tabtab icon indicating copy to clipboard operation
tabtab copied to clipboard

`yarn global ls` removes installed completions

Open tadayosi opened this issue 7 years ago • 1 comments

Using yarn I installed tabtab and yarn-completions globally:

$ sudo yarn global add tabtab
$ sudo yarn global add yarn-completions

Now you can see:

$ ll /usr/local/share/.config/yarn/global/node_modules/tabtab/.completions/
total 16K
-rw-r--r--. 1 root root 714 Oct  9  2016 gitbook.bash
-rw-r--r--. 1 root root 440 Oct  9  2016 gitbook.fish
-rw-r--r--. 1 root root 389 Oct 10  2016 gitbook.zsh
-rw-r--r--. 1 root root 696 May 25 16:16 yarn.bash

However, when I do sudo yarn global ls afterwards the installed yarn.bash disappears!!!

$ sudo yarn global ls
yarn global v0.24.5
warning No license field
info "[email protected]" has binaries:
   - tabtab
info "[email protected]" has binaries:
   - completions-yarn
Done in 1.22s.

$ ll /usr/local/share/.config/yarn/global/node_modules/tabtab/.completions/
total 12K
-rw-r--r--. 1 root root 714 Oct  9  2016 gitbook.bash
-rw-r--r--. 1 root root 440 Oct  9  2016 gitbook.fish
-rw-r--r--. 1 root root 389 Oct 10  2016 gitbook.zsh

It happens on both CentOS 7 (via yum repo / with sudo) and macOS (via brew / without sudo).

tadayosi avatar May 26 '17 01:05 tadayosi