All pastes #960685 Raw Edit

Untitled

public text v1 · immutable
#960685 ·published 2008-03-28 11:28 UTC
rendered paste body
#!/bin/bash
# Sync alpine address book

if [ -f "$1"]; then
if [ -f "$2"]; then
cat "$1" >> "$2"
else
echo "Usage new address book old address book"
exit 0
fi
else 
echo "Usage new address book old address book"
exit 0
fi

# Strip duplicate lines
uniq "$2" > complete_book
# move complete_book to $2's name since that is where we expect to see our new addressbook...
mv complete_book "$1"