feat: switch CI from Travis-CI to GitHub Actions

This commit is contained in:
ruanyf
2020-12-28 22:19:45 +08:00
parent 06f9d34511
commit 5dfe25f8e3
3 changed files with 38 additions and 1 deletions

37
.github/workflows/wangdoc.yml vendored Normal file
View File

@@ -0,0 +1,37 @@
name: HTML tutorial CI
on:
push:
branches:
- master
jobs:
page-generator:
name: Generating pages
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
with:
persist-credentials: false
- name: Setup Node.js
uses: actions/setup-node@main
with:
node-version: '14'
- name: Install dependencies
run: npm install
- name: Build pages
run: npm run build
- name: Deploy to website
uses: JamesIves/github-pages-deploy-action@3.7.1
with:
GIT_CONFIG_NAME: wangdoc-bot
GIT_CONFIG_EMAIL: yifeng.ruan@gmail.com
REPOSITORY_NAME: wangdoc/website
ACCESS_TOKEN: ${{ secrets.WANGDOC_BOT_TOKEN }}
BASE_BRANCH: master
BRANCH: master # The branch the action should deploy to.
FOLDER: dist # The folder the action should deploy.
TARGET_FOLDER: dist/html
CLEAN: true # Automatically remove deleted files from the deploy branch
COMMIT_MESSAGE: update from HTML tutorial

View File

@@ -8,7 +8,7 @@ URL 是“统一资源定位符”Uniform Resource Locator的首字母缩
https://www.example.com/path/index.html
```
所谓资源可以简单理解成各种可以通过互联网访问的文件比如网页、图像、音频、视频、JavaScript 脚本等等。只有知道了它们的 URL能在互联网上获取它们。
所谓资源可以简单理解成各种可以通过互联网访问的文件比如网页、图像、音频、视频、JavaScript 脚本等等。只有知道了它们的 URL才能在互联网上获取它们。
只要资源可以通过互联网访问,它就必然有对应的 URL。一个 URL 对应一个资源,但是同一个资源可能对应多个 URL。