Skip to content

Instantly share code, notes, and snippets.

@DavideC03
Last active December 4, 2020 19:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DavideC03/601a941bc4950d1ff71b98619ee46737 to your computer and use it in GitHub Desktop.
Save DavideC03/601a941bc4950d1ff71b98619ee46737 to your computer and use it in GitHub Desktop.
Run the code if there is a GitHub update available
# By Davide Castellani (help@castellanidavide.it)
if (-Not ((git pull <github_repositository_path> <main/master>) -Match "Already up to date."))
{
echo "Start other processes"
}
@DavideC03
Copy link
Author

Added the possibility to made pull for only a branch

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment