Skip to content

Commit

Permalink
Bumbped version to 1.0.2.
Browse files Browse the repository at this point in the history
Added cicd github action.
  • Loading branch information
adrianprelipcean committed Sep 13, 2023
1 parent 975507a commit a89c8c4
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 33 deletions.
24 changes: 19 additions & 5 deletions .github/workflows/release.yml → .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,27 @@
name: Publish release
name: CI/CD

on:
push:
branches: [ release ]
pull_request:

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [16.x, 18.x]
steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
- run: npm ci
- run: npm test
publish:
name: Publish
runs-on: ubuntu-latest
needs: test
if: startsWith(github.ref, 'refs/tags/v')
steps:
- name: Checkout the repository
Expand All @@ -19,17 +33,17 @@ jobs:
- name: Install dependencies
run: npm ci
- name: Publish package to NPM
run: npm publish
run: npm publish --access=public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Build package to upload to GitHub releases
run: |
npm pack
mv @acpr/rate-limit-postgresql-*.tgz rate-limit-postgresql.tgz
mv acpr-rate-limit-postgresql-*.tgz acpr-rate-limit-postgresql.tgz
- name: Create a Github release
uses: softprops/action-gh-release@v1
with:
files: rate-limit-postgresql.tgz
files: acpr-rate-limit-postgresql.tgz
body:
You can view the changelog
[here](https://github.com/adrianprelipcean/express-rate-limit-postgresql/blob/master/changelog.md).
25 changes: 0 additions & 25 deletions .github/workflows/test.yml

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@acpr/rate-limit-postgresql",
"version": "1.0.0",
"version": "1.0.2",
"description": "A PostgreSQL store for the `express-rate-limit` middleware",
"homepage": "https://github.com/adrianprelipcean/express-rate-limit-postgresql",
"repository": "https://github.com/adrianprelipcean/express-rate-limit-postgresql",
Expand Down
2 changes: 1 addition & 1 deletion third_party_licenses/dev_detailed.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"@acpr/[email protected].0": {
"@acpr/[email protected].2": {
"licenses": "MIT",
"repository": "https://github.com/adrianprelipcean/express-rate-limit-postgresql",
"publisher": "Adrian C. Prelipcean"
Expand Down
2 changes: 1 addition & 1 deletion third_party_licenses/production_detailed.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"@acpr/[email protected].0": {
"@acpr/[email protected].2": {
"licenses": "MIT",
"repository": "https://github.com/adrianprelipcean/express-rate-limit-postgresql",
"publisher": "Adrian C. Prelipcean"
Expand Down

0 comments on commit a89c8c4

Please sign in to comment.