nimble
nimble copied to clipboard
FR: verify and satisfy the dependencies, separately from `nimble build`
It would be nice for nimble to have a way for installing a list of dependencies in the same way it does with nimble build
.
The case is: I'm writing a package file for a GNU/Linux distributive and would like to use nimble to install dependencies automatically, without an interactive prompt. However, if I use nimble install -y
for this, nimble overwrites currently installed packages in its cache. This is problematic in case a user has local changes in those dirs, one example is having symlinks from nimble develop
there. If a user has a proper *.nimble
config for it's package, nimble build
does the correct thing: it satisfies the dependencies but doesn't overwrite anything present. However, If I needed to build the package in some other way (for example, directly with nim c
), I would have no way of using nimble to just satisfy the dependencies without the overwriting behaviour of nimble install -y
.
Possible solutions:
- Add a separate command to satisfy the dependencies, provided as arguments:
nimble --satisfy threading>=0.1.0,cligen>=1.5.0
- Have a separate argument for
nimble install
which would prevent interactive prompts but won't reinstall already present packages.
Workaround:
Set --nimbleDir
to a temporary folder and use nimble install -y
Not sure if it helps but you can also do nimble c ...
It requires completely different design. Nimble is a package manager, not a build system.
It requires completely different design. Nimble is a package manager, not a build system.
I'm not sure I understand you.
- This FR asks for a split of a functionality Nimble already has.
- It's exactly about extracting the package management from the build process to allow more flexibility in the latter.