Advertisement
Guest User

Untitled

a guest
Aug 2nd, 2016
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.37 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. echo "Cleaning up..."
  4. rm -rf components/sync/driver
  5. git reset --hard sc-t
  6.  
  7. echo "Moving sync_driver..."
  8. git mv components/sync_driver components/sync/driver
  9.  
  10. # replace performs a string replacement for all files in the repo under the
  11. # current folder and is defined as:
  12. #
  13. #     git grep -l "$1" | xargs sed -i "s/$1/$2/g"
  14.  
  15. echo "Updating sync build files..."
  16. replace "components\/sync_driver" "components\/sync\/driver"
  17. replace "sync_driver\/resources" "sync\/driver\/resources"
  18. replace "driver:sync_driver\"" "driver\""
  19. replace "\/driver:test_support\"" ":test_support_sync_driver\""
  20. replace "\"\/\/components\/sync\/driver" "\"\/\/components\/sync"
  21.  
  22. # sort_includes is a hacked version of cpplint/nitpick.py that sorts Java
  23. # imports in addition to C++ includes. It mostly just sorts within blocks of
  24. # includes, but can also insert newlines to create new blocks if it detects
  25. # different types of include (e.g. C++ vs C system headers).
  26.  
  27. echo "Sorting includes..."
  28. git diff --name-only --diff-filter=ACMR sc-t | xargs sort_includes --quiet
  29.  
  30. echo "Formatting..."
  31. git cl format
  32.  
  33. echo "Commiting automated changes..."
  34. git co .git-blame-ignore-revs
  35. git commit --all -m "Automated changes." > /dev/null
  36.  
  37. echo "Cherry-picking manual changes..."
  38. git cherry-pick e6acee2
  39.  
  40. echo "Building..."
  41. build_chrome
  42.  
  43. echo "Running presubmit checks..."
  44. git cl presubmit
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement