Can INSTALL-CHOCOLATEYPACKAGE do xcopy for the exe file in toolsDir. #2461
Replies: 7 comments
-
@moh-hassan You can use https://docs.chocolatey.org/en-us/create/functions/get-chocolateywebfile |
Beta Was this translation helpful? Give feedback.
-
Thanks @TheCakeIsNaOH for reply. |
Beta Was this translation helpful? Give feedback.
-
If you have a normal installation of Chocolatey, then choco should be run with administrative privileges, in which case choco would have write permissions into the If you have a user level installation of Chocolatey, then the
Here is an example of a package downloading an exe with |
Beta Was this translation helpful? Give feedback.
-
I used the script you guided me, and the package is installed successfully. 👍 with the message:
Thanks for support |
Beta Was this translation helpful? Give feedback.
-
Here is information about shims: |
Beta Was this translation helpful? Give feedback.
-
Now, it's clear why two files. |
Beta Was this translation helpful? Give feedback.
-
This isn't an issue with Chocolatey, so I've moved it over to a discussion. If that changes, we can always move it back. |
Beta Was this translation helpful? Give feedback.
-
I have a package with script 'chocolateyInstall.ps1' that call the command 'INSTALL-CHOCOLATEYPACKAGE' and download remote URL of exe file (not a setup).
Although the installation is successful, the package is not ready to run because the exe is not available in the toolsDir.
Install-ChocolateyPackage command download the file in a temporary location but didn't copy the file to the toolsDir.
I have to zip the file and use the command 'Install-ChocolateyZipPackage' which copy the exe to toolsDir and is working fine.
It's nice if the command 'INSTALL-CHOCOLATEYPACKAGE' can do xcopy of the exe file(s) as if it's portable package without imbedding the exe in the package.
Beta Was this translation helpful? Give feedback.
All reactions