rucker / dotfiles-manager

A script to compile your dotfiles!
MIT License
8 stars 0 forks source link

[dfm.py] [Windows] Fails to execute due to python3 shebang line #51

Open rucker opened 3 years ago

rucker commented 3 years ago

Under git-bash execution fails (output below). On Unix-like systems, the Python 3 binary is typically python3. This is untrue on Windows, at least when Python 3 is installed via Chocolatey.


IEUser@MSEDGEWIN10 MINGW64 ~/bin
$ which python
/c/Python39/python

IEUser@MSEDGEWIN10 MINGW64 ~/bin
$ python --version
Python 3.9.6

IEUser@MSEDGEWIN10 MINGW64 ~/bin
$ ./dfm
/usr/bin/env: ‘python3’: No such file or directory
rucker commented 1 year ago

Due to various installation options on Windows (App Store, python.org installer, chocolatey...), each having different ideas of installation location, PATH updating, and whether a python3.exe is installed, the simplest workaround may be to symlink /python/install/dir/python3 -> /python/install/dir/python.