File tree Expand file tree Collapse file tree 1 file changed +35
-4
lines changed
Expand file tree Collapse file tree 1 file changed +35
-4
lines changed Original file line number Diff line number Diff line change @@ -35,6 +35,8 @@ If you are using the PWA plugin, your app must be served over HTTPS so that [Ser
3535
3636### GitHub Pages
3737
38+ #### Pushing updates manually
39+
38401 . Set correct ` publicPath ` in ` vue.config.js ` .
3941
4042 If you are deploying to ` https://<USERNAME>.github.io/ ` , you can omit ` publicPath ` as it defaults to ` "/" ` .
@@ -79,9 +81,39 @@ If you are using the PWA plugin, your app must be served over HTTPS so that [Ser
7981 cd -
8082 ` ` `
8183
82- ::: tip
83- You can also run the above script in your CI setup to enable automatic deployment on each push.
84- :::
84+ #### Using Travis CI for automatic updates
85+
86+ 1. Set correct ` publicPath` in ` vue.config.js` as explained above.
87+
88+ 2. Install the Travis CLI client: ` gem install travis && travis --login`
89+
90+ 3. Generate a GitHub [access token](https: // help.github.com/en/articles/creating-a-personal-access-token-for-the-command-line)
91+ with repo permissions.
92+
93+ 4. Grant the Travis job access to your repository: ` travis set GITHUB_TOKEN=xxx`
94+ (` xxx` is the personal access token from step 3. )
95+
96+ 5. Create a ` .travis.yml` file in the root of your project.
97+
98+ ` ` ` yaml
99+ language: node_js
100+ node_js:
101+ - "node"
102+
103+ cache: npm
104+
105+ script: npm run build
106+
107+ deploy:
108+ provider: pages
109+ skip_cleanup: true
110+ github_token: $GITHUB_TOKEN
111+ local_dir: dist
112+ on:
113+ branch: master
114+ ` ` `
115+
116+ 6. Push the ` .travis.yml` file to your repository to trigger the first build.
85117
86118### GitLab Pages
87119
@@ -370,7 +402,6 @@ Verify your project is successfully published by Surge by visiting `myawesomepro
370402 cd -
371403 ```
372404
373-
374405### Docker (Nginx)
375406
376407Deploy your application using nginx inside of a docker container.
You can’t perform that action at this time.
0 commit comments