Emacs: sh snippets update

master
Pierre Neidhardt 2014-02-08 13:48:42 +01:00
parent 2640c56eef
commit 8c5fe9cfaa
4 changed files with 3 additions and 14 deletions

View File

@ -5,7 +5,7 @@ check()
{ {
for i ; do for i ; do
if ! command -v \$i >/dev/null 2>&1; then if ! command -v \$i >/dev/null 2>&1; then
echo >&2 "\'$i' not found in PATH. Exiting." echo "\'$i' not found in PATH. Exiting." >&2
exit 1 exit 1
fi fi
done done

View File

@ -1,11 +0,0 @@
# name: copy list of files
# key: listcopy
# --
SOURCE="$HOME"
DEST="$TEMP"
while read -r i; do
mkdir -p "$DEST/$(dirname "$i")"
cp -v "$SOURCE/$i" "$DEST/$(dirname "$i")"
done <<EOF
$0
EOF

View File

@ -2,6 +2,6 @@
# key: notcmd # key: notcmd
# -- # --
if ! command -v $1 >/dev/null 2>&1; then if ! command -v $1 >/dev/null 2>&1; then
echo >&2 "'$1' not found in PATH. Exiting." echo "'$1' not found in PATH. Exiting." >&2
exit 1 exit 1
fi fi

View File

@ -1,4 +1,4 @@
# name: >/dev/null # name: >/dev/null
# key: null # key: null
# -- # --
>/dev/null$0 >/dev/null 2>&1$0