]> _ Git - alire.git/commit
Add a -f, --force global switch (#435)
authorAlejandro R Mosteo <alejandro@mosteo.com>
Mon, 8 Jun 2020 15:32:15 +0000 (17:32 +0200)
committerGitHub <noreply@github.com>
Mon, 8 Jun 2020 15:32:15 +0000 (17:32 +0200)
commit1a67a0d52f2e3fae9a44ee6c287bffd9eba93e9a
treea19ab927b09478417d9314ca3be025e3972ef823
parenta328f1fdc24fd1d02b2d79dc2dd56334a99ab1fc
Add a -f, --force global switch (#435)

This global modifier is available in Alire.Force. Other candidate locations,
like Alire.Config, Alire.Errors, Alire.Utils.User_Input cannot be used because
they bring in non-preelaborable units and it snowballs from there.

The recommended usage is through Alire.Recoverable_Error, which will warn or
raise appropriately depending on the flag. The boolean Alire.Force is also
available for less straightforward situations (interaction defaults for
example).
src/alire/alire.adb
src/alire/alire.ads
src/alr/alr-commands-version.adb
src/alr/alr-commands.adb
testsuite/tests/misc/force-switch/test.py [new file with mode: 0644]
testsuite/tests/misc/force-switch/test.yaml [new file with mode: 0644]