Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance the Installation for Windows CMD #254

Open
Hamster5295 opened this issue Nov 9, 2024 · 0 comments
Open

Enhance the Installation for Windows CMD #254

Hamster5295 opened this issue Nov 9, 2024 · 0 comments

Comments

@Hamster5295
Copy link

The autojump.exe itself is not sufficient to provide the expected function on windows cmd prompt, while installing the python autojump and overriding the script cause confusion. There could be better approaches.

The python autojump actually does 2 things through installation:

  1. Adding the path to the scripts to the PATH env.
  2. Binding autojump.lua to clink so that the script can hook and record the changes in working directories.

The Powershell requires extra intergrations, which is absent currently.

As for Windows CMD, it's possible to provide some other approaches for installation.

Install Script

This can be achieved through the following steps:

  1. Include autojump.lua and those .bat scripts into the windows_msvc package.
  2. Add a install.bat or what to the package. The script can be something like this:
REM Setting the PATH env varible
setx /m PATH "%PATH%;%~dp0"

REM Bind autojump.lua to clink
REM TODO: Warn user when clink is not present
clink installscripts "%~dp0"

Scoop

The Scoop package manager has added this project into the 'extras' bucket(A manifest that explains where and how to install a software). See ScoopInstaller/Extras#8377
Currently the scoop-installed autojump-rs cannot function as well, due to the same reason given. However, scoop provides the ability to run scripts at installation / uninstallation as well as dependency lookup, which make it possible to automaticly check the presence of clink and configure the environment.

  1. Include autojump.lua and those .bat scripts into the windows_msvc package. This is the same as above
  2. Modify the scoop manifest for auto installation, dependency check and more: https://github.com/ScoopInstaller/Extras/blob/master/bucket/autojump.json
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant