Skip to content

Commit 64a8ba6

Browse files
authored
merge(#223): from curbengh/gh-action
2 parents 639662e + 32da61c commit 64a8ba6

File tree

5 files changed

+71
-57
lines changed

5 files changed

+71
-57
lines changed

.github/workflows/tester.yml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
name: Tester
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
tester:
7+
runs-on: ${{ matrix.os }}
8+
strategy:
9+
matrix:
10+
os: [ubuntu-latest, windows-latest, macos-latest]
11+
node-version: ['10.x', '12.x', '14.x']
12+
fail-fast: false
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: true
17+
- name: Use Node.js ${{ matrix.node-version }}
18+
uses: actions/setup-node@v1
19+
with:
20+
node-version: ${{ matrix.node-version }}
21+
- name: Cache NPM dependencies
22+
uses: actions/cache@v1
23+
with:
24+
path: node_modules
25+
key: ${{ runner.os }}-npm-cache
26+
restore-keys: ${{ runner.os }}-npm-cache
27+
- name: Install Dependencies
28+
run: npm install
29+
- name: Test
30+
run: npm run test
31+
env:
32+
CI: true
33+
coverage:
34+
runs-on: ${{ matrix.os }}
35+
strategy:
36+
matrix:
37+
os: [ubuntu-latest]
38+
node-version: ['12.x']
39+
steps:
40+
- uses: actions/checkout@v2
41+
with:
42+
submodules: true
43+
- name: Use Node.js ${{ matrix.node-version }}
44+
uses: actions/setup-node@v1
45+
with:
46+
node-version: ${{ matrix.node-version }}
47+
- name: Cache NPM dependencies
48+
uses: actions/cache@v1
49+
with:
50+
path: node_modules
51+
key: ${{ runner.os }}-npm-cache
52+
restore-keys: ${{ runner.os }}-npm-cache
53+
- name: Install Dependencies
54+
run: npm install
55+
- name: Coverage
56+
run: npm run test-cov
57+
env:
58+
CI: true
59+
- name: Coveralls
60+
uses: coverallsapp/github-action@master
61+
with:
62+
github-token: ${{ secrets.github_token }}

.travis.yml

Lines changed: 0 additions & 19 deletions
This file was deleted.

README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@ Command line interface for Hexo.
1313
$ npm install hexo-cli -g
1414
```
1515

16+
## Development
17+
18+
1. Fork this project
19+
2. `$ git clone https://github.com/user/hexo-cli --recurse-submodules && cd hexo-cli/`
20+
3. `$ npm install`
21+
4. `$ npm test`
22+
1623
## License
1724

18-
MIT
25+
[MIT](LICENSE)

appveyor.yml

Lines changed: 0 additions & 36 deletions
This file was deleted.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
"scripts": {
1515
"eslint": "eslint .",
1616
"test": "mocha test/index.js",
17-
"test-cov": "nyc npm run test"
17+
"test-cov": "nyc --reporter=lcovonly npm run test"
1818
},
1919
"directories": {
2020
"lib": "./lib",

0 commit comments

Comments
 (0)