Add another folder to msync
This commit is contained in:
parent
488d3559a1
commit
619baf6937
@ -9,20 +9,25 @@ while getopts ":pr" o; do
|
|||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
|
# Setup ssh agent to avoid repeated password prompts
|
||||||
|
eval `ssh-agent -s`
|
||||||
|
|
||||||
|
ssh-add ~/.ssh/keys/beryllium
|
||||||
|
|
||||||
if [ $ACTION = PUSH ]
|
if [ $ACTION = PUSH ]
|
||||||
then
|
then
|
||||||
rsync -avPzc ~/med/memes/woof/ boron:~/med/memes/woof
|
rsync -avPzc ~/med/memes/woof/ boron:~/med/memes/woof
|
||||||
|
|
||||||
rsync -avPzc ~/med/memes/woof/ beryllium:~/med/memes/woof
|
rsync -avPzc ~/med/memes/woof/ beryllium:~/med/memes/woof
|
||||||
|
|
||||||
|
rsync -avPzc --delete ~/med/mus/ beryllium:~/storage/music/mus
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ $ACTION = RECV ]
|
if [ $ACTION = RECV ]
|
||||||
then
|
then
|
||||||
# Move files to the quarantine zone for categorisation and renaming
|
# Move files to the quarantine zone for categorisation and renaming
|
||||||
|
|
||||||
# Setup ssh agent to avoid repeated password prompts
|
|
||||||
eval `ssh-agent -s`
|
|
||||||
ssh-add ~/.ssh/keys/beryllium
|
|
||||||
|
|
||||||
rsync -avPzc beryllium:~/storage/pictures/Infinity/ ~/med/memes/woof/quar && \
|
rsync -avPzc beryllium:~/storage/pictures/Infinity/ ~/med/memes/woof/quar && \
|
||||||
ssh beryllium "rm -I storage/pictures/Infinity/*"
|
ssh beryllium "rm -I storage/pictures/Infinity/*"
|
||||||
|
|
||||||
@ -30,5 +35,6 @@ then
|
|||||||
ssh beryllium "rm -I storage/movies/Infinity/*"
|
ssh beryllium "rm -I storage/movies/Infinity/*"
|
||||||
|
|
||||||
# Kill ssh agent
|
# Kill ssh agent
|
||||||
kill $SSH_AGENT_PID
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
kill $SSH_AGENT_PID
|
||||||
|
Loading…
Reference in New Issue
Block a user