Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 50 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
name: Build

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

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'yarn'

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: '3.x'

- name: Install pre-commit
run: pip install pre-commit

- name: Run pre-commit
run: pre-commit run --all-files

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
cache: 'yarn'

- name: Install dependencies
run: yarn install --frozen-lockfile

- name: Build TypeScript
run: yarn build
43 changes: 14 additions & 29 deletions .github/workflows/npm-publish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This workflow will run tests using node and then publish a package to GitHub Packages when a release is created
# This workflow will run tests using node and then publish a package to NPM when a release is created
# For more information see: https://help.github.com/actions/language-and-framework-guides/publishing-nodejs-packages

name: Node.js Package
Expand All @@ -8,43 +8,28 @@ on:
types: [created]

jobs:

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 12
- run: npm install
- run: npm ci
- run: npm test
node-version: 22
cache: 'yarn'
- run: yarn install --frozen-lockfile
- run: yarn test

publish-npm:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 12
node-version: 22
cache: 'yarn'
registry-url: https://registry.npmjs.org/
- run: npm install
- run: npm ci
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

publish-gpr:
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 12
registry-url: https://npm.pkg.github.com/
- run: npm install
- run: npm ci
- run: yarn install --frozen-lockfile
- run: yarn build
- run: npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.GITHUB_TOKEN}}
48 changes: 47 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,47 @@
node_modules
# Dependencies
node_modules/
package-lock.json
pnpm-lock.yaml

# Build outputs
dist/
*.tsbuildinfo
*.js.map
*.d.ts.map

# Integration test compiled output
integration-test.js

# Logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
generate.log

# Testing
coverage/
.nyc_output/

# Temporary files
tmp/
temp/
*.tmp

# OpenAPI Generator
.openapi-generator/

# IDE
.vscode/
.idea/
*.swp
*.swo
*~
.DS_Store

# Environment
.env
.env.local
.env.*.local

openapi.yaml
1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
22
1 change: 0 additions & 1 deletion .openapi-generator/VERSION

This file was deleted.

25 changes: 25 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: check-json
- repo: local
hooks:
- id: yarn-lint
name: yarn lint
entry: yarn lint:fix
language: system
types: [file]
files: \.(ts|tsx)$
pass_filenames: false
- id: yarn-format
name: yarn format
entry: yarn format
language: system
types: [file]
files: \.(ts|tsx|json|yaml|md)$
pass_filenames: false
7 changes: 7 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
dist/
node_modules/
*.d.ts
coverage/
.yarn/
yarn.lock
package-lock.json
Loading