atom / chocolatey

chocolatey installer for Atom
MIT License
12 stars 17 forks source link

Switch From .exe Shim To Batch File #23

Closed joefitzgerald closed 10 years ago

joefitzgerald commented 10 years ago

Adding another line like https://github.com/atom/chocolatey/blob/master/chocolatey/tools/chocolateyInstall.ps1#L27 for atom.bat (Install-BinFile "apm" "$dest\Atom\atom.exe") would fix issues described:

Removing the atom.exe file from %ALLUSERSPROFILE%\Chocolatey\bin\atom.exe and replacing it with %ALLUSERSPROFILE%\Chocolatey\bin\atom.bat with the following content allows specs to run via apm test and allows atom . or atom c:\windows to work.

@echo off
SET DIR=%~dp0%
cmd /c "%DIR%..\lib\atom.0.115.0\tools\atom\atom.exe %*"
exit /b %ERRORLEVEL%

What's the rationale for the .exe shim vs a .bat?

joefitzgerald commented 10 years ago

Also, @kevinsawicki I'd be happy to make a PR against https://github.com/atom/ci and / or help you with an article on AppVeyor if you'd like.

joefitzgerald commented 10 years ago

@kevinsawicki for your reference: