You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/external-commands.rst
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,22 +1,22 @@
1
1
External Commands
2
2
=================
3
3
4
-
``cabal-install`` provides a system for external commands, akin to the ones used by tools like ``git`` or ``cargo``.
4
+
:term:`cabal-install:exe:cabal` provides a system for external commands, akin to the ones used by tools like ``git`` or ``cargo``.
5
5
6
-
If you execute ``cabal <cmd>``, ``cabal-install`` will search the path for an executable named ``cabal-<cmd>`` and execute it. The name of the command is passed as the first argument and
6
+
If you execute ``cabal <cmd>``, :term:`cabal-install:exe:cabal` will search the path for an executable named ``cabal-<cmd>`` and execute it. The name of the command is passed as the first argument and
7
7
the remaining arguments are passed afterwards. An error will be thrown in case the custom command is not found. The exit code of cabal when calling an external command is the same as the exit code
8
8
of the command.
9
9
10
-
The ``$CABAL`` environment variable is set to the path of the ``cabal-install`` executable
10
+
The ``$CABAL`` environment variable is set to the path of the :term:`cabal-install:exe:cabal` executable
11
11
which invoked the subcommand.
12
12
13
13
It is strongly recommended that you implement your custom commands by calling the
14
14
CLI via the ``$CABAL`` variable rather than linking against the ``Cabal`` library.
15
15
There is no guarantee that the subcommand will link against the same version of the
16
-
``Cabal`` library as ``cabal-install`` so it would lead to unexpected results and
16
+
``Cabal`` library as :term:`cabal-install:exe:cabal` so it would lead to unexpected results and
17
17
incompatibilities.
18
18
19
-
``cabal-install`` can also display the help message of the external command.
19
+
:term:`cabal-install:exe:cabal` can also display the help message of the external command.
20
20
When ``cabal help <cmd>`` is invoked, then ``cabal-<cmd> <cmd> --help`` will be called so
0 commit comments