0

I'm looking for any suggestions. To describe my scenario I have a web app service on azure. We have it set up so the frontend(which uses React) is a part of the whole solution. Also we have continuous deployment set up so that when our production branch accepts a pull request it automatically gets pulled down and the web app service redeploys. In this process the frontend does not get rebuilt. We need to run the npm build script that we have. In some cases someone forgets to rebuild the frontend before pushing. Is there some way that im just not aware of that would allow us to run that build script at a moment like right when it pulls the new changes from github.

1 Answer 1

0

You would have to write hooks in order to achieve that. If you want to run the npm build whenever someone from your team takes a pull then you need to write 'post-merge' hook, this hook should have a call to your npm build script. Since GIT pull involves merge, when there will be new changes to merge in during pull this hook will get executed which in turn will run the npm build script.

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.