Skip to content

Commit

Permalink
ci: add actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomas2D committed Sep 2, 2024
1 parent 47b3d53 commit ebdb714
Show file tree
Hide file tree
Showing 7 changed files with 517 additions and 8 deletions.
22 changes: 22 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
name: Bug report
about: Create a report to help us improve
title: ""
labels: bug
assignees: ""
---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots / Code snippets**
If applicable, add screenshots or code snippets to help explain your problem.

**Additional context**
Add any other context about the problem here.
19 changes: 19 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
---
name: Feature request
about: Suggest an idea for this project
title: ""
labels: ""
assignees: ""
---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
32 changes: 32 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: CI

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
main:
timeout-minutes: 10
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Enable Corepack
run: corepack enable
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: ".nvmrc"
cache: "yarn"
- name: Install dependencies
run: yarn install --immutable
- name: Commits Lint
run: yarn commitlint --verbose --from "${{ github.event.pull_request.base.sha || github.event.commits[0].id }}" --to "${{ github.event.pull_request.head.sha || github.event.head_commit.id }}"
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
CI=true yarn copyright
12 changes: 12 additions & 0 deletions commitlint.config.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
import type { UserConfig } from "@commitlint/types";

const Configuration: UserConfig = {
extends: ["@commitlint/config-conventional"],
ignores: [
function ignoreDependabot(commit: string) {
return commit.includes("<[email protected]>") && commit.includes("dependabot");
},
],
};

export default Configuration;
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"build": "yarn generate && tsup && yarn copyright",
"generate": "./scripts/generate.sh",
"copyright": "./scripts/copyright.sh",
"release": "release-it"
"release": "release-it",
"prepare": "husky"
},
"keywords": [
"bee",
Expand All @@ -21,7 +22,10 @@
"@connectrpc/connect": "^1.4.0"
},
"devDependencies": {
"@commitlint/cli": "^19.4.1",
"@commitlint/config-conventional": "^19.4.1",
"@release-it/conventional-changelog": "^8.0.1",
"husky": "^9.1.5",
"lb4": "^1.0.0",
"release-it": "^17.6.0",
"tsup": "^8.2.4",
Expand Down
Loading

0 comments on commit ebdb714

Please sign in to comment.