Compare commits
2 commits
9b2faedb19
...
584d85ef90
Author | SHA1 | Date | |
---|---|---|---|
584d85ef90 | |||
e64d445adc |
3 changed files with 26 additions and 0 deletions
26
apsalar/icloudsync
Executable file
26
apsalar/icloudsync
Executable file
|
@ -0,0 +1,26 @@
|
|||
#!/bin/sh
|
||||
# Sync icloud photos to machine using a
|
||||
# simple wrapper for tmux and icloudpd
|
||||
session="icloudsync"
|
||||
|
||||
# Check if icloudpd is available
|
||||
if ! type icloudpd >/dev/null; then
|
||||
echo "please install icloud photo downloader."
|
||||
echo "See: https://github.com/icloud-photos-downloader/icloud_photos_downloader"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
tmux has-session -t $session 2>/dev/null
|
||||
|
||||
if [ $? != 0 ]; then
|
||||
tmux new-session -d -s $session
|
||||
tmux send-keys -t $session "icloudpd --directory=$HOME/Pictures --username \$ICLOUD_USERNAME" C-m
|
||||
echo "icloudsync started"
|
||||
else
|
||||
if [[ $1 == "attach" ]]; then
|
||||
tmux attach-session -t $session
|
||||
else
|
||||
echo "icloudsync already active: use icloudsync attach to view progress"
|
||||
fi
|
||||
fi
|
||||
|
BIN
icons/battlenet.png
Normal file
BIN
icons/battlenet.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 44 KiB |
BIN
icons/profanity.png
Normal file
BIN
icons/profanity.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 19 KiB |
Loading…
Reference in a new issue