Can I auto-update my Github after publishing from Visual Studio?

Viewed 106

Is there a way to automate storing code updates to GitHub after a developer publishes a new version of code from Visual Studio (2017 or 2019)?

Or is there a way to automate storing code updates to any code repository?

We also currently use VisualSVN, but are open to other repository software packages if they solve this problem for us.
We publish web projects and console apps to on-prem servers, so my understanding is that GitHub Actions won't work for us (yet).

1 Answers

If you are pushing to an on-premise Git repository hosting server, you can add to that remote repository a post-receive hook.

Said hook can in turn analyze what just got pushed and push it in turn to GitHub.

See git-post-receive-hook-push-to-mirrors as an example of such hook.

Related