I have made a number of changes to an Angular repo on a branch called feat/demo-mode and I want to publish this branch to GitHub Pages.
Under the GitHub Pages section, I chose my branch as outlined here configuring-a-publishing-source-for-your-github-pages-site.
I have added/updated the following scripts in package.json
"build": "ng build --prod --base-href /my-example-repo/",
"predeploy": "npm run build",
"deploy": "npx angular-cli-ghpages --dir=dist/my-example-repo --branch=feat/demo-mode --message='Deploy to GitHub Pages'"
When I run npm run deploy
, the app builds and deploys. I can now visit it on https://funfair-tech.github.io/my-example-repo/
, however the code in feat/demo-mode has now been replaced with the contents of my dist folder.