rtfd/docs/public/bash/snippets.rst
Marc Beninca 96f5a0771a in→docs
2019-08-25 22:15:32 +02:00

26 lines
393 B
ReStructuredText

********
Snippets
********
Start a runnable script file
============================
.. code:: bash
#! /bin/bash
Find out current script
=======================
.. code:: bash
SCRIPT_FILE="$(realpath "${BASH_SOURCE[0]}")"
SCRIPT_DIRECTORY="$(dirname "${SCRIPT_FILE}")"
SCRIPT_NAME="$(basename "${SCRIPT_FILE}")"
Quit the interpreter
====================
.. code:: bash
exit