registry icon indicating copy to clipboard operation
registry copied to clipboard

Download specific package version with Semver is awkward

Open calvinrp opened this issue 2 years ago • 3 comments

Currently, if you want to download a specific version the semver syntax is kind of awkward. Happy to close this issue, if others are OK with the current behavior.

Example: warg download namespace:package-name --version 0.1.0

This will match ^0.1.0 instead of =0.1.0.

In order to download the exact match: warg download namespace:package-name --version \=0.1.0

= needs to be escaped with \

calvinrp avatar Sep 27 '23 01:09 calvinrp

= needs to be escaped with \

What shell do you use? zsh sees = and \= as identical

lann avatar Sep 27 '23 14:09 lann

Anyway, I would agree that --version 0.1.0 ought to mean =0.1.0. We could check if the first char is a digit and prepend =, which would still let you do --version '^0.1.0' to get the current behavior.

lann avatar Sep 27 '23 14:09 lann

= needs to be escaped with \

What shell do you use? zsh sees = and \= as identical

Using zsh on MacOS. Doesn't work for me without escaping.

calvinrp avatar Sep 27 '23 14:09 calvinrp