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

[Feature Request] Open Terminus here in Windows 10 Context Menu #362

Closed
yxuko opened this issue Jun 7, 2018 · 2 comments
Closed

[Feature Request] Open Terminus here in Windows 10 Context Menu #362

yxuko opened this issue Jun 7, 2018 · 2 comments

Comments

@yxuko
Copy link
Contributor

yxuko commented Jun 7, 2018

Hello,
It would be great if in Windows 10 Context menu there is an option Open Terminus here so that commands run would be running directly from that directory

@QWp6t
Copy link

QWp6t commented Jul 27, 2018

This is a script I wrote for myself. You can use it to add any other right-click options to folders in explorer by editing the variables at the top. It modifies HKCU to ensure it only affects the current user.

Edit: I should have mentioned that this requires you to hold shift while right-clicking. That's because of the empty "Extended" value that I added. Just remove each line in the script that says "Extended" if you don't want to have to hold shift while right-clicking.

@echo off
set ICON=%LocalAppData%\terminus\Terminus.exe
set LABEL=Open terminal here
set COMMAND=%LocalAppData%\terminus\Terminus.exe \"%%V\"
set SLUG=Terminal

reg delete "HKCU\Software\Classes\Directory\Background\shell\%SLUG%" /f
reg delete "HKCU\Software\Classes\Directory\shell\%SLUG%" /f
reg delete "HKCU\Software\Classes\Drive\shell\%SLUG%" /f
reg delete "HKCU\Software\Classes\LibraryFolder\Background\shell\%SLUG%" /f

reg add "HKCU\Software\Classes\Directory\Background\shell\%SLUG%" /f /ve /t REG_SZ /d "%LABEL%"
reg add "HKCU\Software\Classes\Directory\Background\shell\%SLUG%" /f /v "Extended" 
reg add "HKCU\Software\Classes\Directory\Background\shell\%SLUG%" /f /v "Icon" /t REG_SZ /d "%ICON%"
reg add "HKCU\Software\Classes\Directory\Background\shell\%SLUG%\command" /f /ve /t REG_SZ /d "%COMMAND%"
reg add "HKCU\Software\Classes\Directory\shell\%SLUG%" /f /ve /t REG_SZ /d "%LABEL%"
reg add "HKCU\Software\Classes\Directory\shell\%SLUG%" /f /v "Extended" 
reg add "HKCU\Software\Classes\Directory\shell\%SLUG%" /f /v "Icon" /t REG_SZ /d "%ICON%"
reg add "HKCU\Software\Classes\Directory\shell\%SLUG%\command" /f /ve /t REG_SZ /d "%COMMAND%"
reg add "HKCU\Software\Classes\Drive\shell\%SLUG%" /f /ve /t REG_SZ /d "%LABEL%"
reg add "HKCU\Software\Classes\Drive\shell\%SLUG%" /f /v "Extended" 
reg add "HKCU\Software\Classes\Drive\shell\%SLUG%" /f /v "Icon" /t REG_SZ /d "%ICON%"
reg add "HKCU\Software\Classes\Drive\shell\%SLUG%\command" /f /ve /t REG_SZ /d "%COMMAND%"
reg add "HKCU\Software\Classes\LibraryFolder\Background\shell\%SLUG%" /f /ve /t REG_SZ /d "%LABEL%"
reg add "HKCU\Software\Classes\LibraryFolder\Background\shell\%SLUG%" /f /v "Extended" 
reg add "HKCU\Software\Classes\LibraryFolder\Background\shell\%SLUG%" /f /v "Icon" /t REG_SZ /d "%ICON%"
reg add "HKCU\Software\Classes\LibraryFolder\Background\shell\%SLUG%\command" /f /ve /t REG_SZ /d "%COMMAND%"

@yxuko
Copy link
Contributor Author

yxuko commented Jul 27, 2018

That's great, thank you for the effort even I actually wanted the extended way
I wanted it to be included by default in terminus

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants