Skip to content

Commit 7d2602c

Browse files
author
Gabriel P.
committed
feat: switch to Github action
1 parent 5f47a9b commit 7d2602c

File tree

3 files changed

+49
-27
lines changed

3 files changed

+49
-27
lines changed

.circleci/config.yml

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

.github/workflows/ci.yml

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
jobs:
10+
lint_build:
11+
runs-on: ubuntu-latest
12+
13+
steps:
14+
- name: Checkout code
15+
uses: actions/checkout@v4
16+
17+
- name: Setup Node.js
18+
uses: actions/setup-node@v4
19+
with:
20+
node-version: '16'
21+
22+
- name: Setup pnpm
23+
uses: pnpm/action-setup@v4
24+
with:
25+
version: 10
26+
27+
- name: Get pnpm store directory
28+
id: pnpm-cache
29+
shell: bash
30+
run: |
31+
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
32+
33+
- name: Setup pnpm cache
34+
uses: actions/cache@v4
35+
with:
36+
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
37+
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
38+
restore-keys: |
39+
${{ runner.os }}-pnpm-store-
40+
41+
- name: Install dependencies
42+
run: pnpm install --frozen-lockfile
43+
44+
- name: Lint
45+
run: pnpm lint
46+
47+
- name: Build
48+
run: pnpm build

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# ph-node-api
22

3-
[![CircleCI](https://dl.circleci.com/status-badge/img/gh/PlanetHoster/ph-node-api/tree/main.svg?style=svg)](https://dl.circleci.com/status-badge/redirect/gh/PlanetHoster/ph-node-api/tree/main)
3+
[![CI](https://github.com/PlanetHoster/ph-node-api/actions/workflows/ci.yml/badge.svg)](https://github.com/PlanetHoster/ph-node-api/actions/workflows/ci.yml)
44

55
[![NPM](https://nodei.co/npm/ph-node-api.png)](https://nodei.co/npm/ph-node-api/)
66

0 commit comments

Comments
 (0)