Skip to content

Instantly share code, notes, and snippets.

@hyrious
Created December 12, 2020 16:03
Show Gist options
  • Save hyrious/754a8ff3134750fdb381b6e090fd493e to your computer and use it in GitHub Desktop.
Save hyrious/754a8ff3134750fdb381b6e090fd493e to your computer and use it in GitHub Desktop.
scoop use fastgit
# put these code after scoop/apps/scoop/current/lib/manifest.ps1
$_old_url = $function:url
function url($manifest, $arch) {
$url = & $_old_url $manifest $arch
if ($url -like 'https://github.com/*/*/releases/download/*') {
$url = $url -replace 'https://github.com', 'https://download.fastgit.org'
}
$url
}
# i guess scoop should provide some plugin api...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment