vercel / hyper

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

#config-location Either your webpage is wrong or your program. #4242

Open zeilen opened 4 years ago

zeilen commented 4 years ago

Issue

Either your webpage is wrong or your program.

hyper.is/#config-location says for macOS the path to config file is ~/Library/Application Support/Hyper/.hyper.js and it says “config at ~/.hyper.js still supported”.

But when I start a freshly installed Hyper.app it creates ~/Lib…/App…Supp…/Hyper/ without .hyper.js and .hyper_plugins/ inside but creates ~/.hyper.js and ~/.hyper_plugins/. Even when I move them from my home dir to Hyper’s AppSupport dir. They are re-created.

Stanzilla commented 4 years ago

yeah the website is a bit outdated, thanks!

ppot commented 4 years ago

Well.. The documentation represent latest stable release. Not canary.

zeilen commented 4 years ago

I found out Hyper uses $XDG_CONFIG_HOME if set.

(3.0.2 is the latest stable release)

nicolaibach commented 4 years ago

@zeilen: on my system Hyper uses $XDG_CONFIG_HOME when launched via the cli command. Opening the .app still reads from ~/.hyper.js. Can you confirm that?

lewxdev commented 3 years ago

I can confirm that this is still an issue as of the current stable build (3.0.2) I tried to add export XDG_CONFIG_HOME=$HOME/Library/Application\ Support/Hyper to ~/.zshrc, but hyper still refuses to create or use the configuration files in the application directory (even after they've been moved or deleted from the home directory prior to launch) I made sure to use a fresh install via homebrew as well to avoid inconsistencies.

LabhanshAgrawal commented 3 years ago

@lewxdev try setting it via launchctl setenv refer this Hyper can't pick it up from zshrc if you're not starting it from cli

lewxdev commented 3 years ago

@lewxdev try setting it via launchctl setenv refer this Hyper can't pick it up from zshrc if you're not starting it from cli

@LabhanshAgrawal Thanks! That makes sense. This worked for me by running launchctl setenv XDG_CONFIG_HOME $HOME/Library/Application\ Support/Hyper. However I need to read more on how to keep the changes after reboot. The StackOverflow answer you sent references a command that specifically interfaces with the PATH environment variable.

LabhanshAgrawal commented 3 years ago

I'm not sure how to keep it after reboot, maybe you can get this command to run at startup?

lewxdev commented 3 years ago

@LabhanshAgrawal Possibly, may be simple enough if macOS has a crontab