Skip to content

Commit 8895312

Browse files
committed
ci: add ci for pr and main branch
1 parent 5b4db66 commit 8895312

File tree

2 files changed

+42
-0
lines changed

2 files changed

+42
-0
lines changed

.github/workflows/ci.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node
2+
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs
3+
4+
name: Github CI
5+
6+
on:
7+
push:
8+
branches: ['main', 'ci']
9+
pull_request:
10+
11+
jobs:
12+
build:
13+
runs-on: ubuntu-latest
14+
15+
strategy:
16+
matrix:
17+
node-version: [18, 20, 22]
18+
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
19+
20+
steps:
21+
- uses: actions/checkout@v4
22+
23+
- name: Conventional Commitlint
24+
uses: opensource-nepal/commitlint@v1
25+
with:
26+
verbose: true
27+
28+
- name: Use Node.js ${{ matrix.node-version }}
29+
uses: actions/setup-node@v4
30+
with:
31+
node-version: ${{ matrix.node-version }}
32+
cache: 'npm'
33+
34+
- name: Install dependencies
35+
run: npm ci
36+
37+
- name: Build
38+
run: npm run build
39+
40+
- name: Check lint
41+
run: npm run lint

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
"files": [
99
"dist"
1010
],
11+
"description": "React components for a Nepali DateTime picker, built on top of nepali-datetime.",
1112
"keywords": [
1213
"javascript",
1314
"typescript",

0 commit comments

Comments
 (0)