Advertisement
Guest User

Untitled

a guest
Jun 21st, 2018
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.46 KB | None | 0 0
  1. #!/bin/bash
  2. if [ -z "$1" ]
  3. then
  4. echo 'Brak nazwy brancha! Podaj ja jako pierwszy argument!'
  5. else
  6. {
  7. cd ias2-igo &&
  8. echo '############# checkout origin/sync ##############' &&
  9. git checkout origin/sync
  10. git branch -D $1-temp
  11. git reset --hard &&
  12. echo '############# pull ##############'
  13. git pull
  14. git checkout origin/$1 -b $1-temp &&
  15. echo '############# submodule update ##############' &&
  16. git submodule update &&
  17. echo '############# merge --no-ff origin/sync ##############' &&
  18. git merge --no-ff origin/sync | grep "Already up-to-date." &&
  19. echo $i &&
  20. echo 'xx'
  21. # git merge --no-ff origin/sync &&
  22. # cd custom &&
  23. # git checkout origin/dev &&
  24. # cd .. &&
  25. # echo '############# add custom ##############' &&
  26. # git add custom &&
  27. # echo '############# commit --amend ##############' &&
  28. # git commit --amend # &&
  29. # #echo '############# push ##############' &&
  30. # git push origin HEAD:refs/for/$1
  31. } || {
  32. echo 'Blad synchronizacji. Moze lepiej wykonac ja recznie?'
  33. }
  34. fi
  35.  
  36.  
  37.  
  38.  
  39.  
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47. pkrajewski@mars-maks-debian:~/projects/CLEAN$ sh synchro_igo.sh dev-sfx
  48. ############# checkout origin/sync ##############
  49. M custom
  50. Note: checking out 'origin/sync'.
  51.  
  52. You are in 'detached HEAD' state. You can look around, make experimental
  53. changes and commit them, and you can discard any commits you make in this
  54. state without impacting any branches by performing another checkout.
  55.  
  56. If you want to create a new branch to retain commits you create, you may
  57. do so (now or later) by using -b with the checkout command again. Example:
  58.  
  59. git checkout -b new_branch_name
  60.  
  61. HEAD is now at 4f02b7c... Merge branch 'splitpayment' into sync
  62. Deleted branch dev-sfx-temp (was 2b1a577).
  63. HEAD is now at 4f02b7c Merge branch 'splitpayment' into sync
  64. ############# pull ##############
  65. You are not currently on a branch. Please specify which
  66. branch you want to merge with. See git-pull(1) for details.
  67.  
  68. git pull <remote> <branch>
  69.  
  70. Previous HEAD position was 4f02b7c... Merge branch 'splitpayment' into sync
  71. Branch dev-sfx-temp set up to track remote branch dev-sfx from origin.
  72. Switched to a new branch 'dev-sfx-temp'
  73. ############# submodule update ##############
  74. ############# merge --no-ff origin/sync ##############
  75. Blad synchronizacji. Moze lepiej wykonac ja recznie?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement