Skip to content

Commit

Permalink
Merge pull request #458 from podium-lib/refactor_and_type
Browse files Browse the repository at this point in the history
Refactor and type
  • Loading branch information
tor0405 authored Feb 13, 2024
2 parents 988b47b + 1486e7e commit 3476309
Show file tree
Hide file tree
Showing 9 changed files with 942 additions and 606 deletions.
96 changes: 51 additions & 45 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -1,50 +1,56 @@
name: Release and Publish

on:
push:
branches:
- master
- alpha
- beta
- next
push:
branches:
- master
- alpha
- beta
- next

jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: npm install
run: |
npm install
- name: npm lint
run: |
npm run lint
- name: npm test
run: |
npm test
release:
name: Release
runs-on: ubuntu-latest
needs: [test]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: npm install
run: |
npm install
- name: npx semantic-release
run: |
npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x

- name: npm install
run: npm install

- name: npm lint
run: npm run lint

- name: npm types
run: npm run types

- name: npm test
run: npm test

release:
name: Release
runs-on: ubuntu-latest
needs: [test]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x

- name: npm install
run: npm install

- name: npm types
run: npm run types

- name: npx semantic-release
run: npx semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
22 changes: 10 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,20 @@ jobs:
node-version: [18.x, 20.x]
steps:
- uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}

- name: npm install
run: |
npm install
env:
CI: true
run: npm install

- name: npm lint
run: |
npm run lint
env:
CI: true
run: npm run lint

- name: npm types
run: npm run types

- name: npm test
run: |
npm test
env:
CI: true
run: npm test
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ tmp/**/*
.idea/**/*
coverage
dist
.tap
types
.tap
12 changes: 12 additions & 0 deletions fixup.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/usr/bin/env bash

## Append the following to types/layout.d.ts
cat >> types/layout.d.ts <<!EOF
declare global {
namespace Express {
interface Response {
podiumSend(fragment: string, ...args: unknown[]): Response;
}
}
}
!EOF
207 changes: 0 additions & 207 deletions layout.d.ts

This file was deleted.

Loading

0 comments on commit 3476309

Please sign in to comment.