Moved disco colorization into a function, can be used standalone with "client/bin/disco colorize" on stdin.
Fixed disco-fs-diff to only use rsync, sed, grep, etc to produce the filesystem changelog, python script is gone Minor fixups to other scripts
This commit is contained in:
@@ -3,9 +3,9 @@
|
||||
PARAMROOT=/var/disco/parameters
|
||||
|
||||
function check_names_regex() {
|
||||
echo "$1" | grep -E '^[a-zA-Z0-9_-\./]*$' >/dev/null 2>&1
|
||||
echo $1 | grep -E '^[a-zA-Z0-9_\-\.\/]*$' >/dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
echo "error: Invalid characters in pathname '$1'. Valid pathname characters are [a-zA-Z0-9_-\.\/]*." >&2
|
||||
echo "error: Invalid characters in pathname '$1'. Valid pathname characters are [a-zA-Z0-9_-.\/]*." >&2
|
||||
exit 1
|
||||
fi
|
||||
echo "$1" | grep "^/" >/dev/null 2>&1
|
||||
|
||||
Reference in New Issue
Block a user