From c2c691e01fe30a9dabbc0bd1bed69fdcc7f69e22 Mon Sep 17 00:00:00 2001 From: Henry Wojnicki Date: Thu, 6 Jun 2024 14:10:18 -0400 Subject: [PATCH] documented pull event class --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index dabd67e4..9e0e9ab3 100644 --- a/README.md +++ b/README.md @@ -58,6 +58,12 @@ This might look like: ![Example of mapping configuration](docs/images/settings.PNG "Example of mapping configuration") +### Pull Event Handlers + +The ##class(SourceControl.Git.PullEventHandler) is a base class that can be extended in order to develop functionality that should be run when the repository pulls from remote. The code placed inside the subclass' OnPull() method will be executed any time a pull occurs. + +A recommended way to implement CI/CD would be to use one of the pre-defined subclasses of PullEventHandler that are placed inside the PullEventHandler package. Additionally, custom load logic can be placed in that package following the model of the existing subclasses. + ### Security #### Unsecured (http) connections @@ -99,6 +105,8 @@ Assuming you have the local and remote repositories created, `git config core.sshCommand 'ssh -i ~/.ssh/'` 8. Test the refresh button for the remote branches on the WebUI, fetch from the source control menu in Studio or VS Code, and `git fetch` in Git Bash. All 3 should work without any issues. + + ## During Development :warning: Whenever any code in this project is updated outside the server (e.g. after every `git pull`), you _have_ to run `zpm "load "`. Otherwise, the changes won't be reflected on the server. However, if you load git-source-control via the InterSystems package manager and run `git pull` via the extension itself with the default pull event handler configured, it'll just work.