Project

General

Profile

« Previous | Next » 

Revision 14411

lib/sh/util.sh: added lowercase()

View differences:

trunk/lib/sh/util.sh
8 8

  
9 9
realpath() { readlink -f -- "$1"; }
10 10

  
11
lowercase() { tr A-Z a-z <<<"$1"; }
12

  
11 13
str2varname() { echo "${1//[^a-zA-Z0-9_]/_}"; }
12 14

  
13 15
include_guard_var() { str2varname "$(realpath "$1")"; }
......
42 44

  
43 45
#### stubs
44 46

  
45
die() { return "$?"; } # can't use `:` because that resets $?
47
die()
48
{ return "$?"; } # can't use `:` because that resets $?
46 49

  
47 50
alias log_local='declare PS4="$PS4" log_level="$log_level"'
48 51

  

Also available in: Unified diff