Guest User

Untitled

a guest
Aug 2nd, 2018
159
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. How to have a trailing space character in authors file for git svn
  2. <author>ashfame</author>
  3. <author>clean</author>
  4. <author>clean </author>
  5. <author>rocketweb</author>
  6.  
  7. ashfame = Ashfame <mail@example.com>
  8. clean = Yogesh Tiwari <yogesh.tiwari@example.com>
  9. clean = Yogesh Tiwari <yogesh.tiwari@example.com>
  10. "clean " = Yogesh Tiwari <yogesh.tiwari@example.com>
  11. "clean " = Yogesh Tiwari <yogesh.tiwari@example.com>
  12. rocketweb = rocketweb <rocketweb@rocketweb.com>
  13. (no author) = Yogesh Tiwari <yogesh.tiwari@example.com>
  14. (no author) = no_author
  15.  
  16. #!/bin/sh
  17.  
  18. git filter-branch --env-filter '
  19.  
  20. an="$GIT_AUTHOR_NAME"
  21. am="$GIT_AUTHOR_EMAIL"
  22. cn="$GIT_COMMITTER_NAME"
  23. cm="$GIT_COMMITTER_EMAIL"
  24.  
  25. if [ "$GIT_COMMITTER_EMAIL" = "your@email.to.match" ]
  26. then
  27. cn="Your New Committer Name"
  28. cm="Your New Committer Email"
  29. fi
  30. if [ "$GIT_AUTHOR_EMAIL" = "your@email.to.match" ]
  31. then
  32. an="Your New Author Name"
  33. am="Your New Author Email"
  34. fi
  35.  
  36. export GIT_AUTHOR_NAME="$an"
  37. export GIT_AUTHOR_EMAIL="$am"
  38. export GIT_COMMITTER_NAME="$cn"
  39. export GIT_COMMITTER_EMAIL="$cm"
  40. '
Add Comment
Please, Sign In to add comment