Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion UniGetUI.iss
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ Name: "portableinstall"; Description: "{cm:PortInst}"; GroupDescription: "{cm:In
Name: "regularinstall"; Description: "{cm:RegInst}"; GroupDescription: "{cm:InstallType}"; Flags: exclusive
Name: "regularinstall\startmenuicon"; Description: "{cm:RegStartMmenuIcon}"; GroupDescription: "{cm:ShCuts}";
Name: "regularinstall\desktopicon"; Description: "{cm:RegDesktopIcon}"; GroupDescription: "{cm:ShCuts}";
Name: "regularinstall\addtopath"; Description: "{cm:RegAddToPath}"; Flags: unchecked;
Name: "regularinstall\addtopath"; Description: "{cm:RegAddToPath}";

[Registry]
Root: HKCU; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\Run"; ValueType: string; ValueName: "WingetUI"; ValueData: """{app}\UniGetUI.exe"" --daemon"; Flags: uninsdeletevalue noerror; Tasks: regularinstall;
Expand Down
12 changes: 6 additions & 6 deletions docs/CLI.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ macOS. It forwards arguments and terminal input/output, waits for each command t
returns its exit code. Keep it with the rest of the installation; copying only the launcher
elsewhere will not work.

- **Windows:** Select **Add to PATH** during a regular installation to run `uniget` from any
directory. This option is off by default and uses the user or system `PATH` according to
the install mode. Open a new terminal after installation. Without this option, run
- **Windows:** Keep **Add to PATH** selected during a regular installation to run `uniget` from
any directory. This option is on by default (upgrades keep your previous choice) and uses the
user or system `PATH` according to the install mode. Open a new terminal after installation. Without this option, run
`.\uniget.exe` from the installation directory.
- **Linux:** The `.deb` and `.rpm` packages expose `uniget` on `PATH`; from an extracted tarball,
run `./uniget` in the directory containing `UniGetUI`.
Expand All @@ -33,11 +33,11 @@ The commands below assume PowerShell is in the installation directory on Windows
.\uniget.exe operation wait --id 123 --timeout 300
```

For a silent Windows installation, include `ADDTOPATH=1` to opt in, or `ADDTOPATH=0` to
explicitly deselect **Add to PATH**:
For a silent Windows installation, include `ADDTOPATH=0` to opt out, or `ADDTOPATH=1` to
explicitly select **Add to PATH** (for example, over a previously saved opt-out):

```powershell
.\UniGetUI.Installer.exe /VERYSILENT /SUPPRESSMSGBOXES /NORESTART ADDTOPATH=1
.\UniGetUI.Installer.exe /VERYSILENT /SUPPRESSMSGBOXES /NORESTART ADDTOPATH=0
```

The property name is case-insensitive and accepts only `0` or `1`. It overrides the saved
Expand Down
2 changes: 1 addition & 1 deletion docs/TUI.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Otherwise, use the launcher included with your installation:
| Linux | Installed `.deb` and `.rpm` packages provide `uniget tui`. From an extracted archive, open its folder and run `./uniget tui`. |
| macOS | After installing in Applications, run `/Applications/UniGetUI.app/Contents/MacOS/uniget tui`. From an extracted archive, run `./uniget tui` in its folder. |

On Windows, selecting **Add to PATH** during installation lets you use `uniget` from any
On Windows, the **Add to PATH** installer option (on by default) lets you use `uniget` from any
folder. Open a new terminal after installation. Portable installations do not change `PATH`;
run the launcher from the portable folder. See [the CLI guide](CLI.md#quick-start) for more
launch options and [portable mode](PORTABLE.md) for portable installation details.
Expand Down
17 changes: 9 additions & 8 deletions testing/automation/run-installer-path-tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,12 @@ try {
$ownerName = [Convert]::ToHexString([Security.Cryptography.SHA256]::HashData(
[Text.Encoding]::Unicode.GetBytes($entry.ToLowerInvariant()))).ToLowerInvariant()
$cases = @(
@{ Name = 'default-unchecked'; Args = @(); Path = 0; Before = 0 },
@{ Name = 'alias-enable'; Args = @('ADDTOPATH=1'); Path = 1; Before = 0 },
@{ Name = 'alias-disable'; Args = @('ADDTOPATH=0'); Path = 0; Before = 0 },
@{ Name = 'case-insensitive'; Args = @('aDdToPaTh=1'); Path = 1; Before = 0 },
@{ Name = 'same-value-repeated'; Args = @('ADDTOPATH=1', 'addtopath=1'); Path = 1; Before = 0 },
@{ Name = 'same-zero-repeated'; Args = @('ADDTOPATH=0', 'addtopath=0'); Path = 0; Before = 0 },
@{ Name = 'default-checked'; Args = @(); Path = 1; Before = 1 },
@{ Name = 'alias-enable'; Args = @('ADDTOPATH=1'); Path = 1; Before = 1 },
@{ Name = 'alias-disable'; Args = @('ADDTOPATH=0'); Path = 0; Before = 1 },
@{ Name = 'case-insensitive'; Args = @('aDdToPaTh=0'); Path = 0; Before = 1 },
@{ Name = 'same-value-repeated'; Args = @('ADDTOPATH=1', 'addtopath=1'); Path = 1; Before = 1 },
@{ Name = 'same-zero-repeated'; Args = @('ADDTOPATH=0', 'addtopath=0'); Path = 0; Before = 1 },
@{ Name = 'native-merge-still-works'; Args = @('/MERGETASKS="regularinstall\addtopath"'); Path = 1; Before = 1 },
@{ Name = 'native-tasks-still-works'; Args = @('/TASKS="regularinstall,regularinstall\addtopath"'); Path = 1; Before = 1 },
@{ Name = 'override-tasks-disable'; Args = @('/TASKS="regularinstall,regularinstall\startmenuicon,regularinstall\addtopath"', 'ADDTOPATH=0'); Path = 0; Before = 1 },
Expand All @@ -120,11 +120,12 @@ try {
@{ Name = 'portable-enable-ignored'; Args = @('/TASKS="portableinstall"', 'ADDTOPATH=1'); Path = 0; Before = 0; Portable = 1 },
@{ Name = 'portable-disable-ignored'; Args = @('/TASKS="portableinstall"', 'ADDTOPATH=0'); Path = 0; Before = 0; Portable = 1 },
@{ Name = 'portable-owned-untouched'; Args = @('/TASKS="portableinstall"', 'ADDTOPATH=1'); Path = 0; Before = 0; Portable = 1; Seed = 'owned' },
@{ Name = 'unrequested-slash-not-supported'; Args = @('/ADDTOPATH=1'); Path = 0; Before = 0 },
@{ Name = 'unrequested-slash-not-supported'; Args = @('/ADDTOPATH=0'); Path = 1; Before = 1 },
@{ Name = 'previous-on-retained'; Args = @(); Path = 1; Before = 1; Previous = 'on'; Seed = 'owned' },
@{ Name = 'previous-off-retained'; Args = @(); Path = 0; Before = 0; Previous = 'off' },
@{ Name = 'previous-on-alias-off'; Args = @('ADDTOPATH=0'); Path = 0; Before = 1; Previous = 'on'; Seed = 'owned' },
@{ Name = 'previous-off-alias-on'; Args = @('ADDTOPATH=1'); Path = 1; Before = 0; Previous = 'off' },
@{ Name = 'preexisting-enable-unowned'; Args = @('ADDTOPATH=1'); Path = 1; Before = 0; Seed = 'preexisting' },
@{ Name = 'preexisting-enable-unowned'; Args = @('ADDTOPATH=1'); Path = 1; Before = 1; Seed = 'preexisting' },
@{ Name = 'preexisting-disable-preserved'; Args = @('/MERGETASKS="regularinstall\addtopath"', 'ADDTOPATH=0'); Path = 0; Before = 1; Seed = 'preexisting' },
@{ Name = 'invalid-missing-equals'; Args = @('ADDTOPATH'); Invalid = 'Invalid argument' },
@{ Name = 'invalid-empty'; Args = @('ADDTOPATH='); Invalid = 'Invalid argument' },
Expand Down
Loading