skaji / cpm

fast CPAN client
https://metacpan.org/dist/App-cpm
Other
170 stars 36 forks source link

ambiguous handling of local directories #252

Open haarg opened 1 month ago

haarg commented 1 month ago

When running cpm install $module, if $module matches a directory that exists, it will try to install from that directory. This is ambiguous with some module names. I ran into this with the module lib. Where normally lib would be ignored as up to date, if the lib directory exist it will fail.

Admittedly, a core only library like lib is not particularly useful to try to install. But for my use case, I am giving cpm the full list of declared prerequisites from a module, and some modules list those core only modules as prereqs. I've needed to add exceptions to filter out lib.

It would be preferable if there was either a way force always resolving arguments as module names, or if installing paths required a /, either as an absolute path or . relative (./some-path).

skaji commented 1 month ago

Duplicate of https://github.com/skaji/cpm/issues/217