Skip to content

Commit fd48174

Browse files
author
Ahmad Nassri
committed
ci(actions): replace old ci setup with new github actions workflows
1 parent 5c53c92 commit fd48174

File tree

12 files changed

+313
-128
lines changed

12 files changed

+313
-128
lines changed

.eslintrc

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

.github/dependabot.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: "github-actions"
4+
open-pull-requests-limit: 10
5+
directory: "/"
6+
schedule:
7+
interval: "daily"
8+
9+
- package-ecosystem: "npm"
10+
open-pull-requests-limit: 10
11+
directory: "/"
12+
schedule:
13+
interval: "daily"
14+

.github/linters/.markdown-lint.yml

Lines changed: 154 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,154 @@
1+
# Heading levels should only increment by one level at a time
2+
MD001: false
3+
4+
# Heading style
5+
MD003:
6+
style: atx
7+
8+
# Unordered list style
9+
MD004:
10+
style: dash
11+
12+
# Inconsistent indentation for list items at the same level
13+
MD005: true
14+
15+
# Unordered list indentation
16+
MD007:
17+
indent: 2
18+
start_indented: false
19+
20+
# Trailing spaces
21+
MD009:
22+
br_spaces: 2
23+
list_item_empty_lines: false
24+
strict: false
25+
26+
# Hard tabs
27+
MD010:
28+
code_blocks: false
29+
30+
# Reversed link syntax
31+
MD011: true
32+
33+
# Multiple consecutive blank lines
34+
MD012:
35+
maximum: 1
36+
37+
# Line length
38+
MD013:
39+
line_length: 180
40+
strict: true
41+
stern: true
42+
43+
# Dollar signs used before commands without showing output
44+
MD014: false
45+
46+
# No space after hash on atx style heading
47+
MD018: true
48+
49+
# Multiple spaces after hash on atx style heading
50+
MD019: true
51+
52+
# No space inside hashes on closed atx style heading
53+
MD020: true
54+
55+
# Multiple spaces inside hashes on closed atx style heading
56+
MD021: true
57+
58+
# Headings should be surrounded by blank lines
59+
MD022:
60+
lines_above: 1
61+
lines_below: 1
62+
63+
64+
# Headings must start at the beginning of the line
65+
MD023: true
66+
67+
# Multiple headings with the same content
68+
MD024:
69+
allow_different_nesting: true
70+
71+
# Multiple top level headings in the same document
72+
MD025: true
73+
74+
# Trailing punctuation in heading
75+
MD026:
76+
punctuation: ".,;:!?。,;:!?"
77+
78+
# Multiple spaces after blockquote symbol
79+
MD027: true
80+
81+
# Blank line inside blockquote
82+
MD028: true
83+
84+
# Ordered list item prefix
85+
MD029:
86+
style: one_or_ordered
87+
88+
# Spaces after list markers
89+
MD030:
90+
ul_single: 1
91+
ol_single: 1
92+
ul_multi: 1
93+
ol_multi: 1
94+
95+
# Fenced code blocks should be surrounded by blank lines
96+
MD031:
97+
list_items: true
98+
99+
# Lists should be surrounded by blank lines
100+
MD032: true
101+
102+
# inline HTML
103+
MD033:
104+
allowed_elements: []
105+
106+
# Bare URL used
107+
MD034: true
108+
109+
# Horizontal rule style
110+
MD035:
111+
style: "---"
112+
113+
114+
# Emphasis used instead of a heading
115+
MD036:
116+
punctuation: ".,;:!?。,;:!?"
117+
118+
# Spaces inside emphasis markers
119+
MD037: true
120+
121+
# Spaces inside code span elements
122+
MD038: true
123+
124+
# Spaces inside link text
125+
MD039: true
126+
127+
# Fenced code blocks should have a language specified
128+
MD040: true
129+
130+
# First line in file should be a top level heading
131+
MD041: true
132+
133+
# No empty links
134+
MD042: true
135+
136+
# Required heading structure
137+
MD043: false
138+
139+
# Proper names should have the correct capitalization
140+
MD044: false
141+
142+
# Images should have alternate text (alt text)
143+
MD045: false
144+
145+
# Code block style
146+
MD046:
147+
style: fenced
148+
149+
# Files should end with a single newline character
150+
MD047: true
151+
152+
# Code fence style
153+
MD048:
154+
style: backtick

.github/settings.yml

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

.github/workflows/release.yml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
name: release
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
8+
jobs:
9+
dependencies:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
- uses: actions/[email protected]
15+
16+
# run checks
17+
- run: npm audit --audit-level=moderate
18+
- run: npx updated
19+
20+
test:
21+
needs: dependencies
22+
23+
strategy:
24+
matrix:
25+
os: [ubuntu-latest, windows-latest, macos-latest]
26+
node-version: [10, 12, 13, 14]
27+
28+
runs-on: ${{ matrix.os }}
29+
30+
steps:
31+
- uses: actions/checkout@v2
32+
33+
- uses: actions/cache@v2
34+
with:
35+
path: ~/.npm
36+
key: client-${{ hashFiles('**/package-lock.json') }}
37+
38+
- uses: actions/[email protected]
39+
with:
40+
node-version: ${{ matrix.node-version }}
41+
42+
# run test
43+
- run: npm ci
44+
- run: npm run test
45+
46+
release:
47+
needs: test
48+
49+
runs-on: ubuntu-latest
50+
51+
steps:
52+
- uses: actions/checkout@v2
53+
- uses: actions/[email protected]
54+
55+
# release
56+
- run: npx semantic-release
57+
env:
58+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
59+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/super-linter.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: super-linter
2+
3+
on:
4+
push:
5+
branches-ignore:
6+
- master
7+
8+
jobs:
9+
super-linter:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
- uses: docker://github/super-linter:v3

.github/workflows/test.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: test
2+
3+
on:
4+
push:
5+
branches-ignore:
6+
- master
7+
8+
jobs:
9+
dependencies:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- uses: actions/checkout@v2
14+
- uses: actions/[email protected]
15+
16+
# run checks
17+
- run: npm audit --audit-level=moderate
18+
- run: npx updated
19+
20+
test:
21+
needs: dependencies
22+
23+
strategy:
24+
matrix:
25+
os: [ubuntu-latest, windows-latest, macos-latest]
26+
node-version: [10, 12, 13, 14]
27+
28+
runs-on: ${{ matrix.os }}
29+
30+
steps:
31+
- uses: actions/checkout@v2
32+
33+
- uses: actions/cache@v2
34+
with:
35+
path: ~/.npm
36+
key: client-${{ hashFiles('**/package-lock.json') }}
37+
38+
- uses: actions/[email protected]
39+
with:
40+
node-version: ${{ matrix.node-version }}
41+
42+
# run test
43+
- run: npm ci
44+
- run: npm run test

.releaserc copy

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"plugins": [
3+
["@semantic-release/commit-analyzer", {
4+
"releaseRules": [
5+
{"breaking": true, "release": "major"},
6+
{"revert": true, "release": "patch"},
7+
{"type": "build", "release": "patch"},
8+
{"type": "feat", "release": "minor"},
9+
{"type": "fix", "release": "patch"},
10+
{"type": "perf", "release": "patch"},
11+
{"type": "refactor", "release": "patch"}
12+
]
13+
}],
14+
"@semantic-release/release-notes-generator",
15+
"@semantic-release/github",
16+
"@semantic-release/npm"
17+
]
18+
}

.remarkrc

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

0 commit comments

Comments
 (0)