Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(release): Bump to version 0.4.0 #5424

Merged
merged 75 commits into from
Apr 18, 2024
Merged
Show file tree
Hide file tree
Changes from 31 commits
Commits
Show all changes
75 commits
Select commit Hold shift + click to select a range
360daa7
feat(chore): Improve git.exe execution and add parallel bucket update…
r15ch13 Nov 23, 2022
af5ffcd
test(bucket): Skip manifest validation if no manifest changes (#5270)
niheaven Nov 30, 2022
6369ba6
refactor(scoop-download): Output more detailed manifest information (…
HUMORCE Dec 10, 2022
52f9ce3
fix(autoupdate): Fix file hash extraction (#5295)
niheaven Dec 18, 2022
257304b
fix(decompress): Exclude '*.nsis' that may cause error (#5294)
niheaven Dec 18, 2022
68760de
fix(shortcuts): Output correctly formatted path (#5333)
HUMORCE Jan 9, 2023
e2558ac
fix(chore): Handle spaces in git command arguments (#5375)
rashil2000 Feb 6, 2023
54e3613
ci(dependabot): Add dependabot.yml for GitHub Actions (#5377)
rasa Feb 18, 2023
1d0bd43
builds(checkver): Read the private_host config variable (#5381)
Ercolino Feb 19, 2023
32ca856
fix(core): Fix `is_in_dir` under Unix (#5391)
niheaven Feb 19, 2023
7c6aeb2
fix(install): Fix downloading release assets from private GitHub repo…
jeppefrandsen Feb 25, 2023
c44e214
feat(config): Support portable config file (#5369)
chawyehsu Feb 25, 2023
0a39de8
fix(env): Avoid automatic expansion of `%%` in env (#5395)
WHYBBE Feb 25, 2023
3f11454
fix(core): Fix scripts' calling parameters (#5365)
niheaven Feb 26, 2023
c00dd42
fix(getopt): Stop split arguments in `getopt()` and ensure array by e…
Valinor Feb 26, 2023
8acfeee
fix(scoop-info) --verbose file size collection (#5352)
starthal Feb 26, 2023
7826d6f
perf(decompress): disable progress bar to improve Expand-Archive perf…
r15ch13 Feb 27, 2023
559c6f9
feat(bucket): Make official buckets higher priority (#5398)
niheaven Mar 10, 2023
41620bb
feat(core): Add `-Silent` switch for `Invoke-ExternalCommand` (#5346)
Mar 11, 2023
ad0f617
feat(bucket): Switch nirsoft bucket to ScoopInstaller/Nirsoft (#5328)
rasa Mar 11, 2023
a20bb4f
fix(shim): Use bash executable directly (#5433)
rashil2000 Mar 16, 2023
2accaae
fix(core): Rewrite config file when needed (#5439)
niheaven Mar 20, 2023
682a1e2
fix(git): set HTTP(S)_PROXY only in process scope to prevent race con…
r15ch13 Mar 20, 2023
cddc52e
docs(scoop-info): Fix help message (#5445)
HUMORCE Mar 27, 2023
52059ca
fix(env): Apply env immediately by `SendMessageTimeout` (#5452)
WHYBBE Apr 7, 2023
1d14058
fix(scoop-checkup): Skip defender check in Windows Sandbox (#5519)
HUMORCE May 30, 2023
3dfb4bf
fix(buckets): Avoid error messages for unexpected dir (#5549)
HUMORCE Jun 29, 2023
efdd6dd
docs(CHANGELOG): Add missing brackets for the links (#5596)
Lutra-Fs Aug 11, 2023
0b4919c
fix(scoop-virustotal): Continue execution when no app but `-a` flag i…
Lutra-Fs Sep 10, 2023
6a35a22
fix(scoop-checkup): Change the message level of helpers from ERROR to…
HUMORCE Sep 11, 2023
aa09601
docs(readme): Improve documentation language (#5638)
walpox Oct 2, 2023
4357971
fix(env): Publish environment change when deleting variable (#5631)
rashil2000 Oct 2, 2023
353137f
fix(shim): Remove console window for GUI apps (#5559)
spider2048 Oct 2, 2023
6898773
fix(core): Use relative path as fallback of `$scoopdir` (#5544)
HUMORCE Oct 3, 2023
becc7a7
fix(core): Avoid error messages when deleting non-existent environmen…
HUMORCE Oct 3, 2023
00c92b0
fix(install): Avoid error when unlinking non-existent junction/hardli…
HUMORCE Oct 3, 2023
6d79d62
fix(core): Handle scoop aliases and broken (edited,copied) shim (#5551)
HUMORCE Oct 3, 2023
acc271d
fix(scoop-(un)hold): Correct output the messages when manifest not fo…
HUMORCE Oct 3, 2023
b3c05e7
perf(scoop-search): Improve performance for local search (#5644)
r15ch13 Oct 3, 2023
863af42
fix(core): Fix detection of Git (#5545)
HUMORCE Oct 5, 2023
ab34b7f
feat(core): Allow global install of PowerShell modules (#5611)
gerardog Oct 5, 2023
15f9bbe
fix(update): Change error message to a better instruction (#5677)
rashil2000 Oct 6, 2023
3a3f41c
fix(shim): Fix shim adding bug related to Resolve-Path(#5493)
dooptydoo90x Oct 8, 2023
2847e0a
fix(scoop-shim): Avoid unexpected output of `list` subcommand (#5681)
lewis-yeung Oct 10, 2023
14b38b4
fix(scoop-shim): Check literal path in `Get-ShimPath` (#5680)
lewis-yeung Oct 10, 2023
6cdcc75
fix(shim): Fix a minor issue with `Get-Subsystem` (#5684)
spider2048 Oct 14, 2023
7b35e19
fix(perf): Do not call `scoop` externally from inside the code (#5695)
hagaigold Oct 19, 2023
7e81e49
fix(scoop-reset): Don't abort when multiple apps are passed and an ap…
Lutra-Fs Oct 26, 2023
fb31696
fix(scoop-checkup): Don't throw 7zip error when external 7zip is used…
rashil2000 Oct 26, 2023
5328bef
fix(config): Warn users about misconfigured token (#5777)
rashil2000 Jan 5, 2024
48f7935
fix(manifest): Correct source of manifest (#5575)
HUMORCE Feb 23, 2024
7e3dc73
refactor(core): Cleanup some old codes, e.g., `msi` section and confi…
niheaven Mar 6, 2024
54e0514
fix(install): Fix bugs in #5715 (#5824)
niheaven Mar 7, 2024
6f9ed1d
fix(ci): Update 'psmodulecache' version to 'main' (#5828)
niheaven Mar 13, 2024
9d07c33
fix(decompress): Remove unused parent dir w/ 'extract_dir' (#5682)
niheaven Mar 13, 2024
3186fef
fix(update/uninstall): Remove items from PATH correctly (#5833)
niheaven Mar 20, 2024
90766f9
fix(shim): Allow GUI applications to attach to the shell's console wh…
spider2048 Mar 20, 2024
5354ab5
builds(supporting): Update Json to 13.0.3, Json.Schema to 3.0.15 (#5835)
niheaven Mar 21, 2024
5153d73
perf(shim): Update kiennq-shim to v3.1 (#5841)
niheaven Mar 22, 2024
9770c86
fix(shim): Update kiennq-shim to v3.1.1 (#5847)
niheaven Mar 25, 2024
77b66cc
fix(core): Fix arguments parsing method of `Invoke-ExternalCommand()`…
niheaven Mar 25, 2024
6772e61
refactor(core): Rewrite and separate path-related functions to `syste…
niheaven Mar 27, 2024
dfbeace
fix(system): Remove EnvVar only if existed (#5858)
niheaven Apr 1, 2024
9ef03c2
perf(scoop-update): Check for running process before wasting time on …
davidlwatsonjr Apr 1, 2024
0b13505
fix(scoop-shim): Import system.ps1 (#5864)
svraka Apr 4, 2024
5a06eac
refactor(helper): Remove 7zip's fallback '7zip-zstd' (#5548)
HUMORCE Apr 8, 2024
b008fe5
fix(scoop-virustotal): escape character not available in PowerShell 5…
amorphobia Apr 8, 2024
81e7dec
fix(scoop-alias): Prevent overwrite existing file when adding alias (…
HUMORCE Apr 8, 2024
92b71c6
refactor(core): Get rid of 'fullpath' (#3533)
niheaven Apr 10, 2024
6327146
fix(shim): Run JAR file from app's root directory (#5872)
niheaven Apr 11, 2024
7054c9d
fix(decompress): Use `wix.exe` in WiX Toolset v4+ as primary extracto…
niheaven Apr 12, 2024
98cf8ae
fix(autoupdate): Fix bug that 'WebClient' doesn't auto-extract 'gzip'…
niheaven Apr 17, 2024
fa06e92
refactor(shim): Remove CS shim codebase (#5903)
niheaven Apr 18, 2024
5819b5a
feat(path): Isolate Scoop apps' PATH (#5840)
niheaven Apr 18, 2024
78f6fec
docs(changelog): Rearrange and update CHANGELOG (#5904)
niheaven Apr 18, 2024
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
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
---
# ~/.github/dependabot.yml
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/" # == /.github/workflows/
schedule:
interval: "daily"
55 changes: 55 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,58 @@
## [Unreleased](https://github.com/ScoopInstaller/Scoop/compare/master...develop)

### Features

- **scoop-update:** Add support for parallel syncing buckets in PowerShell 7 and improve output ([#5122](https://github.com/ScoopInstaller/Scoop/issues/5122))
- **bucket:** Switch nirsoft bucket to ScoopInstaller/Nirsoft ([#5328](https://github.com/ScoopInstaller/Scoop/issues/5328))
- **config:** Support portable config file ([#5369](https://github.com/ScoopInstaller/Scoop/issues/5369))
- **bucket:** Make official buckets higher priority ([#5398](https://github.com/ScoopInstaller/Scoop/issues/5398))
- **core:** Add `-Quiet` switch for `Invoke-ExternalCommand` ([#5346](https://github.com/ScoopInstaller/Scoop/issues/5346))

### Bug Fixes

- **decompress:** Exclude '*.nsis' that may cause error ([#5294](https://github.com/ScoopInstaller/Scoop/issues/5294))
- **autoupdate:** Fix file hash extraction ([#5295](https://github.com/ScoopInstaller/Scoop/issues/5295))
- **getopt:** Stop split arguments in `getopt()` and ensure array by explicit arguments type ([#5326](https://github.com/ScoopInstaller/Scoop/issues/5326))
- **shortcuts:** Output correctly formatted path ([#5333](https://github.com/ScoopInstaller/Scoop/issues/5333))
- **core:** Fix scripts' calling parameters ([#5365](https://github.com/ScoopInstaller/Scoop/issues/5365))
- **core:** Fix `is_in_dir` under Unix ([#5391](https://github.com/ScoopInstaller/Scoop/issues/5391))
- **core:** Rewrite config file when needed ([#5439](https://github.com/ScoopInstaller/Scoop/issues/5439))
- **core:** Prevents leaking HTTP(S)_PROXY env vars to current sessions after Invoke-Git in parallel execution ([#5436](https://github.com/ScoopInstaller/Scoop/pull/5436))
- **env:** Avoid automatic expansion of `%%` in env ([#5395](https://github.com/ScoopInstaller/Scoop/issues/5395), [#5452](https://github.com/ScoopInstaller/Scoop/pull/5452))
- **install:** Fix download from private GitHub repositories ([#5361](https://github.com/ScoopInstaller/Scoop/issues/5361))
- **scoop-info:** Fix errors in file size collection when `--verbose` ([#5352](https://github.com/ScoopInstaller/Scoop/pull/5352))
- **shim:** Use bash executable directly ([#5433](https://github.com/ScoopInstaller/Scoop/issues/5433))
- **scoop-checkup:** Skip defender check in Windows Sandbox ([#5519](https://github.com/ScoopInstaller/Scoop/issues/5519))
- **buckets:** Avoid error messages for unexpected dir ([#5549](https://github.com/ScoopInstaller/Scoop/issues/5549))
- **scoop-virustotal**: Fix `scoop-virustotal` when `--all' has been passed without app ([#5593](https://github.com/ScoopInstaller/Scoop/pull/5593))
- **scoop-checkup:** Change the message level of helpers from ERROR to WARN ([#5549](https://github.com/ScoopInstaller/Scoop/issues/5614))

### Performance Improvements

- **decompress:** Disable progress bar to improve `Expand-Archive` performance ([#5410](https://github.com/ScoopInstaller/Scoop/issues/5410))

### Code Refactoring

- **git:** Use Invoke-Git() with direct path to git.exe to prevent spawning shim subprocesses ([#5122](https://github.com/ScoopInstaller/Scoop/issues/5122), [#5375](https://github.com/ScoopInstaller/Scoop/issues/5375))
- **scoop-download:** Output more detailed manifest information ([#5277](https://github.com/ScoopInstaller/Scoop/issues/5277))

### Builds

- **checkver:** Read the private_host config variable ([#5381](https://github.com/ScoopInstaller/Scoop/issues/5381))

### Continuous Integration

- **dependabot:** Add dependabot.yml for GitHub Actions ([#5377](https://github.com/ScoopInstaller/Scoop/pull/5377))

### Tests

- **bucket:** Skip manifest validation if no manifest changes ([#5270](https://github.com/ScoopInstaller/Scoop/issues/5270))

### Documentation

- **scoop-info:** Fix help message([#5445](https://github.com/ScoopInstaller/Scoop/issues/5445))
- **readme:** Improve documentation language ([#5638](https://github.com/ScoopInstaller/Scoop/issues/5638))

## [v0.3.1](https://github.com/ScoopInstaller/Scoop/compare/v0.3.0...v0.3.1) - 2022-11-15

### Features
Expand Down
103 changes: 54 additions & 49 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
<p align="center">
<h1 align="center">Scoop</h1>

<!--<img src="scoop.png" alt="Long live Scoop!"/>-->
<h1 align="center">Scoop</h1>
</p>
<p align="center">
<b><a href="https://github.com/ScoopInstaller/Scoop#what-does-scoop-do">Features</a></b>
|
<b><a href="https://github.com/ScoopInstaller/Scoop#installation">Installation</a></b>
|
<b><a href="https://github.com/ScoopInstaller/Scoop/wiki">Documentation</a></b>
<a href="https://github.com/ScoopInstaller/Scoop#what-does-scoop-do">Features</a>
|
<a href="https://github.com/ScoopInstaller/Scoop#installation">Installation</a>
|
<a href="https://github.com/ScoopInstaller/Scoop/wiki">Documentation</a>
</p>

- - -
<p align="center" >
---

<p align="center">
<a href="https://github.com/ScoopInstaller/Scoop">
<img src="https://img.shields.io/github/languages/code-size/ScoopInstaller/Scoop.svg" alt="Code Size" />
</a>
Expand All @@ -36,43 +36,48 @@ Scoop is a command-line installer for Windows.

## What does Scoop do?

Scoop installs programs from the command line with a minimal amount of friction. It:
Scoop installs apps from the command line with a minimal amount of friction. It:

- Eliminates permission popup windows
- Hides GUI wizard-style installers
- Prevents PATH pollution from installing lots of programs
- Avoids unexpected side-effects from installing and uninstalling programs
- Finds and installs dependencies automatically
- Performs all the extra setup steps itself to get a working program
- Eliminates [User Account Control](https://learn.microsoft.com/windows/security/application-security/application-control/user-account-control/) (UAC) prompt notifications.
- Hides the graphical user interface (GUI) of wizard-style installers.
- Prevents polluting the `PATH` environment variable. Normally, this variable gets cluttered as different apps are installed on the device.
- Avoids unexpected side effects from installing and uninstalling apps.
- Resolves and installs dependencies automatically.
- Performs all the necessary steps to get an app to a working state.

Scoop is very scriptable, so you can run repeatable setups to get your environment just the way you like, e.g.:
Scoop is quite script-friendly. Your environment can become the way you like by using repeatable setups. For example:

```powershell
```console
scoop install sudo
sudo scoop install 7zip git openssh --global
scoop install aria2 curl grep sed less touch
scoop install python ruby go perl
```

If you've built software that you'd like others to use, Scoop is an alternative to building an installer (e.g. MSI or InnoSetup) — you just need to zip your program and provide a JSON manifest that describes how to install it.
If you have built software that you would like others to use, Scoop is an alternative to building an installer (like MSI or InnoSetup). You just need to compress your app to a `.zip` file and provide a JSON manifest that describes how to install it.

## Installation

Run the following command from a **non-admin** PowerShell to install scoop to its default location `C:\Users\<YOUR USERNAME>\scoop`.
Run the following commands from a regular (non-admin) PowerShell terminal to install Scoop:

```powershell
iwr -useb get.scoop.sh | iex
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression
```

Advanced installation instruction and full documentation of the installer are available in [ScoopInstaller/Install](https://github.com/ScoopInstaller/Install). Please create new issues there if you have questions about the installation.
**Note**: The first command makes your device allow running the installation and management scripts. This is necessary because Windows 10 client devices restrict execution of any PowerShell scripts by default.

## [Documentation](https://github.com/ScoopInstaller/Scoop/wiki)
It will install Scoop to its default location:

`C:\Users\<YOUR USERNAME>\scoop`

You can find the complete documentation about the installer, including advanced installation configurations, in [ScoopInstaller/Install](https://github.com/ScoopInstaller/Install). Please create new issues there if you have questions about the installation.

## Multi-connection downloads with `aria2`

Scoop can utilize [`aria2`](https://github.com/aria2/aria2) to use multi-connection downloads. Simply install `aria2` through Scoop and it will be used for all downloads afterward.

```powershell
```console
scoop install aria2
```

Expand All @@ -90,54 +95,54 @@ You can tweak the following `aria2` settings with the `scoop config` command:

## Inspiration

- [Homebrew](http://mxcl.github.io/homebrew/)
- [sub](https://github.com/37signals/sub#readme)
- [Homebrew](https://brew.sh/)
- [Sub](https://signalvnoise.com/posts/3264-automating-with-convention-introducing-sub)

## What sort of apps can Scoop install?

The apps that install best with Scoop are commonly called "portable" apps: i.e. compressed program files that run stand-alone when extracted and don't have side-effects like changing the registry or putting files outside the program directory.

Since installers are common, Scoop supports them too (and their uninstallers).
The apps that are most likely to get installed fine with Scoop are those referred to as "portable" apps. These apps are compressed files which can run standalone after being extracted. This type of apps does not produce side effects like changing the Windows Registry or placing files outside the app directory.

Scoop is also great at handling single-file programs and Powershell scripts. These don't even need to be compressed. See the [runat](https://github.com/ScoopInstaller/Main/blob/master/bucket/runat.json) package for an example: it's really just a GitHub gist.
Scoop also supports installer files and their uninstallation methods. Likewise, it can handle single-file apps and PowerShell scripts. These do not even need to be compressed. See the [runat](https://github.com/ScoopInstaller/Main/blob/master/bucket/runat.json) package for an example: it is simply a GitHub gist.

### Contribute to this project

If you'd like to improve Scoop by adding features or fixing bugs, please read our [Contributing Guide](https://github.com/ScoopInstaller/.github/blob/main/.github/CONTRIBUTING.md).
If you would like to improve Scoop by adding features or fixing bugs, please read our [Contributing Guide](https://github.com/ScoopInstaller/.github/blob/main/.github/CONTRIBUTING.md).

### Support this project

If you find Scoop useful and would like to support ongoing development and maintenance, here's how:
If you find Scoop useful and would like to support the ongoing development and maintenance of this project, you can donate here:

- [PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=DM2SUH9EUXSKJ) (one-time donation)
- [PayPal](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=DM2SUH9EUXSKJ) (one-time donations)

## Known application buckets

The following buckets are known to scoop:
The following buckets are known to Scoop:

- [main](https://github.com/ScoopInstaller/Main) - Default bucket for the most common (mostly CLI) apps
- [extras](https://github.com/ScoopInstaller/Extras) - Apps that don't fit the main bucket's [criteria](https://github.com/ScoopInstaller/Scoop/wiki/Criteria-for-including-apps-in-the-main-bucket)
- [games](https://github.com/Calinou/scoop-games) - Open source/freeware games and game-related tools
- [nerd-fonts](https://github.com/matthewjberger/scoop-nerd-fonts) - Nerd Fonts
- [nirsoft](https://github.com/kodybrown/scoop-nirsoft) - Almost all of the [250+](https://rasa.github.io/scoop-directory/by-apps#kodybrown_scoop-nirsoft) apps from [Nirsoft](https://nirsoft.net)
- [sysinternals](https://github.com/niheaven/scoop-sysinternals) - Sysinternals Suite and all individual application from [Microsoft](https://learn.microsoft.com/sysinternals/)
- [java](https://github.com/ScoopInstaller/Java) - A collection of Java development kits (JDKs), Java runtime engines (JREs), Java's virtual machine debugging tools and Java based runtime engines.
- [nonportable](https://github.com/ScoopInstaller/Nonportable) - Non-portable apps (may require UAC)
- [php](https://github.com/ScoopInstaller/PHP) - Installers for most versions of PHP
- [versions](https://github.com/ScoopInstaller/Versions) - Alternative versions of apps found in other buckets
- [main](https://github.com/ScoopInstaller/Main) - Default bucket which contains popular non-GUI apps.
- [extras](https://github.com/ScoopInstaller/Extras) - Apps that do not fit the main bucket's [criteria](https://github.com/ScoopInstaller/Scoop/wiki/Criteria-for-including-apps-in-the-main-bucket).
- [games](https://github.com/Calinou/scoop-games) - Open-source and freeware video games and game-related tools.
- [nerd-fonts](https://github.com/matthewjberger/scoop-nerd-fonts) - Nerd Fonts.
- [nirsoft](https://github.com/ScoopInstaller/Nirsoft) - A collection of over 250+ apps from [Nirsoft](https://nirsoft.net).
- [sysinternals](https://github.com/niheaven/scoop-sysinternals) - The Sysinternals suite from [Microsoft](https://learn.microsoft.com/sysinternals/).
- [java](https://github.com/ScoopInstaller/Java) - A collection of Java development kits (JDKs) and Java runtime engines (JREs), Java's virtual machine debugging tools and Java based runtime engines.
- [nonportable](https://github.com/ScoopInstaller/Nonportable) - Non-portable apps (may trigger UAC prompts).
- [php](https://github.com/ScoopInstaller/PHP) - Installers for most versions of PHP.
- [versions](https://github.com/ScoopInstaller/Versions) - Alternative versions of apps found in other buckets.

The main bucket is installed by default. To add any of the other buckets, type:
The `main` bucket is installed by default. You can make use of more buckets by typing:

```console
scoop bucket add bucketname
scoop bucket add <name>
```

For example, to add the extras bucket, type:
For example, to add the `extras` bucket, type:

```console
scoop bucket add extras
```

You would be able to install apps from the `extras` bucket now.

## Other application buckets

Many other application buckets hosted on Github can be found in the [Scoop Directory](https://rasa.github.io/scoop-directory/) or via [other search engines](https://rasa.github.io/scoop-directory/#other-search-engines).
Many other application buckets hosted on GitHub can be found on [ScoopSearch](https://scoop.sh/) or via [other search engines](https://rasa.github.io/scoop-directory/#other-search-engines).
24 changes: 15 additions & 9 deletions bin/checkver.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -226,15 +226,21 @@ $Queue | ForEach-Object {
$url = substitute $url $substitutions

$state = New-Object psobject @{
app = $name;
file = $file;
url = $url;
regex = $regex;
json = $json;
jsonpath = $jsonpath;
xpath = $xpath;
reverse = $reverse;
replace = $replace;
app = $name
file = $file
url = $url
regex = $regex
json = $json
jsonpath = $jsonpath
xpath = $xpath
reverse = $reverse
replace = $replace
}

get_config PRIVATE_HOSTS | Where-Object { $_ -ne $null -and $url -match $_.match } | ForEach-Object {
(ConvertFrom-StringData -StringData $_.Headers).GetEnumerator() | ForEach-Object {
$wc.Headers[$_.Key] = $_.Value
}
}

$wc.Headers.Add('Referer', (strip_filename $url))
Expand Down
8 changes: 4 additions & 4 deletions bin/scoop.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ switch ($subCommand) {
}
({ $subCommand -in @('-v', '--version') }) {
Write-Host 'Current Scoop version:'
if ((Test-CommandAvailable git) -and (Test-Path "$PSScriptRoot\..\.git") -and (get_config SCOOP_BRANCH 'master') -ne 'master') {
git -C "$PSScriptRoot\.." --no-pager log --oneline HEAD -n 1
if (Test-GitAvailable -and (Test-Path "$PSScriptRoot\..\.git") -and (get_config SCOOP_BRANCH 'master') -ne 'master') {
Invoke-Git -Path "$PSScriptRoot\.." -ArgumentList @('log', 'HEAD', '-1', '--oneline')
} else {
$version = Select-String -Pattern '^## \[(v[\d.]+)\].*?([\d-]+)$' -Path "$PSScriptRoot\..\CHANGELOG.md"
Write-Host $version.Matches.Groups[1].Value -ForegroundColor Cyan -NoNewline
Expand All @@ -31,9 +31,9 @@ switch ($subCommand) {

Get-LocalBucket | ForEach-Object {
$bucketLoc = Find-BucketDirectory $_ -Root
if ((Test-Path "$bucketLoc\.git") -and (Test-CommandAvailable git)) {
if (Test-GitAvailable -and (Test-Path "$bucketLoc\.git")) {
Write-Host "'$_' bucket:"
git -C "$bucketLoc" --no-pager log --oneline HEAD -n 1
Invoke-Git -Path $bucketLoc -ArgumentList @('log', 'HEAD', '-1', '--oneline')
Write-Host ''
}
}
Expand Down
2 changes: 1 addition & 1 deletion buckets.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"main": "https://github.com/ScoopInstaller/Main",
"extras": "https://github.com/ScoopInstaller/Extras",
"versions": "https://github.com/ScoopInstaller/Versions",
"nirsoft": "https://github.com/kodybrown/scoop-nirsoft",
"nirsoft": "https://github.com/ScoopInstaller/Nirsoft",
"sysinternals": "https://github.com/niheaven/scoop-sysinternals",
"php": "https://github.com/ScoopInstaller/PHP",
"nerd-fonts": "https://github.com/matthewjberger/scoop-nerd-fonts",
Expand Down
Loading