0

Specifically I have a conflict with using cup parser generator and chocolatey. Both have a command "cup" with chocolatey's "cup" meaning choco upgrade. Is there any way I can specify which command the command line should use? Or replace one command with a different word?

  • Run `where.exe cup` to find the fully-qualified path. This will list all "cup" + ext files found in `PATH`, where the extensions are taken from the `PATHEXT` environment variable. Use the full path in a shell shortcut (.LNK) that's stored in a common directory for scripts and shortcuts that's set in the `PATH` environment variable. Use an empty "start in" directory in the shortcut to inherit the shell's current directory. Add ".LNK" to `PATHEXT` to run shortcuts from the command line without having to type the ".lnk" file extension. – Eryk Sun Oct 08 '19 at 18:02
  • How do I create a .LNK shortcut? Do I have to create this common directory? And I am pretty lost on this part " Use an empty "start in" directory in the shortcut to inherit the shell's current directory." – GHizzle Oct 08 '19 at 19:22
  • Creating a shortcut using the Windows shell and modifying environment variables are common tasks. You can find many tutorials. Create a directory for scripts and shortcuts to programs in your profile directory. Name it whatever you want, e.g. "Scripts". When you create a shortcut to a file in this directory, you'll see a "start in" field; leave this blank. Add the full path to this directory to your per-user `PATH`, and add ".LNK" to `PATHEXT`. Note that these variables are delimited by semicolon, and they should contain no double or single quote characters, even if a path contains spaces. – Eryk Sun Oct 08 '19 at 23:52

0 Answers0