just icon indicating copy to clipboard operation
just copied to clipboard

@microsoft/just could provide a known issue and/or a warning if another cli has been detected in $PATH.

Open peterkc opened this issue 6 years ago • 4 comments

casey/just has been using the the cli name just since 11/2017. Perhaps consider using just-cli instead to avoid the conflict?

peterkc avatar Jul 19 '19 23:07 peterkc

oh interesting - do you mean npx just would cause an issue here?

kenotron avatar Jul 30 '19 20:07 kenotron

@kenotron

Given:

  • casey/just is installed to /usr/local/bin/just
  • @microsoft/just is install and available at ./node_modules/.bin/just

@microsoft/just will have a higher priority over /usr/local/bin/just for npm run and npx just.

If a project is using a Justfile, then /usr/local/bin/just will not work.

To resolve the conflicts and have both cli coexists, users would have the following options.

"scripts": {
  "use-ms-just-option-1": "npx just task-name",
  "use-ms-just-option-2": "./node_modules/.bin/just task-name",
  "use-casey-just-option-1": "/usr/local/bin/just task-name",
  "use-casey-just-option-2": "just-alias task-name",
  "use-casey-just-option-3": "./Justfile task-name",
},

For @microsoft/just:

  • use npx just
  • ./node_modules/.bin/just

For casey/just:

  • use absolute path
  • create a symlink _just -> /usr/local/bin/just
  • a shebang in Justfile (i.e. #!/usr/bin/env just --justfile)

@microsoft/just could provide a known issue and/or a warning if another cli has been detected in $PATH.

peterkc avatar Jul 30 '19 23:07 peterkc

@microsoft/just could provide a known issue and/or a warning if another cli has been detected in $PATH.

Oh that's an interesting feature... I'm going to rename this issue so to reflect this idea.

kenotron avatar Jul 31 '19 17:07 kenotron

Issues seem to have gone stale.

github-actions[bot] avatar Mar 08 '20 00:03 github-actions[bot]