Skip to content
Snippets Groups Projects
Select Git revision
  • master default protected
  • v1.14.7
  • v1.14.6
  • v1.14.5
  • v1.14.4
  • v1.14.3
  • v1.14.2
  • v1.14.1
  • v1.14.0
  • v1.13.2
  • v1.13.1
  • v1.13.0
  • v1.12.1
  • v1.12.0
  • v1.11.1
  • v1.11.0
  • v1.10.0
  • v1.9.2
  • v1.9.1
  • v1.9.0
  • v1.8.4
21 results

shlog

Blame
    • Rafael Guterres Jeffman's avatar
      b0e03a03
      Add shell utitily functions for scripts · b0e03a03
      Rafael Guterres Jeffman authored
      Add two shell libaries with utilities to write shell scripts.
      
      The 'utils/shlog' file provides macro names for ANSI escape sequences to
      control color output on terminals, a 'log' functions with pre-defined
      behavior for ERROR, WARN, DEBUG, INFO and SUCCESS level messages, and
      the 'quiet' function which executes a command and hides its output.
      
      The 'utils/shfun' file provides an interruptinon handler for SIGINT, and
      the following functions:
      
      - run_if_exists: run a command if it is available
      - cleanup: cleanup environment, possibly stopping a container and a
        Python virtual environment.
      - start_virtual_environmnt: initiates a Python virtual environment
      - in_python_virtualenv: test if the script is running inside a Python
        virtual environment
      - die: abort the script with an error message end exit code 1
      
      New files:
      
        - utils/shlog
        - utils/shfun
      b0e03a03
      History
      Add shell utitily functions for scripts
      Rafael Guterres Jeffman authored
      Add two shell libaries with utilities to write shell scripts.
      
      The 'utils/shlog' file provides macro names for ANSI escape sequences to
      control color output on terminals, a 'log' functions with pre-defined
      behavior for ERROR, WARN, DEBUG, INFO and SUCCESS level messages, and
      the 'quiet' function which executes a command and hides its output.
      
      The 'utils/shfun' file provides an interruptinon handler for SIGINT, and
      the following functions:
      
      - run_if_exists: run a command if it is available
      - cleanup: cleanup environment, possibly stopping a container and a
        Python virtual environment.
      - start_virtual_environmnt: initiates a Python virtual environment
      - in_python_virtualenv: test if the script is running inside a Python
        virtual environment
      - die: abort the script with an error message end exit code 1
      
      New files:
      
        - utils/shlog
        - utils/shfun