vercel / hyper

A terminal built on web technologies
https://hyper.is
MIT License
43.46k stars 3.52k forks source link

Support home-relative paths by expanding `~` #8039

Open jaraco opened 1 month ago

jaraco commented 1 month ago

Is your feature request related to a problem? Please describe. I'd like to be able to share my hyper config without having to customize it to each host, but due to corporate restrictions, my username must be different on these different hosts. Therefore, the shell configuration variable must necessarily be different on each machine. For example:

    shell: '\\Users\\jaraco\\.local\\bin\\xonsh.exe',
    shell: '\\Users\\jaraco2\\.local\\bin\\xonsh.exe',

If the hyper configuration would allow for home-relative paths, it would make it possible to declare this config in one way on both hosts:

    shell: '~\\.local\\bin\\xonsh.exe',

Describe the solution you'd like

For any config item that references a path, allow the path to contain ~ and expand it to the user's home directory.