[X] I have searched all issues/PRs to ensure it has not already been reported or fixed.
[X] I have verified that I am using the latest version of Scoop and corresponding bucket.
Package Name
Git (and others probably)
Expected/Current Behaviour
When I call scoop from Ansible to install a list of packages it appears to re-install packages that are already installed.
There is no --reinstall flag provided, nor does it exist, it just attempts to reinstall every package specified as argument regardless of whether it's already installed or not. The issue with this behavior is that when you call scoop from a bash instance spawned by OpenSSH installing git package fails due to use of the bash process.
Steps to Reproduce
admin@windows-01 MINGW64 ~
$ scoop info git | grep version
Description : Distributed version control system
Version : 2.45.2
admin@windows-01 MINGW64 ~
$ scoop install --global git@2.45.2
Installing 'git' (2.45.2) [64bit] from 'C:\Users\admin\scoop\buckets\main\bucket\git.json'
Loading PortableGit-2.45.2-64-bit.7z.exe from cache
Checking hash of PortableGit-2.45.2-64-bit.7z.exe ... ok.
Extracting dl.7z ... ERROR Exit code was 2!
Failed to extract files from C:\ProgramData\scoop\apps\git\2.45.2\dl.7z.
Log file:
C:\ProgramData\scoop\apps\git\2.45.2\7zip.log
Please try again or create a new issue by using the following link and paste your console output:
https://github.com/ScoopInstaller/Main/issues/new?title=git%402.45.2%3a+decompress+error
admin@windows-01 MINGW64 ~
$ tail -n4 'C:\ProgramData\scoop\apps\git\2.45.2\7zip.log'
ERROR: Cannot delete output file : Access is denied. : C:\ProgramData\scoop\apps\git\2.45.2\bin\bash.exe
ERROR: Cannot delete output file : Access is denied. : C:\ProgramData\scoop\apps\git\2.45.2\usr\bin\bash.exe
ERROR: Cannot delete output file : Access is denied. : C:\ProgramData\scoop\apps\git\2.45.2\usr\bin\msys-2.0.dll
ERROR: Cannot delete output file : Access is denied. : C:\ProgramData\scoop\apps\git\2.45.2\usr\bin\sh.exe
Possible Solution
Do not reinstall packages that are already installed.
Or provide an explicit --no-reinstall or --reinstall flags.
Scoop and Buckets Version
$ scoop --version
Current Scoop version:
d337bb1f (HEAD -> master, tag: v0.4.2, origin/master, origin/HEAD) chore(release): Bump to version 0.4.2 (#5964)
'main' bucket:
e49e18cfb (HEAD -> master, origin/master, origin/HEAD) tup: Update to version 0.8-8
'extras' bucket:
a105a9577 (HEAD -> master, origin/master, origin/HEAD) virtualhere-client: Update to version 5.6.6
'java' bucket:
22628523 (HEAD -> master, origin/master, origin/HEAD) temurin17-nightly-jre: Update to version 17.0.12-5.0.ea
Prerequisites
Package Name
Git (and others probably)
Expected/Current Behaviour
When I call
scoop
from Ansible to install a list of packages it appears to re-install packages that are already installed.There is no
--reinstall
flag provided, nor does it exist, it just attempts to reinstall every package specified as argument regardless of whether it's already installed or not. The issue with this behavior is that when you callscoop
from abash
instance spawned by OpenSSH installinggit
package fails due to use of thebash
process.Steps to Reproduce
Possible Solution
Do not reinstall packages that are already installed. Or provide an explicit
--no-reinstall
or--reinstall
flags.Scoop and Buckets Version
Scoop Config
PowerShell Version
Additional Softwares
No response