74 Commits

Author SHA1 Message Date
abgox 0e698ccbd5 refactor(output): Combine the separated outputs into a single output (#6545)
Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>
2025-11-11 20:48:03 +08:00
Hsiao-nan Cheung ebd8c036fa chore(release): Bump to version 0.5.3 (#6257)
* fix (decompress): `Expand-7zipArchive` only delete temp dir / `$extractDir` if it is empty (#6092)

Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>

* refactor(download): Move download-related functions to 'download.ps1' (#6095)

* fix(download): Fallback to default downloader when aria2 fails (#4292)

* fix(commands): Handling broken aliases (#6141)

* fix(shim): properly check `wslpath`/`cygpath` command first (#6114)

Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>

* fix(scoop-bucket): Add missing import for `no_junction` envs (#6181)

Signed-off-by: Chawye Hsu <su+git@chawyehsu.com>

* docs(chglog): Update to 0.5.3 (#6258)

* perf(shim): Update kiennq-shim to v3.1.2 (#6261)

* fix(decompress): Replace deprecated 7ZIPEXTRACT_USE_EXTERNAL config (#6327)

Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>

* fix(scoop-uninstall): Fix uninstaller does not gain Global state (#6430)

* global arg

* changelog

* refactor(Get-Manifest): Select actual source for manifest (#6142)

* first step

* Revert "first step"

This reverts commit c5907c3e25.

* refactor(Get-Manifest): Select actual source for installed manifest

* rework sub-commands, `scoop-depends` is NOT working at this stage

* URI manifest

* opt

* deprecated manifest

* source of manifests

* source of manifest pt2

- Mark URI(path/URL/UNC/etc.) query as standalone manifest
- Drop `installed` and `available update` items for [query] and [installed] are different sources.

* remove variable preventing I forget it

* scoop-info: fix source of manifest on bucket

* fix `scoop-depends`

* Fix Standalone and Source detection

* fix global install

* Fix scoop-cat, scoop-home

- Query for remote manifest

* scoop-list: info +deprecated

* manifest: Fix first selected manifest

* gramma..

* Fix 61b3259

* length

* fix(scoop-depends-tests): Mocking `USE_EXTERNAL_7ZIP` as $false (#6431)

* fix(scoop-depends-tests): Mocking `USE_EXTERNAL_7ZIP` as $false to avoding error when it is $true

* CHANGELOG

* feat(autoupdate): GitHub predefined hashes support (#6416)

* feat(autoupdate): predefined hash case for GitHub

- Remove `sha256:` prefix in `format_hash()`
- Add GitHub support in `get_hash_for_app()`

Close #6381

* doc(chglog): GitHub auto hash update

* fix(autoupdate): remove prefix only

* docs(CHANGELOG): Update to 0.5.3 (#6432)

* docs(CHANGELOG): Update to 0.5.3

* 6416

---------

Signed-off-by: Chawye Hsu <su+git@chawyehsu.com>
Co-authored-by: Olav Rønnestad Birkeland <6450056+o-l-a-v@users.noreply.github.com>
Co-authored-by: kiennq <kien.n.quang@gmail.com>
Co-authored-by: HUMORCE <humorce@outlook.com>
Co-authored-by: Ryan <sitiom@proton.me>
Co-authored-by: Chawye Hsu <su+git@chawyehsu.com>
Co-authored-by: Bassel Rachid <101208715+basselworkforce@users.noreply.github.com>
Co-authored-by: Wordless Echo <wordless@echo.moe>
2025-08-11 00:38:38 +00:00
L. Yeung dec4232754 fix(decompress): Match extract_dir/extract_to and archives (#5983) 2024-05-26 15:36:06 +08:00
Hsiao-nan Cheung 5c896e901f refactor(decompress): Use 7zip to extract Zstd archive (#5973) 2024-05-17 09:56:14 +08:00
Hsiao-nan Cheung a5bd2297c6 refactor(install): Separate archive extraction from downloader (#5951) 2024-05-12 18:47:16 +08:00
Hsiao-nan Cheung 1752050614 fix(core): Fix "Invoke-ExternalCommand" quoting rules (#5945) 2024-05-11 14:49:49 +08:00
Hsiao-nan Cheung 7054c9d338 fix(decompress): Use wix.exe in WiX Toolset v4+ as primary extractor of Expand-DarkArchive() (#5871) 2024-04-12 16:09:11 +08:00
Hsiao-nan Cheung 9d07c33e87 fix(decompress): Remove unused parent dir w/ 'extract_dir' (#5682) 2024-03-13 18:41:58 +08:00
Richard Kuhnt 7826d6fe2d perf(decompress): disable progress bar to improve Expand-Archive performance (#5410)
See: https://github.com/ScoopInstaller/Install/pull/42

---------

Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>
2023-02-27 20:11:40 +01:00
Hsiao-nan Cheung 257304bbc7 fix(decompress): Exclude '*.nsis' that may cause error (#5294) 2022-12-18 23:22:41 +08:00
Hsiao-nan Cheung 1eea29b0d1 fix(decompress): Trim ending '/' (#5195) 2022-10-15 23:19:16 +08:00
Hsiao-nan Cheung ec8161df6c fix(decompress): Use PS's default 'Expand-Archive()' (#5185) 2022-10-14 14:29:24 +08:00
Hsiao-nan Cheung 08ecdd16a8 fix(config): Change config option to snake_case in file and SCREAMING_CASE in code (#5116) 2022-08-21 19:51:31 +08:00
L. Yeung 288aee9ee9 feat(core): Improve argument concatenation in Invoke-ExternalCommand (#5065) 2022-07-25 23:44:26 +08:00
Issac Lin 1b5ee6f090 fix(decompress): Handle split RAR archives (#4994) 2022-06-24 22:15:54 +08:00
Issac Lin b130e606cf fix(depends): Avoid digits in archive file extension (#4915)
Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>
2022-05-16 22:32:26 +08:00
Chawye Hsu 4d36cbd90d fix(decompress): Fix tarball decompression (#4813)
Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>
2022-03-17 20:30:43 +08:00
Hsiao-nan Cheung 5b87c99aa8 refactor(deps): Rewrite 'depends.ps1' (#4638) 2022-01-12 11:10:55 +08:00
Hsiao-nan Cheung 3ca1b1f2e3 fix(decompress): Fix Split-Path -LeafBase in PS5 (#4639) 2022-01-10 14:22:12 +08:00
Hsiao-nan Cheung d5cb86078b fix(decompress): Fix nested Zstd archive extraction (#4608) 2021-12-31 01:04:47 +08:00
Hsiao-nan Cheung cd6d31dae8 fix(decompress): Fix 'Expand-7zipArchive()' for nested archive (#4582) 2021-12-15 11:38:02 +08:00
Hsiao-nan Cheung e35ff313a5 fix(decompress): Check .zst first
And also trim `\` in `-DestinationPath`
2021-11-10 11:11:45 +08:00
worldyun af7a6f6d0e feat(decompress): Support Zstandard archive (#4372)
Co-authored-by: WorldYun <worldyun@qq.com>
Co-authored-by: Hsiao-nan Cheung <niheaven@gmail.com>
2021-11-10 09:40:11 +08:00
issaclin32 544e6094cc fix(decompress): fix bugs on extract_dir (#3540) 2019-07-24 22:37:31 +02:00
Hsiao-nan Cheung 1caaed8f3d feat(compress): Allow 'Expand-InnoArchive -ExtractDir' to accept '{xxx}' (#3487) 2019-06-24 14:26:35 +02:00
Hsiao-nan Cheung c8047bd5ed fix(decompress): '$ExtractDir' error with '.zip' and subdir (#3472)
For some `extract_dir` in .zip that has sub-dir, the former one would remove parent dir and get error (flac, flac-1.3.2-win\win64), now use temp dir instead. And also fix .msi, in case of some installer that don't have `SourceDir`.

`Expand-DarkArchive` will be used in wix extraction, so it doesn't need `-ExtractDir`.

`Expand-7zipArchive` and `Expand-InnoArchive` works well.

Tested:

- calibre-normal (msi, PFiles\Calibre2)
- flac (zip, flac-1.3.2-win\win64)
- pkg-config (zip, multiple url and extract_dir)

BTW, `Expand-Archive` has `-PassThru` param in PowerShell 6+, and it will be more convinient to support `-ExtractDir` with it. I'll check function's source code and plan to rewrite `Expand-ZipArchive`.

Fix #3473, ref https://github.com/lukesampson/scoop/issues/3473#issuecomment-493446461
2019-06-24 14:26:35 +02:00
Hsiao-nan Cheung a882c4f1eb fix(decompress): '$ExtractDir' removed original extract file by accident (#3470) 2019-06-24 14:26:35 +02:00
Hsiao-nan Cheung 2fafcb880a feature(decompress): Add 'ExtractDir' to 'Expand-...' functions (#3466)
* feature(decompress): Add 'ExtractDir' to 'Expand-...' functions

* Fix 'TrimEnd' and nested 7z
2019-06-24 14:26:35 +02:00
Hsiao-nan Cheung 61d1c1c41a refactor(core): Add more generic 'Invoke-ExternalCommand' instead of 'run' (#3432) 2019-06-24 14:26:35 +02:00
Richard Kuhnt 6141e46d6a fix(decompress): Change dark.exe parameter order
https://github.com/lukesampson/scoop-extras/pull/2143
https://github.com/ScoopInstaller/Main/pull/56
2019-05-15 19:53:54 +02:00
Richard Kuhnt 87a1e784d7 fix(decompress): Fix dark parameter order
close #3454
2019-05-12 14:05:39 +02:00
Richard Kuhnt 27afed09d4 feature(decompress): Add Expand-DarkArchive helper function 2019-05-11 22:09:49 +02:00
Richard Kuhnt f396d8837d Sync #3425 hotfix to develop 2019-05-01 21:27:44 +02:00
Hsiao-nan Cheung a6fd88f582 Expand-ZipArchive: Compatible with Pscx (#3425)
Close scoopinstaller/scoop-main#19
Close scoopinstaller/scoop-main#20
Close lukesampson/scoop-extras#2078
2019-05-01 21:26:54 +02:00
Richard Kuhnt 010546cf26 refactor(core): Combine helpers to Get-HelperPath and Test-HelperInstalled 2019-05-01 14:17:49 +02:00
Richard Kuhnt e162255824 refactor(decompress): Use helper functions for 7zip/lessmsi/innounp 2019-05-01 14:17:49 +02:00
Richard Kuhnt d3ba0b203f fix(decompress): Fix return value of extract_7zip 2019-05-01 14:17:49 +02:00
Richard Kuhnt 501d4b4d35 refactor(decompress): Change function name casing
7zip_path -> Get-7zipPath
7zip_installed -> Test-7zipInstalled
Expand-7ZipArchive -> Expand-7zipArchive
Test-7ZipRequirement -> Test-7zipRequirement
Expand-MSIArchive -> Expand-MsiArchive
Test-LessMSIRequirement -> Test-LessmsiRequirement
2019-05-01 14:17:49 +02:00
Hsiao-nan Cheung 34c26aab6c Patch(decompress): Allow other args to be passthrough (#3411)
ref: https://github.com/lukesampson/scoop-extras/pull/2021#issuecomment-484182951, https://github.com/lukesampson/scoop/pull/3204#issuecomment-484402074

- Add new param `Overwrite` to `Expand-7ZipArchive`, with following values
  - "All": 7z param `-aoa`, overwrite All existing files without prompt, behave the same with default
  - "Skip": 7z param `-aos`, Skip extracting of existing files
  - "Rename": 7z param `-aou`, aUto rename extracting file
- Add new param `Switches` to `Expand-7ZipArchive` and `Expand-InnoArchive`
  - It could pass all unrecognized params to `7z` and `innounp`
- Patch `extract_7zip` and `unpack_inno` to adapt to `Expand-XXX`

Usage: https://github.com/lukesampson/scoop-extras/pull/2021, https://github.com/lukesampson/scoop-extras/pull/2070
2019-04-29 17:26:42 +02:00
Chawye Hsu 2db651c13a fix: correct deprecation function name (#3406) 2019-04-28 14:23:04 +02:00
Richard Kuhnt 1268d74224 [Regression]: Rename extract_inno to unpack_inno 2019-04-28 12:50:49 +02:00
Richard Kuhnt 79a6d5cb04 decompress: Fix get_config calls 2019-04-26 20:34:16 +02:00
Hsiao-nan Cheung 72730e0d73 decompress.ps1: Refactor extraction handling functions (#3204)
* Refactored functions:
  * requires_7zip > Test-7ZipRequirement
  * requires_lessmsi > Test-LessMSIRequirement
  * extract_7zip > Expand-7ZipArchive
  * extract_msi/extract_lessmsi > Expand-MSIArchive
  * unpack_inno > Expand-InnoArchive
  * extract_zip/unzip_old > Expand-ZipArchive
* Fix 7zip failed when .tar and .tgz have diff names
* Add tools to CI
* Add test cases for Expand-7ZipArchive
* Add test cases for Expand-InnoArchive
* Add test cases for Expand-MSIArchive
* Add config `7ZIPEXTRACT_USE_EXTERNAL`
* Change '$recurse' to '$removal'
2019-04-26 18:35:59 +02:00
Hsiao-nan Cheung 5f91682a79 decompress.ps1: Refactored (w/ install.ps1, core.ps1) (edited) (#3169)
* decompress.ps1: Refactored (w/ install.ps1, core.ps1)

* fix install.ps1
2019-03-07 22:14:06 +01:00
Richard Kuhnt 2224da82f8 Allow extraction of nupkg files with 7zip 2018-08-09 19:23:06 +02:00
Richard Kuhnt 55ce0c0b0c Check if 7zip installed via Scoop instead of using 7z.exe from PATH 2018-08-08 11:06:35 +02:00
Steve Baker 9a3fc965ef Add .bz2 files to decompression (#2085)
Add .bz2 files to decompression
2018-03-04 10:26:59 +01:00
Chawye Hsu e1bb1e91d0 Lint: PSAvoidUsingCmdletAliases (#2075) 2018-03-03 18:41:19 +01:00
Luke Sampson e8e5ac5615 Update more UI messages for consistency. 2017-02-13 20:53:36 +11:00
Luke Sampson 1c173bc56d Use sentence case for UI messages. 2017-02-13 20:20:41 +11:00