dfrankland / hyper-tab-icons

💅 Icons in the header tabs for the current running process in Hyper.app.
91 stars 16 forks source link

Icon not updating #15

Closed anirudhb closed 7 years ago

anirudhb commented 7 years ago

Hyper 0.8.3 hyper-tab-icons 1.1.2

How to reproduce

  1. Download a plugin like hyperterm-title or use the git-HEAD version of Hyper.app
  2. Change the title to a custom title that is not the process name
  3. Observe

When I start Python, or Node.js, or Ruby, the icon seems to stay as a shell.

Could this have something to do with me having a different title than the process name? If so, could there be a way to fix it?

anirudhb commented 7 years ago

How could you run a command inside the current shell and get the output? This would help to find the icon.

dfrankland commented 7 years ago

I can't reproduce this on Hyper.app@0.8.3 and hyper-tab-icons@1.1.2. There's no good way to know what the current running process is inside of another shell. This applies to things like the following:

anirudhb commented 7 years ago

Change the title with a plugin like hyperterm-title to a different title than the currently running process, then try.

dfrankland commented 7 years ago

I use hyperterm-title too. Make sure that hyperterm-tab-icons is after hyperterm-title like the following:

module.exports = {
  config: { ... },
  plugins: [
    'hyperterm-title',  // Shows title suggested by shell, this runs first
    'hyper-tab-icons',  // Show icon for current process, this runs second and gets the result of `hyperterm-title`
  ],
};
anirudhb commented 7 years ago

Still doesn't work (with custom title)

anirudhb commented 7 years ago

Even vice-versa.

dfrankland commented 7 years ago

This merge breaks hyperterm-title: https://github.com/zeit/hyper/pull/892

Essentially Hyper.app@0.8.4 will make hyperterm-title unneeded since the functionality will be built in 👍

dfrankland commented 7 years ago

So to fix this issue, if you are using Hyper.app@HEAD instead of the official 0.8.3 release please do not use hyperterm-title.

anirudhb commented 7 years ago

I'm not using Hyper.app@HEAD, I'm using 0.8.3

dfrankland commented 7 years ago

I am confused. Your "how to reproduce" in the initial issue says you are:

How to reproduce

  1. Download a plugin like hyperterm-title or use the git-HEAD version of Hyper.app

If you are actually using hyperterm-title and Hyper.app@0.8.3 (the official release version downloaded from here), I cannot reproduce the issue.

Is there any other information you could provide me?

anirudhb commented 7 years ago

Starting from dock, macOS sierra, plugins list:

anirudhb commented 7 years ago

It was downloaded from hyper.is

anirudhb commented 7 years ago

Just to clarify: the icon is showing up but it is not updating to the correct icon

anirudhb commented 7 years ago

0.8.3.873

dfrankland commented 7 years ago

Using all of the same plugins, on macOS Sierra, using Hyper.app@0.8.3.373, launching from the toolbar. I still cannot reproduce this; all of the correct icons show up.

anirudhb commented 7 years ago

Make sure the process name is not in the title.

anirudhb commented 7 years ago

Some code: PROMPT_COMMAND='echo -ne "\033]0;blah\007"'

anirudhb commented 7 years ago

With say, PS1="$ "

anirudhb commented 7 years ago

And no DEBUG trap

dfrankland commented 7 years ago

Ah, setting the title to an arbitrary string will break this plugin. This plugin is a presentational component only. See the "How it Works" section in the README. All it does is look at the title provided by Hyper.app and shows an icon it thinks best matches it using fuzzy filtering.

Arttse commented 7 years ago

Same problem for me. Icon simply does not change. For purity, I'm use only this plugin.

hyper-tab-icons


Hyper 1.0.0 hyper-tab-icons 1.1.2 Linux Ubuntu 16.04 Using zsh by default.

dfrankland commented 7 years ago

@Arttse, this is a slightly different issue. I've opened another issue for the problem you are seeing here: https://github.com/dfrankland/hyper-tab-icons/issues/17

Good catch btw!

Arttse commented 7 years ago

@dfrankland thanks for quick response! I thought that the problem is in the icon change, so I wrote here. It is not clear how it should look on Linux. Well, thanks again, I'll be waiting for improvements :+1:

dfrankland commented 7 years ago

This should be fixed with hyper-tab-icons@1.1.3 now. See here: https://github.com/dfrankland/hyper-tab-icons#configtabiconsprocessnameregex