Skip to content

Simplify install/uninstall to direct single-line commands (#33)#34

Merged
JosunLP merged 2 commits into
mainfrom
dev
Mar 30, 2026
Merged

Simplify install/uninstall to direct single-line commands (#33)#34
JosunLP merged 2 commits into
mainfrom
dev

Conversation

@JosunLP
Copy link
Copy Markdown
Owner

@JosunLP JosunLP commented Mar 30, 2026

This pull request updates the installation and uninstallation instructions and scripts for both Unix and Windows. The main goal is to simplify the process by allowing users to stream the scripts directly into their shells, while still supporting manual review if desired. Additionally, the scripts have been improved to handle cases where they are executed directly from a stream and not from a file.

README and documentation improvements:

  • Updated installation and uninstallation instructions in README.md to use direct streaming of scripts via curl (Unix) and irm (PowerShell), reducing the need for temporary file downloads. Added a note about how to manually review scripts if preferred.

Unix install script (install-unix.sh) improvements:

  • Changed detection of the script directory to handle cases where the script is streamed and not present as a file, preventing errors when $SCRIPT_SOURCE is not a file.
  • Modified logic for determining the binary path and local installation: now only attempts to install from a local binary if the script directory is valid and the binary exists.

Windows install script (install-windows.ps1) improvements:

  • Improved handling of script path and binary path to support streaming execution (i.e., when the script is not saved to disk), by checking if $scriptPath exists and setting $binaryPath accordingly.
  • Updated logic to only attempt local installation if the binary path is valid and the file exists, preventing errors when running from a stream.

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: JosunLP <[email protected]>
Copilot AI review requested due to automatic review settings March 30, 2026 09:24
@github-actions github-actions Bot added documentation Improvements or additions to documentation scripts labels Mar 30, 2026
@JosunLP
Copy link
Copy Markdown
Owner Author

JosunLP commented Mar 30, 2026

@codex[agent] update the version and the changelog

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the project’s installation/uninstallation flow to support “single-line” streaming execution (curl/irm piped into shell/PowerShell) while keeping archive-bundle installs working.

Changes:

  • README: replaces download-then-run examples with streamed one-liners and adds a note about manual review.
  • Unix installer: makes script-directory detection safe for streamed execution and only attempts local-binary install when the script path is a real file.
  • Windows installer: makes script/binary path detection safe for streamed execution and guards local-binary install accordingly.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
README.md Switches install/uninstall examples to piped execution and documents review option.
scripts/install-unix.sh Avoids assuming $BASH_SOURCE is a file; gates local-binary installation on valid script dir.
scripts/install-windows.ps1 Avoids assuming $MyInvocation.MyCommand.Path exists; gates local-binary installation on valid paths.

Comment thread README.md
Comment thread README.md
@JosunLP
Copy link
Copy Markdown
Owner Author

JosunLP commented Mar 30, 2026

@copilot apply changes based on the comments in this thread

@Codex
Copy link
Copy Markdown

Codex AI commented Mar 30, 2026

@codex[agent] update the version and the changelog

Version bumped to 1.3.1 and changelog updated with the install/uninstall changes (0374ab9).

@JosunLP
Copy link
Copy Markdown
Owner Author

JosunLP commented Mar 30, 2026

@copilot apply changes based on the comments in this thread

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 30, 2026

@copilot apply changes based on the comments in this thread

Applied in 7c1e262. The README now uses sudo env SORT_IT_NOW_VERSION=<version> bash for the streamed Unix install example and sudo bash for the default-path uninstall example, with an added note about /usr/local/bin and INSTALL_DIR.

@copilot apply changes based on the comments in this thread

Applied in 7c1e262. The README now uses sudo env SORT_IT_NOW_VERSION=<version> bash for the streamed Unix install example and sudo bash for the default-path uninstall example, with an added note about /usr/local/bin and INSTALL_DIR.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.

Comment thread README.md Outdated
@JosunLP
Copy link
Copy Markdown
Owner Author

JosunLP commented Mar 30, 2026

@copilot apply changes based on the comments in this thread

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 30, 2026

@copilot apply changes based on the comments in this thread

Applied in 4892975. The README now marks the default streamed Windows install command as an Administrator/elevated PowerShell flow and points to $env:LOCALAPPDATA\Programs\sort-it-now as the per-user -Destination example. No UI changes were made, so there isn’t a screenshot to include.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.

@JosunLP JosunLP merged commit 497416d into main Mar 30, 2026
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation scripts

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants