If your activestate.yaml
file is under Git version control, you can configure Git to automatically update your ActiveState Platform Runtime each time you switch branches or pull in remote changes.
From your project’s root directory, create a .git/hooks/post-checkout
file (or open it if your project already has one). Add the following content to that file:
if [ "$3" == "1" ]; then
echo "\nSynchronizing ActiveState Platform Runtime after having switched Git branches"
state exec exit 0
fi
Then make sure the hook is executable by running the following shell command from your project’s root directory:
chmod +x .git/hooks/post-checkout
Now every time you checkout or switch to another Git branch, Git will invoke that hook to update your project’s Platform Runtime.
From your project’s root directory, create a .git/hooks/post-merge
file (or open it if you project already has one). Add the following content to that file:
echo "\nSynchronizing ActiveState Platform Runtime after having pulled in remote changes"
state exec exit 0
Then make sure the hook is executable by running the following shell command from your project’s root directory:
chmod +x .git/hooks/post-merge
Now every time you pull in remote changes for your project, Git will invoke that hook to update your project’s Platform Runtime.