henrikruscon / hyper-statusline

Status Line Plugin for Hyper
MIT License
386 stars 79 forks source link

Would love to contribute to this project but I'm confused by the PID usage #81

Open rfgamaral opened 6 years ago

rfgamaral commented 6 years ago

I use Hyper with WSL and this plugin doesn't work with it (see #75). I'm trying to fix that but I come across one thing that is confusing me and I'm not sure how to proceed until I understand what is going on.

Please take a look at:

Why do we need to get the PID on SESSION_SET_XTERM_TITLE and then do nothing with it? I mean:

So, is handling SESSION_SET_XTERM_TITLE really needed? Do we really need to read the PID here? If so, why?

Would really like to understand this as I'm not sure how to proceed to fix #75 without understanding this bit of the code base.

j-f1 commented 6 years ago

If it’s possible to fetch the PID in SESSION_ADD_DATA, then the pid global and the SESSION_SET_XTERM_TITLE section seem to be unnecessary.

rfgamaral commented 6 years ago

@j-f1 But why do we even need to fetch the PID in SESSION_ADD_DATA? The one we currently have when that event is dispatch should be the correct one, we don't need to fetch it again. What am I missing?

rfgamaral commented 6 years ago

@henrikdahl Could you provide some input here please?

j-f1 commented 5 years ago

Feel free to open a PR on my fork. I’ll be happy to review and get the changes published!