Note
This is still under development. It currently does not replace even close to all the scoop commands, and is missing a lot of functionality. There is unlikely to be any breaking changes, so there is likely no harm using it as is.
Super fast replacements and additions to scoop commands written in Rust
scoop bucket add extras
scoop install sfsu
You may set up the hooks to use the scoop commands normally
Add the following to your Powershell profile
Invoke-Expression (&sfsu hook)
You can also optionally disable certain hooks via the --disable <COMMAND>
flag
Invoke-Expression (&sfsu hook --disable list)
It also supports Bash in WSL and MSYS2
Add the following to your .bashrc (or its equivalents, i.e .zshrc) file
source <(sfsu.exe hook --shell bash)
Nushell is also supported. Run the following command save it to a file.
sfsu hook --shell nu | save -f path/to/some/file.nu
Then source it in your config.nu
(situated in path $nu.config-path
).
source path/to/the/file.nu
The above disable demonstration also works
Benchmarks 1
Note
These benchmarks may not accurately represent the speeds on your system. While they do provide a relative measurement, your environment and results will be different.
On average, sfsu search
is ~400 times faster than regular scoop search
and ~5 times faster than scoop-search.
sfsu list
is ~35 times faster than scoop list
sfsu
and hok
are pretty comperable in all benchmarks. sfsu
wins some benchmarks and hok
wins others.
Done on a AMD Ryzen 9 7900X @ 5.5GHz with 32GB of RAM at 4800MHz and 11 scoop buckets listed below
Searching 2
$ hyperfine --warmup 5 'sfsu search google' 'hok search google' 'scoop-search google' 'scoop search google'
Benchmark 1: sfsu search google
Time (mean ± σ): 32.0 ms ± 2.1 ms [User: 0.4 ms, System: 2.4 ms]
Range (min … max): 29.5 ms … 44.5 ms 78 runs
Benchmark 2: hok search google
Time (mean ± σ): 37.8 ms ± 1.6 ms [User: 2.2 ms, System: 2.2 ms]
Range (min … max): 34.5 ms … 44.2 ms 65 runs
Benchmark 3: scoop-search google
Time (mean ± σ): 352.6 ms ± 29.9 ms [User: 14.1 ms, System: 78.1 ms]
Range (min … max): 325.2 ms … 415.2 ms 10 runs
Benchmark 4: scoop search google
Time (mean ± σ): 12.031 s ± 0.192 s [User: 3.400 s, System: 6.475 s]
Range (min … max): 11.756 s … 12.464 s 10 runs
Summary
sfsu search google ran
1.18 ± 0.09 times faster than hok search google
11.03 ± 1.17 times faster than scoop-search google
376.34 ± 24.89 times faster than scoop search google
Listing 3
$ hyperfine --warmup 5 'sfsu list' 'hok list' 'scoop list'
Benchmark 1: sfsu list
Time (mean ± σ): 41.3 ms ± 1.6 ms [User: 3.1 ms, System: 11.2 ms]
Range (min … max): 39.2 ms … 45.1 ms 63 runs
Benchmark 2: hok list
Time (mean ± σ): 32.4 ms ± 0.9 ms [User: 3.9 ms, System: 13.7 ms]
Range (min … max): 30.9 ms … 35.6 ms 84 runs
Benchmark 3: scoop list
Time (mean ± σ): 1.147 s ± 0.019 s [User: 0.531 s, System: 0.251 s]
Range (min … max): 1.121 s … 1.183 s 10 runs
Summary
hok list ran
1.27 ± 0.06 times faster than sfsu list
35.34 ± 1.14 times faster than scoop list
Info 4
Hok does not have the Updated at
and Updated by
fields.
As such, for the sake of fairness, I have split the benchmark in two.
The first benchmark compares sfsu
without these fields to Hok,
and the second benchmark compares sfsu
with these fields to Scoop.
$ hyperfine --warmup 5 'sfsu info sfsu --disable-updated' 'hok info sfsu'
Benchmark 1: sfsu info sfsu --disable-updated
Time (mean ± σ): 63.1 ms ± 9.4 ms [User: 0.6 ms, System: 15.0 ms]
Range (min … max): 53.9 ms … 90.7 ms 53 runs
Benchmark 2: hok info sfsu
Time (mean ± σ): 133.0 ms ± 19.1 ms [User: 7.4 ms, System: 29.8 ms]
Range (min … max): 111.9 ms … 181.7 ms 21 runs
Summary
sfsu info sfsu --disable-updated ran
2.11 ± 0.44 times faster than hok info sfsu
$ hyperfine --warmup 5 'sfsu info sfsu' 'scoop info sfsu'
Benchmark 1: sfsu info sfsu
Time (mean ± σ): 425.3 ms ± 57.4 ms [User: 86.3 ms, System: 114.7 ms]
Range (min … max): 350.6 ms … 526.7 ms 10 runs
Benchmark 2: scoop info sfsu
Time (mean ± σ): 814.6 ms ± 47.2 ms [User: 153.4 ms, System: 192.8 ms]
Range (min … max): 756.4 ms … 902.8 ms 10 runs
Summary
sfsu info sfsu ran
1.92 ± 0.28 times faster than scoop info sfsu
dorado https://github.com/chawyehsu/dorado
emulators https://github.com/borger/scoop-emulators.git
extras https://github.com/ScoopInstaller/Extras
games https://github.com/Calinou/scoop-games
java https://github.com/ScoopInstaller/Java
lemon https://github.com/hoilc/scoop-lemon
main https://github.com/ScoopInstaller/Main
nirsoft https://github.com/kodybrown/scoop-nirsoft
personal https://github.com/jewlexx/personal-scoop.git
spotify https://github.com/TheRandomLabs/Scoop-Spotify.git
sysinternals https://github.com/niheaven/scoop-sysinternals.git
versions https://github.com/ScoopInstaller/Versions
The build instructions can be found in the wiki
I have a couple of long term goals.
Firstly, I want to create a Rust library to help interacting with Scoop from code. This library would allow for things like installing packages, running updates, etc. It will likely start by providing a function to get the Scoop install path, but hopefully over time it will grow into a fully fledged library, which is used internally by sfsu to interact with Scoop.
My other long term goal is to create a Scoop replacement for those who want it, in a similar vein as Shovel. This is a fairly large undertaking and will definitely take me a lot of time, so this is a very long term goal, and may never happen. Despite this I never really plan to replace Scoop. It is a great package manager and if anything sfsu
would just be a command you can run instead of Scoop, but would run on Scoop installations.
In the meantime I will continue working on this independently of Scoop as a collection of seperate tools that work in conjunction with Scoop.
Made with 💗 by Juliette Cordor
Footnotes
-
These benchmarks are done after warmups. You will likely see far greater improvements when run on "cold" systems. Results will also differ depending on search request and the number of results, as well as installed buckets, and a few other factors ↩
-
Run on sfsu version v1.8.3, Hok version v0.1.0-beta.4, scoop-search version 1.4.0 ↩
-
Run on sfsu version v1.6.3 and Hok version v0.1.0-beta.4 ↩
-
Run on sfsu version v1.6.3 and Hok version v0.1.0-beta.4 ↩