v1.2
This commit is contained in:
parent
dbc11279e0
commit
0fb8a165d1
5 changed files with 17 additions and 8 deletions
6
debian/changelog
vendored
6
debian/changelog
vendored
|
@ -1,3 +1,9 @@
|
||||||
|
sapphrc (1.2) unstable; urgency=medium
|
||||||
|
|
||||||
|
* fix some problematic synchronization (hopefully)
|
||||||
|
|
||||||
|
-- Penelope Gwen <support@pogmom.me> Tue, 09 Apr 2024 00:34:22 -0600
|
||||||
|
|
||||||
sapphrc (1.1) unstable; urgency=medium
|
sapphrc (1.1) unstable; urgency=medium
|
||||||
|
|
||||||
* fixed broken updown logic
|
* fixed broken updown logic
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
1.0
|
1.2
|
||||||
|
|
|
@ -17,3 +17,5 @@ do
|
||||||
echo "${backup_homedir}"
|
echo "${backup_homedir}"
|
||||||
rsync -arvSH --files-from="${include_list}" --exclude-from="${exclude_list}" --exclude '.config/sapphrc/' "${HOME}" "${backup_homedir}"
|
rsync -arvSH --files-from="${include_list}" --exclude-from="${exclude_list}" --exclude '.config/sapphrc/' "${HOME}" "${backup_homedir}"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
find ${HOME}/.config/sapphrc/backups/ -name *.swp -type f -exec rm {} \;
|
||||||
|
|
|
@ -5,6 +5,7 @@ source /lib/sapphrc/sapphrc-font
|
||||||
validate_backupdir
|
validate_backupdir
|
||||||
|
|
||||||
cd "$HOME/.config/sapphrc/backups"
|
cd "$HOME/.config/sapphrc/backups"
|
||||||
|
git config pull.rebase false
|
||||||
git pull --no-edit
|
git pull --no-edit
|
||||||
|
|
||||||
sapphrc_config="$HOME/.config/sapphrc"
|
sapphrc_config="$HOME/.config/sapphrc"
|
||||||
|
|
|
@ -10,15 +10,15 @@ gs="$(git status | grep -i 'modified')"
|
||||||
git fetch origin
|
git fetch origin
|
||||||
reslog=$(git log HEAD..origin/main --oneline)
|
reslog=$(git log HEAD..origin/main --oneline)
|
||||||
|
|
||||||
if [[ "${gs}" == *"modified"* && "${reslog}" != "" ]];then
|
echo $gs
|
||||||
#local AND remote changes exist
|
echo " "
|
||||||
echo "local backup reposity conflict with remote - please manually fix this!"
|
echo $reslog
|
||||||
exit 1
|
|
||||||
|
if [[ "${reslog}" == "" ]];then
|
||||||
|
#remote changes exist
|
||||||
|
sapphrc_restore
|
||||||
elif [[ $gs == *"modified"* ]];then
|
elif [[ $gs == *"modified"* ]];then
|
||||||
#local changes exist
|
#local changes exist
|
||||||
sapphrc_push
|
sapphrc_push
|
||||||
elif [[ "${reslog}" == "" ]];then
|
|
||||||
#remote changes exist
|
|
||||||
sapphrc_restore
|
|
||||||
fi
|
fi
|
||||||
exit
|
exit
|
||||||
|
|
Loading…
Add table
Reference in a new issue