9 lines
292 B
Bash
Executable File
9 lines
292 B
Bash
Executable File
#!/usr/bin/bash
|
|
# Sorts the output of getfacl records to stdout
|
|
# Assumes filenames don't contain + and |
|
|
|
|
grep -v -e '^user:[^:]' -e '^mask::' | awk '
|
|
BEGIN { RS="\n\n"; FS="\n"; ORS="\n"; OFS="|"}
|
|
// { $2=$2; print }
|
|
' | sort -k 1,1 -t '|' | tr '\n' '+' | sed 's/+/\n\n/g' | sed 's/|/\n/g'
|