-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 85baae6
Showing
30 changed files
with
2,521 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"include": ["src/**/*.ts"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
ARG VARIANT="18-bullseye" | ||
FROM mcr.microsoft.com/vscode/devcontainers/javascript-node:0-${VARIANT} | ||
|
||
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \ | ||
&& apt-get install -y \ | ||
gnupg2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
{ | ||
"name": "@pippo/api", | ||
"build": { | ||
"dockerfile": "Dockerfile" | ||
}, | ||
"customizations": { | ||
"vscode": { | ||
"extensions": ["biomejs.biome"] | ||
} | ||
}, | ||
"postCreateCommand": "bash -i -c 'nvm install && nvm use' && npm install", | ||
"remoteUser": "node" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# Current code owner of the repo | ||
* @matteosacchetto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
version: 2 | ||
updates: | ||
# GitHub actions | ||
- package-ecosystem: "github-actions" | ||
directory: "/" | ||
schedule: | ||
interval: weekly | ||
# Run on monday at 11:00 (CEST) | ||
day: "monday" | ||
time: "11:00" | ||
timezone: "Europe/Rome" | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
include: scope | ||
prefix: ci | ||
labels: | ||
- "type: deps" | ||
- "type: ci" | ||
|
||
# NPM | ||
- package-ecosystem: npm | ||
directory: "/" | ||
schedule: | ||
interval: weekly | ||
# Run on monday at 11:00 (CEST) | ||
day: "monday" | ||
time: "11:00" | ||
timezone: "Europe/Rome" | ||
open-pull-requests-limit: 10 | ||
commit-message: | ||
include: scope | ||
prefix: build | ||
labels: | ||
- "type: deps" | ||
ignore: | ||
# Allow only minor and patch | ||
- dependency-name: "@types/node" | ||
update-types: ["version-update:semver-major"] | ||
|
||
groups: | ||
dependencies: | ||
patterns: | ||
- "*" | ||
dependency-type: "production" | ||
update-types: | ||
- "minor" | ||
- "patch" | ||
dev-dependencies: | ||
patterns: | ||
- "*" | ||
dependency-type: "development" | ||
update-types: | ||
- "minor" | ||
- "patch" | ||
new-dependencies-major-version: | ||
patterns: | ||
- "*" | ||
update-types: | ||
- "major" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
- color: d73a4a | ||
description: Something isn't working! | ||
name: 'type: bug' | ||
- color: 0075ca | ||
description: Improvements or additions to documentation | ||
name: 'type: docs' | ||
- color: cfd3d7 | ||
description: This issue or pull request already exists | ||
name: 'type: duplicate' | ||
- color: a2eeef | ||
description: New feature or request | ||
name: 'type: feature' | ||
- color: 094ee3 | ||
description: Fix some misbehaving part | ||
name: 'type: fix' | ||
- color: '09e385' | ||
description: Refactor code | ||
name: 'type: refactor' | ||
- color: 02bf51 | ||
description: Performance optimization | ||
name: 'type: perf' | ||
- color: 7057ff | ||
description: Good for newcomers | ||
name: 'type: good first issue' | ||
- color: '008672' | ||
description: Extra attention is needed | ||
name: 'type: help wanted' | ||
- color: e4e669 | ||
description: This doesn't seem right | ||
name: 'type: invalid' | ||
- color: d876e3 | ||
description: Further information is requested | ||
name: 'type: question' | ||
- color: ffffff | ||
description: This will not be worked on | ||
name: 'type: wontfix' | ||
- color: bf0404 | ||
description: Priority 1 | ||
name: 'priority: 1' | ||
- color: bf4504 | ||
description: Priority 2 | ||
name: 'priority: 2' | ||
- color: f0d005 | ||
description: Priority 3 | ||
name: 'priority: 3' | ||
- color: 055ff0 | ||
description: Priority 4 | ||
name: 'priority: 4' | ||
- color: 4f4f4f | ||
description: Dependencies | ||
name: 'type: deps' | ||
- color: f542e0 | ||
description: CI | ||
name: 'type: ci' | ||
- color: ff6978 | ||
description: Major change | ||
name: 'semver: major' | ||
- color: fffcf9 | ||
description: Minor change | ||
name: 'semver: minor' | ||
- color: b1ede8 | ||
description: Patch change | ||
name: 'semver: patch' | ||
- color: ededed | ||
description: Pending release by release-please | ||
name: 'autorelease: pending' | ||
- color: ededed | ||
description: Created release by release-please | ||
name: 'autorelease: tagged' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
{ | ||
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json", | ||
"bump-minor-pre-major": true, | ||
"bump-patch-for-minor-pre-major": true, | ||
"packages": { | ||
".": { | ||
"release-type": "node" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
name: 'ci' | ||
|
||
concurrency: | ||
group: ci-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
branches: | ||
- main | ||
- dev | ||
paths-ignore: | ||
- '.devcontainer/**' | ||
- '.github/**' | ||
- '.vscode/**' | ||
- '.gitignore' | ||
- '.npmignore' | ||
- 'LICENSE' | ||
- 'README.md' | ||
push: | ||
paths-ignore: | ||
- '.devcontainer/**' | ||
- '.github/**' | ||
- '.vscode/**' | ||
- '.gitignore' | ||
- '.npmignore' | ||
- 'LICENSE' | ||
- 'README.md' | ||
|
||
permissions: | ||
contents: read # to fetch code (actions/checkout) | ||
|
||
jobs: | ||
ci: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup NodeJS 18.18.2 | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18.18.2 | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Test | ||
run: npm test --if-present | ||
|
||
- name: Build | ||
run: npm run build --if-present | ||
|
||
- name: Check style | ||
run: npm run style-check --if-present | ||
if: github.event_name == 'pull_request' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: pr-linter | ||
|
||
on: | ||
pull_request: | ||
types: | ||
- opened | ||
- edited | ||
- reopened | ||
|
||
permissions: | ||
contents: read | ||
pull-requests: write | ||
issues: read | ||
|
||
jobs: | ||
triage: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Lint pull request title | ||
uses: jef/conventional-commits-pr-action@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: release | ||
|
||
on: | ||
workflow_run: | ||
workflows: [ci] | ||
types: | ||
- completed | ||
branches: [main] | ||
|
||
permissions: | ||
contents: write | ||
pull-requests: write | ||
|
||
jobs: | ||
release-please: | ||
if: ${{ github.event.workflow_run.conclusion == 'success' }} | ||
runs-on: ubuntu-latest | ||
outputs: | ||
release_created: ${{ steps.release.outputs.release_created }} | ||
tag_name: ${{ steps.release.outputs.tag_name }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Package name | ||
id: name | ||
run: echo "::set-output name=name::$(jq -r .name package.json)" | ||
|
||
- name: Create release PR | ||
uses: google-github-actions/release-please-action@v4 | ||
id: release | ||
with: | ||
release-type: node | ||
config-file: .github/release-please-config.json | ||
target-branch: main | ||
|
||
upload-artifact: | ||
runs-on: ubuntu-latest | ||
needs: release-please | ||
if: ${{ needs.release-please.outputs.release_created == 'true' }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Setup NodeJS 18.18.2 | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18.18.2 | ||
cache: npm | ||
cache-dependency-path: package-lock.json | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Save archive | ||
run: echo "archive=$(npm pack 2>/dev/null | tail -1)" >> $GITHUB_ENV | ||
|
||
- name: Upload ${{ env.archive }} to release | ||
uses: svenstaro/upload-release-action@v2 | ||
with: | ||
repo_token: ${{ secrets.GITHUB_TOKEN }} | ||
tag: refs/tags/${{ needs.release-please.outputs.tag_name }} | ||
file: ${{ env.archive }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: sync-labels | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- .github/labels.yml | ||
|
||
jobs: | ||
labels: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
issues: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
|
||
- name: Sync labels | ||
uses: EndBug/label-sync@v2 | ||
with: | ||
config-file: .github/labels.yml | ||
delete-other-labels: true |
Oops, something went wrong.