Make sure you have the project set up locally first. Follow these instructions if you haven't already.
- Create a new branch (say publish_gh_pages).
git checkout -b publish_gh_pages- Install ember-cli-github-pages addon.
ember install ember-cli-github-pages-
Open config/environment.js file and change the value of
rootURLfrom/toopen-event-frontend -
Commit the changes made so far.
git add -A && git commit -m "Added ember-cli-github-pages addon"- Create the
gh-pagesbranch and remove unnecessary files.
git checkout --orphan gh-pages && rm -rf `bash -c "ls -a | grep -vE '\.gitignore|\.git|node_modules|bower_components|(^[.]{1,2}/?$)'"` && touch .gitkeep && git add -A && git commit -m "initial gh-pages commit"- Switch back to the branch created in the first step.
git checkout publish_gh_pages- Build ember app to the gh-pages branch.
ember gh-pages:commit --message "Initial gh-pages release"- Force push to your clone repository.
git push -f origin gh-pagesYou can now access it at (your-github-username).github.io/openeventfrontend.
In case you use something like FISH for your terminal please refer to this issue.