Describe the bug
editAtLine: '"C:\Program Files\Notepad++\notepad++.exe" -n{{line}} {{filename}}'
works, but
editAtLineAndWait: '"C:\Program Files\Notepad++\notepad++.exe" -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
fails with 'C:\Program' is not recognized as an internal or external command, operable program or batch file.
To Reproduce
Steps to reproduce the behavior:
- Use the following editor commands:
# %LOCALAPPDATA%\lazygit\config.yml
os:
edit: '"C:\Program Files\Notepad++\notepad++.exe" {{filename}}'
editAtLine: '"C:\Program Files\Notepad++\notepad++.exe" -n{{line}} {{filename}}'
editAtLineAndWait: '"C:\Program Files\Notepad++\notepad++.exe" -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
- Try to trigger "edit" by pressing e on a file.
- Try to trigger "editAtLine" by pressing e inside patch panel.
- Observe that both of these work without issues.
- Try to trigger "editAtLineAndWait" by pressing upper-case E (edit hunk) inside patch panel.
- Observe the failure to launch the editor.
Expected behavior
editAtLineAndWait should work the same way as editAtLine and properly launch Notepad++.
Version info:
commit=d167063b4f45d044524f3fba97f850d1eec3f95c, build date=2026-04-13T20:06:40Z, build source=binaryRelease, version=0.61.1, os=windows, arch=amd64, git version=2.54.0.windows.1
Terminal info:
Windows Terminal, Version: 1.24.10921.0
Additional context
What I've tried to make it work so far:
editAtLineAndWait: 'C:\\Program\ Files\\Notepad++\\notepad++.exe -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: 'C:\Program^ Files\Notepad++\notepad++.exe -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: 'C:\Program" "Files\Notepad++\notepad++.exe -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: '\"C:\\Program Files\\Notepad++\\notepad++.exe\" -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: '\"C:\\Program\ Files\\Notepad++\\notepad++.exe\" -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: '\"C:\Program Files\Notepad++\notepad++.exe\" -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
editAtLineAndWait: '''C:\Program Files\Notepad++\notepad++.exe'' -multiInst -nosession -noPlugin -n{{line}} {{filename}}'
All failing the exact same way.
I believe a better way to implement command configs is to make them arrays instead. This would allow lazygit to handle quotes correctly for all platforms/shells and remove any guess-work for the user.
editAtLineAndWait: ['C:\Program Files\Notepad++\notepad++.exe', '-multiInst', '-nosession', '-noPlugin', '-n{{line}}', '{{filename}}']
I don't know how easy it is to allow both arrays and strings for the same key.
Describe the bug
works, but
fails with
'C:\Program' is not recognized as an internal or external command, operable program or batch file.To Reproduce
Steps to reproduce the behavior:
Expected behavior
editAtLineAndWaitshould work the same way aseditAtLineand properly launch Notepad++.Version info:
commit=d167063b4f45d044524f3fba97f850d1eec3f95c, build date=2026-04-13T20:06:40Z, build source=binaryRelease, version=0.61.1, os=windows, arch=amd64, git version=2.54.0.windows.1
Terminal info:
Windows Terminal, Version: 1.24.10921.0
Additional context
What I've tried to make it work so far:
All failing the exact same way.
I believe a better way to implement command configs is to make them arrays instead. This would allow lazygit to handle quotes correctly for all platforms/shells and remove any guess-work for the user.
I don't know how easy it is to allow both arrays and strings for the same key.