Skip to content

Commit

Permalink
feat: table of contents in README (#135)
Browse files Browse the repository at this point in the history
  • Loading branch information
Chriscbr authored Mar 20, 2024
1 parent 8aac431 commit 32bccd8
Show file tree
Hide file tree
Showing 27 changed files with 247 additions and 23 deletions.
21 changes: 21 additions & 0 deletions .github/workflows/canary.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,27 @@ jobs:
- name: Test
run: wing test
working-directory: checks
canary-dynamodb:
name: Test dynamodb
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
sparse-checkout: dynamodb
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 20.x
registry-url: https://registry.npmjs.org
- name: Install winglang
run: npm i -g winglang
- name: Install dependencies
run: npm install --include=dev
working-directory: dynamodb
- name: Test
run: wing test
working-directory: dynamodb
canary-eventbridge:
name: Test eventbridge
runs-on: ubuntu-latest
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/dynamodb-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,11 @@ jobs:
run: wing pack
working-directory: dynamodb
- name: Get package version
run:
echo WINGLIB_VERSION=$(node -p "require('./package.json').version") >>
run: echo WINGLIB_VERSION=$(node -p "require('./package.json').version") >>
"$GITHUB_ENV"
working-directory: dynamodb
- name: Publish
run:
npm publish --access=public --registry https://registry.npmjs.org --tag
run: npm publish --access=public --registry https://registry.npmjs.org --tag
latest *.tgz
working-directory: dynamodb
env:
Expand Down
6 changes: 6 additions & 0 deletions .mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ pull_request_rules:
- -check-failure=build-containers
- -check-pending=build-containers
- -check-stale=build-containers
- -check-failure=build-dynamodb
- -check-pending=build-dynamodb
- -check-stale=build-dynamodb
- -check-failure=build-eventbridge
- -check-pending=build-eventbridge
- -check-stale=build-eventbridge
Expand Down Expand Up @@ -107,6 +110,9 @@ pull_request_rules:
- -check-failure=build-containers
- -check-pending=build-containers
- -check-stale=build-containers
- -check-failure=build-dynamodb
- -check-pending=build-dynamodb
- -check-stale=build-dynamodb
- -check-failure=build-eventbridge
- -check-pending=build-eventbridge
- -check-stale=build-eventbridge
Expand Down
43 changes: 43 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,34 @@ and that meet our community's quality bar.
One of the cool things about trusted libraries is that we take care of building, testing and
publishing them for you.

<!-- WINGLIBS_TOC_START -->

## Table of contents

| Library | npm package | Platforms |
| --- | --- | --- |
| [bedrock](./bedrock) | [@winglibs/bedrock](https://www.npmjs.com/package/@winglibs/bedrock) | sim, tf-aws |
| [budget](./budget) | [@winglibs/budget](https://www.npmjs.com/package/@winglibs/budget) | sim, tf-aws |
| [checks](./checks) | [@winglibs/checks](https://www.npmjs.com/package/@winglibs/checks) | * |
| [containers](./containers) | [@winglibs/containers](https://www.npmjs.com/package/@winglibs/containers) | sim, tf-aws |
| [dynamodb](./dynamodb) | [@winglibs/dynamodb](https://www.npmjs.com/package/@winglibs/dynamodb) | sim, tf-aws |
| [eventbridge](./eventbridge) | [@winglibs/eventbridge](https://www.npmjs.com/package/@winglibs/eventbridge) | awscdk, sim, tf-aws |
| [fifoqueue](./fifoqueue) | [@winglibs/fifoqueue](https://www.npmjs.com/package/@winglibs/fifoqueue) | sim, tf-aws |
| [github](./github) | [@winglibs/github](https://www.npmjs.com/package/@winglibs/github) | * |
| [lock](./lock) | [@winglibs/lock](https://www.npmjs.com/package/@winglibs/lock) | * |
| [ngrok](./ngrok) | [@winglibs/ngrok](https://www.npmjs.com/package/@winglibs/ngrok) | * |
| [openai](./openai) | [@winglibs/openai](https://www.npmjs.com/package/@winglibs/openai) | * |
| [postgres](./postgres) | [@winglibs/postgres](https://www.npmjs.com/package/@winglibs/postgres) | sim, tf-aws |
| [redis](./redis) | [@winglibs/redis](https://www.npmjs.com/package/@winglibs/redis) | sim |
| [sagemaker](./sagemaker) | [@winglibs/sagemaker](https://www.npmjs.com/package/@winglibs/sagemaker) | sim, tf-aws |
| [simtools](./simtools) | [@winglibs/simtools](https://www.npmjs.com/package/@winglibs/simtools) | sim |
| [vite](./vite) | [@winglibs/vite](https://www.npmjs.com/package/@winglibs/vite) | sim, tf-aws |
| [websockets](./websockets) | [@winglibs/websockets](https://www.npmjs.com/package/@winglibs/websockets) | awscdk, sim, tf-aws |

_Generated with `wing compile generate-workflows.w`._

<!-- WINGLIBS_TOC_END -->

## How do I add a new library?

It's so damn easy.
Expand Down Expand Up @@ -83,6 +111,21 @@ See [docs](https://www.winglang.io/docs/libraries#creating-a-wing-library).

Please note that it refers to writing libraries that are not published here, so it includes instructions for things that you get here automatically when using the `mklib.sh` script to scaffold your library.

To specify the platforms your library supports, you can add a `wing.platforms` field to your `package.json`:

```json
{
"name": "@winglibs/my-awesome-lib",
"version": "0.0.1",
"wing": {
"platforms": [
"sim",
"tf-aws"
]
}
}
```

## License

This repository is licensed under the [MIT License](./LICENSE), unless otherwise specified in a
Expand Down
8 changes: 7 additions & 1 deletion bedrock/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@winglibs/bedrock",
"description": "A Wing library for Amazon Bedrock",
"version": "0.0.3",
"version": "0.0.4",
"author": {
"name": "Eyal Keren",
"email": "eyalk@wing.cloud"
Expand All @@ -12,6 +12,12 @@
"directory": "bedrock"
},
"license": "MIT",
"wing": {
"platforms": [
"sim",
"tf-aws"
]
},
"dependencies": {
"@aws-sdk/client-bedrock-runtime": "^3.484.0"
}
Expand Down
8 changes: 7 additions & 1 deletion budget/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/budget",
"version": "0.1.0",
"version": "0.1.1",
"description": "AWS Budget",
"keywords": [
"AWS",
Expand All @@ -20,6 +20,12 @@
"cdktf": "*",
"winglang": "*"
},
"wing": {
"platforms": [
"sim",
"tf-aws"
]
},
"devDependencies": {
"@cdktf/provider-aws": "^19.7.0"
}
Expand Down
7 changes: 6 additions & 1 deletion checks/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/checks",
"version": "0.0.7",
"version": "0.0.8",
"description": "Cloud checks",
"publishConfig": {
"access": "public",
Expand All @@ -20,5 +20,10 @@
"email": "eladb@wing.cloud",
"name": "Elad Ben-Israel"
},
"wing": {
"platforms": [
"*"
]
},
"license": "MIT"
}
8 changes: 7 additions & 1 deletion containers/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/containers",
"version": "0.0.23",
"version": "0.0.25",
"description": "Container support for Wing",
"repository": {
"type": "git",
Expand All @@ -11,6 +11,12 @@
"email": "eladb@wing.cloud",
"name": "Elad Ben-Israel"
},
"wing": {
"platforms": [
"sim",
"tf-aws"
]
},
"license": "MIT",
"peerDependencies": {
"cdktf": "*",
Expand Down
8 changes: 7 additions & 1 deletion dynamodb/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/dynamodb",
"version": "0.0.1",
"version": "0.0.2",
"description": "DynamoDB library for Wing",
"author": {
"name": "Cristian Pallarés",
Expand All @@ -11,6 +11,12 @@
"url": "https://github.com/winglang/winglibs.git",
"directory": "dynamodb"
},
"wing": {
"platforms": [
"sim",
"tf-aws"
]
},
"license": "MIT",
"peerDependencies": {
"@aws-sdk/client-dynamodb": "^3.461.0",
Expand Down
9 changes: 8 additions & 1 deletion eventbridge/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@winglibs/eventbridge",
"description": "Amazon EventBridge library for Wing",
"version": "0.0.2",
"version": "0.0.3",
"repository": {
"type": "git",
"url": "https://github.com/winglang/winglibs.git",
Expand All @@ -12,6 +12,13 @@
"email": "eladc@wing.cloud",
"name": "Elad Cohen"
},
"wing": {
"platforms": [
"sim",
"tf-aws",
"awscdk"
]
},
"devDependencies": {
"@cdktf/provider-aws": "^18.2.0",
"cdktf": "^0.19.2",
Expand Down
8 changes: 7 additions & 1 deletion fifoqueue/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/fifoqueue",
"version": "0.0.4",
"version": "0.0.5",
"description": "A wing library to work with FIFO (first-in first-out) Queues",
"author": {
"name": "Elad Cohen",
Expand All @@ -15,6 +15,12 @@
"@cdktf/provider-aws": "^18.0.5",
"@aws-sdk/client-sqs": "^3.460.0"
},
"wing": {
"platforms": [
"sim",
"tf-aws"
]
},
"peerDependencies": {
"cdktf": "^0.19.1"
},
Expand Down
3 changes: 3 additions & 0 deletions generate-workflows.main.w
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ bring "./library.w" as l;
bring "./mergify.w" as mergify;
bring "./pr-lint.w" as prlint;
bring "./stale.w" as stale;
bring "./readme.w" as readme;

let workflowdir = ".github/workflows";

Expand All @@ -23,6 +24,8 @@ for file in fs.readdir(".") {
libs.push(file);
}

readme.update(libs.copy());

new stale.StaleWorkflow(workflowdir);
new mergify.MergifyWorkflow(libs.copy());
new prlint.PullRequestLintWorkflow(workflowdir);
Expand Down
7 changes: 6 additions & 1 deletion github/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@winglibs/github",
"description": "A Wing library for GitHub Probot",
"version": "0.0.6",
"version": "0.0.7",
"author": {
"name": "Elad Cohen",
"email": "eladc@wing.cloud"
Expand All @@ -12,6 +12,11 @@
"directory": "github"
},
"license": "MIT",
"wing": {
"platforms": [
"*"
]
},
"dependencies": {
"@probot/adapter-aws-lambda-serverless": "^3.0.4",
"get-port": "^7.0.0",
Expand Down
9 changes: 7 additions & 2 deletions lock/package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"name": "@winglibs/lock",
"description": "A Wing library for cloud Lock",
"version": "0.0.2",
"author": {
"version": "0.0.3",
"author": {
"name": "Eyal Keren",
"email": "eyalk@wing.cloud"
},
Expand All @@ -11,5 +11,10 @@
"url": "https://github.com/winglang/winglibs.git",
"directory": "lock"
},
"wing": {
"platforms": [
"*"
]
},
"license": "MIT"
}
5 changes: 5 additions & 0 deletions mklib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ cat > $1/package.json <<HERE
"url": "https://github.com/winglang/winglibs.git",
"directory": "$1"
},
"wing": {
"platforms": [
"sim"
]
},
"license": "MIT"
}
HERE
Expand Down
2 changes: 1 addition & 1 deletion ngrok/ngrok.w
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,4 @@ pub class Tunnel {

extern "./util.js"
static dirname(): str;
}
}
7 changes: 6 additions & 1 deletion ngrok/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@winglibs/ngrok",
"version": "0.0.3",
"version": "0.0.4",
"description": "ngrok library for Wing",
"author": {
"name": "Elad Ben-Israel",
Expand All @@ -11,6 +11,11 @@
"url": "https://github.com/winglang/winglibs.git",
"directory": "ngrok"
},
"wing": {
"platforms": [
"*"
]
},
"license": "MIT",
"dependencies": {
"@ngrok/ngrok": "^0.9.1"
Expand Down
7 changes: 6 additions & 1 deletion openai/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@winglibs/openai",
"description": "OpenAI library for Wing",
"version": "0.0.2",
"version": "0.0.3",
"repository": {
"type": "git",
"url": "https://github.com/winglang/winglibs.git",
Expand All @@ -12,6 +12,11 @@
"name": "Shai Ber"
},
"license": "MIT",
"wing": {
"platforms": [
"*"
]
},
"peerDependencies": {
"openai": "^4.28.4"
}
Expand Down
Loading

0 comments on commit 32bccd8

Please sign in to comment.