hharnisc / hypercwd

Opens new tabs with the same directory as the current tab in Hyper
MIT License
385 stars 39 forks source link

hyper windows git bash error #76

Open seonglae opened 4 years ago

seonglae commented 4 years ago

image

ankitshah009 commented 4 years ago

Any reason why this is happenning? I am notificing the same problem

seonglae commented 4 years ago

reinstall was my solution

gbroques commented 4 years ago

reinstall was my solution

Reinstall what? The hypercwd plugin or entire Hyper Terminal?

seonglae commented 4 years ago

entire hyper.js

YussufElarif commented 3 years ago

That doesn't seem to solve the issue on my end. Is it a specific version that works with hypercwd? @sungle3737

seonglae commented 3 years ago

Actually I'm using Windows Terminal, but my last version was 3.0.2

YussufElarif commented 3 years ago

Ah right, thanks. I've done a little bit more digging on this plugin. I stripped hypercwd to see what the issue was. Turns out it isn't actually hypercwd that is causing these issues, so reinstalling hyper.js seems like the responsible route to go and may have been the reason why it works for you now. I'll keep digging to see what it is that's causing this issue for me specifically and post it for anyone else that's having the same problem

YussufElarif commented 3 years ago

Unfortunately, couldn't do any more digging. Clumped up with my own work. I only got as far as knowing each tab generates a new bash instance but when dispatching "SESSION_SET_CWD", it doesn't change the cwd. It might be a windows thing or gitbash itself, not sure.

patcat commented 3 years ago

I'm finding the same issue on a new install of Hyper when using Windows Subsystem for Linux Bash. Not sure what it is :/

SebbeJohansson commented 3 years ago

I am having the same issue currently. Seems to be related to me trying to another tab when I have something running.

image

SkinnyPigeon commented 3 years ago

For those on WSL and are encountering the same issue, I wrote a simple bash function that sets the current working dir in the bashrc/zshrc file which is then cd'd into on opening a new tab. In the zshrc file include the lines: export HYPER_DIR=/home/your_user_name cd $HYPER_DIR

Then define a function in your zshenv file:

tab () {
  gawk -i inplace -v HYPER_DIR=$(pwd) '/export\ HYPER_DIR/ {$2="HYPER_DIR="HYPER_DIR}; {print}' ~/.zshrc 
}

Now you can call $ tab from the terminal to save the pwd dynamically and opening a new tab will automatically open In the current directory. I hope this helps someone as I could not get this to work any other way

JoanComasFdz commented 3 years ago

Same issue on:

Removing the plugin from the plugins array and the config and restarting Hyper fixed it for me, at the cost of not having that functionality.