Skip to content

Commit 6e28a49

Browse files
committed
add CI
1 parent 0649b0c commit 6e28a49

2 files changed

Lines changed: 89 additions & 0 deletions

File tree

.github/workflows/CI.yml

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
name: CI
2+
on:
3+
- push
4+
- pull_request
5+
6+
defaults:
7+
run:
8+
shell: bash
9+
10+
jobs:
11+
Test:
12+
if: "!contains(github.event.head_commit.message, '[skip ci]')"
13+
name: ${{ matrix.os }} - Atom ${{ matrix.atom_channel }}
14+
runs-on: ${{ matrix.os }}
15+
strategy:
16+
fail-fast: false
17+
matrix:
18+
os:
19+
- ubuntu-latest
20+
# - macos-latest
21+
# - windows-latest
22+
atom_channel: [stable, beta]
23+
steps:
24+
- uses: actions/checkout@v2
25+
- uses: UziTech/action-setup-atom@v1
26+
with:
27+
channel: ${{ matrix.atom_channel }}
28+
- name: Versions
29+
run: apm -v
30+
- name: Install APM dependencies
31+
run: |
32+
apm install
33+
- name: Run the tests
34+
run: |
35+
npm run test
36+
37+
Release:
38+
needs: [Test]
39+
if: github.ref == 'refs/heads/master' &&
40+
github.event.repository.fork == false
41+
runs-on: ubuntu-latest
42+
steps:
43+
- uses: actions/checkout@v2
44+
- uses: UziTech/action-setup-atom@v1
45+
- uses: actions/setup-node@v1
46+
with:
47+
node-version: "12.x"
48+
- name: NPM install
49+
run: npm install
50+
# - name: Release 🎉
51+
# uses: cycjimmy/semantic-release-action@v2
52+
# env:
53+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
54+
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
55+
Skip:
56+
if: contains(github.event.head_commit.message, '[skip ci]')
57+
runs-on: ubuntu-latest
58+
steps:
59+
- name: Skip CI 🚫
60+
run: echo skip ci

.github/workflows/bump_deps.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Bump_Dependencies
2+
3+
on:
4+
schedule:
5+
- cron: "0 0 * * *"
6+
7+
jobs:
8+
Bump_Dependencies:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v2
12+
- uses: actions/setup-node@v2-beta
13+
with:
14+
node-version: "14"
15+
- name: Setup PNPM
16+
uses: pnpm/action-setup@v1.2.0
17+
with:
18+
version: 4.11.1
19+
- run: |
20+
pnpm install
21+
pnpm run bump
22+
pnpm install
23+
- uses: peter-evans/create-pull-request@v2
24+
with:
25+
token: ${{ secrets.GITHUB_TOKEN }}
26+
commit-message: Update dependencies
27+
title: "[AUTO] Update dependencies"
28+
labels: Dependencies
29+
branch: "Bump"

0 commit comments

Comments
 (0)