Ver código fonte

Ensure that gogs repos are in the user subdirectory

Bob Mottram 9 anos atrás
pai
commit
0ab652fcd5
1 arquivos alterados com 3 adições e 0 exclusões
  1. 3
    0
      src/freedombone

+ 3
- 0
src/freedombone Ver arquivo

2595
       echo 'echo "Obtaining Gogs settings backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2595
       echo 'echo "Obtaining Gogs settings backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2596
       backup_directory_to_usb '/home/git/go/src/github.com/gogits/gogs/custom' 'gogs'
2596
       backup_directory_to_usb '/home/git/go/src/github.com/gogits/gogs/custom' 'gogs'
2597
       echo 'echo "Obtaining Gogs repos backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2597
       echo 'echo "Obtaining Gogs repos backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2598
+      echo "mv /home/git/gogs-repositories/*.git /home/git/gogs-repositories/$MY_USERNAME" >> /usr/bin/$BACKUP_SCRIPT_NAME
2598
       backup_directory_to_usb '/home/git/gogs-repositories' 'gogsrepos'
2599
       backup_directory_to_usb '/home/git/gogs-repositories' 'gogsrepos'
2599
       echo 'echo "Obtaining Gogs authorized_keys backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2600
       echo 'echo "Obtaining Gogs authorized_keys backup"' >> /usr/bin/$BACKUP_SCRIPT_NAME
2600
       backup_directory_to_usb '/home/git/.ssh' 'gogsssh'
2601
       backup_directory_to_usb '/home/git/.ssh' 'gogsssh'
3865
       echo 'echo "Obtaining Gogs settings backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3866
       echo 'echo "Obtaining Gogs settings backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3866
       backup_directory_to_friend '/home/git/go/src/github.com/gogits/gogs/custom' 'gogs'
3867
       backup_directory_to_friend '/home/git/go/src/github.com/gogits/gogs/custom' 'gogs'
3867
       echo 'echo "Obtaining Gogs repos backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3868
       echo 'echo "Obtaining Gogs repos backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3869
+      echo "mv /home/git/gogs-repositories/*.git /home/git/gogs-repositories/$MY_USERNAME" >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3868
       backup_directory_to_friend '/home/git/gogs-repositories' 'gogsrepos'
3870
       backup_directory_to_friend '/home/git/gogs-repositories' 'gogsrepos'
3869
 
3871
 
3870
       echo 'echo "Obtaining Gogs authorized_keys backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
3872
       echo 'echo "Obtaining Gogs authorized_keys backup"' >> /usr/bin/$BACKUP_TO_FRIENDS_SCRIPT_NAME
9832
   if grep -Fxq "install_gogs" $COMPLETION_FILE; then
9834
   if grep -Fxq "install_gogs" $COMPLETION_FILE; then
9833
       echo '' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9835
       echo '' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9834
       echo '# gogs' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9836
       echo '# gogs' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9837
+      echo "mv /home/git/gogs-repositories/*.git /home/git/gogs-repositories/$MY_USERNAME" >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9835
       echo 'cd /home/git/go/src/github.com/gogits/gogs' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9838
       echo 'cd /home/git/go/src/github.com/gogits/gogs' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9836
       echo 'git stash' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9839
       echo 'git stash' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9837
       echo 'git stash drop' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME
9840
       echo 'git stash drop' >> /etc/cron.weekly/$UPGRADE_SCRIPT_NAME