GitHub pages website
A Vue.js projectStatic build files from the latest vue project at branch dev). Contains a basic Vue CLI project with
router-link
.
This project contains a default vue-cli (2.9.6) project using the webpack template.
- Custom ESLint Rules have been applied.
- Build files from
dist
have been integrated with basic express server - Has options load page over
http
orhttps
-
Checkout the
dev
branch to access the vuejs project files.
git checkout dev
-
npm install
-
To load over https, create a
.env
file in the root directory and copy the contents of.env.example
to it. SetUSE_SSL
to `true|false to load over https before proceeding to #5. -
npm run dev
to serve with hot reload at localhost:8080 -
npm run build
to build for production with minification -
npm run dev:server
- serves static build files from express server at localhost:8080
- if
USE_SSL
is true, https version can be loaded fromhttps://localhost:8043
For a detailed explanation on how things work, check out the guide and docs for vue-loader.
The website, accessible from https://mechanicore.github.io serves static build files pushed into the master
branch.
This can be manually done by pushing static build files directly into the master
branch, or automatically by pushing vue project code updates into the dev
branch. Please follow the instructions below to trigger the automatic Travis CI/CD.
Read on this reference for more information on setting up Travis CI for GitHub pages.
-
Create a branch from
dev
.
git checkout -b my-test-branch
-
Edit and push updates to
my-test-branch
. -
Create a new Pull Request (PR) from the
my-test-branch
that you've created to branchdev
.- Go to
my-test-branch
page in GitHub, using the branch navigator dropdown menu (Branch: my-updates-branch), or go to its repository url.i.e.:
https://github.com/mechanicore/mechanicore.github.io/tree/my-updates-branch - Press the [New pull request] button beside the branch navigator dropdown menu.
- Go to
-
Set the following in the resulting "Open a pull request" page:
- base:
dev
- compare:
my-test-branch
- Press the [Create pull request] button.
- WAIT for the Travis CI checks to finish.
- base:
-
Press the [Merge pull request] button.
It is important to WAIT for the Travis CI checks from #4 to finish first before pressing this button, else the Travis CI build will fail pushing the built files to /master.
-
View the travis CI status from https://travis-ci.com/mechanicore/mechanicore.github.io.
New GitHub pages website updates can be viewed from https://mechanicore.github.io if the build passed.
[1] - quick notes on using vuex
@mechanicore
20190901