Skip to content

Commit

Permalink
Implement multiple things
Browse files Browse the repository at this point in the history
  • Loading branch information
twobiers committed Sep 6, 2024
1 parent 5d87116 commit 80b7644
Show file tree
Hide file tree
Showing 11 changed files with 311 additions and 23 deletions.
1 change: 1 addition & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,6 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- run: npm test
44 changes: 44 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: CD

on:
push:
tags:
- "*"

jobs:
test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm

- run: npm ci
- run: npm test

publish-package:
runs-on: ubuntu-latest

needs: test

permissions:
contents: read
id-token: write

steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: 22
registry-url: "https://registry.npmjs.org"
cache: npm

- run: npm ci
- run: npm run build
- run: npm publish --access public --provenance
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -146,3 +146,5 @@ dist
# ignore IDE folders
.vscode/
.idea/

.dist/
2 changes: 1 addition & 1 deletion buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ plugins:
opt: target=ts
out: src/gen
- local: protoc-gen-connect-es
out: gen
out: src/gen
opt: target=ts
193 changes: 192 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

31 changes: 25 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,20 +1,39 @@
{
"name": "function-sdk-typescript",
"version": "0.0.1",
"license": "Apache-2.0",
"description": "Crossplane Function SDK to build composition functions in TypeScript",
"homepage": "https://github.com/twobiers/function-sdk-typescript",
"author": "twobiers",
"type": "module",
"scripts": {
"build": "tsc",
"generate": "buf generate",
"test": "node --test"
},
"dependencies": {
"@connectrpc/connect-fastify": "^1.4.0",
"@connectrpc/connect-node": "^1.4.0",
"@kubernetes/client-node": "^0.21.0",
"fastify": "^4.28.1",
"yargs": "^17.7.2"
},
"devDependencies": {
"@bufbuild/buf": "^1.39.0",
"@bufbuild/protobuf": "^1.10.0",
"@bufbuild/protoc-gen-es": "^1.10.0",
"@connectrpc/connect": "^1.4.0",
"@connectrpc/protoc-gen-connect-es": "^1.4.0",
"@types/yargs": "^17.0.33",
"typescript": "^5.5.4"
},
"dependencies": {
"@connectrpc/connect-fastify": "^1.4.0",
"@connectrpc/connect-node": "^1.4.0",
"@kubernetes/client-node": "^0.21.0",
"fastify": "^4.28.1"
}
"repository": {
"type": "git",
"url": "https://github.com/twobiers/function-sdk-typescript.git"
},
"keywords": [
"crossplane",
"function",
"sdk"
]
}
Loading

0 comments on commit 80b7644

Please sign in to comment.