This repository has been archived on 2024-09-06. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
bash_message/example/example.sh
2018-11-08 00:18:02 +01:00

23 lines
505 B
Bash
Executable file

#!/bin/bash
# message librairy example
source ../message.sh
EXIT_ON_ERROR=1
debug "This message wille not be displayed because debug is not activated"
msg "\n**__welcome to message lib example__**\n"
msg "red" "\nMessages "
msg "green" "can "
msg "yellow" "be "
msg "blue" "colored"
msg " **bold** and __underline__ \n\n"
warning "Text with **a warning**"
msg "and when DEBUG=1\n"
DEBUG=1
debug "with debug message"
error "Or a **real** and __serious__ error that exit script when EXIT_ON_ERROR=1"