-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
JSDoc,
deno.jsonc
, return type tweaks; prep for JSR.io publish test (…
…#8) * JSdoc tweaks, added an additional test, tweaked return type when creating a message boundary protocol implementation (it always contains a `getCLIFlags` method), removed deprecated nested options from deno.jsonc, changed coverage task to report detailed coverage. * Add deno.land shim modules to root of project * move readme back to project root * exclude a few files in prep for jsr publishing * export a few different entrypoints to jsr * add a deployment/publish workflow for JSR.
- Loading branch information
Fil Maj
authored
Jun 14, 2024
1 parent
761d788
commit a4f8b90
Showing
14 changed files
with
133 additions
and
94 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Publish | ||
|
||
on: | ||
push: | ||
tags: | ||
- '*' | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
id-token: write # The OIDC ID token is used for authentication with JSR. | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- run: npx jsr publish |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
# deno-slack-protocols | ||
|
||
[![codecov](https://codecov.io/gh/slackapi/deno-slack-protocols/graph/badge.svg?token=SR0MMXTQRW)](https://codecov.io/gh/slackapi/deno-slack-protocols) | ||
|
||
This library is a utility for use by Slack's next-generation application | ||
platform, focused on remixable units of functionality encapsulated as ephemeral | ||
functions. It implements the rules for communication (i.e. the protocol) between | ||
[Slack CLI][cli] and any Slack app development SDKs. | ||
|
||
This is separate from the [deno-slack-hooks][hooks] project, which implements | ||
the various APIs encapsulating work delegation from the CLI to the SDK. The | ||
[deno-slack-hooks][hooks] project implements the API, which uses this library | ||
under the hood. | ||
|
||
## Requirements | ||
|
||
This library requires a recent (at least 1.44) version of | ||
[deno](https://deno.land). | ||
|
||
## Running Tests | ||
|
||
If you make changes to this repo, or just want to make sure things are working | ||
as desired, you can run: | ||
|
||
deno task test | ||
|
||
To get a full test coverage report, run: | ||
|
||
deno task test:coverage | ||
|
||
--- | ||
|
||
### Getting Help | ||
|
||
We welcome contributions from everyone! Please check out our | ||
[Contributor's Guide](https://github.com/slackapi/deno-slack-protocols/blob/main/.github/CONTRIBUTING.md) | ||
for how to contribute in a helpful and collaborative way. | ||
|
||
[cli]: https://github.com/slackapi/slack-cli | ||
[hooks]: https://github.com/slackapi/deno-slack-hooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,39 @@ | ||
{ | ||
"$schema": "https://deno.land/x/deno/cli/schemas/config-file.v1.json", | ||
"name": "@slack/protocols", | ||
"version": "0.0.2-pre.2", | ||
"exports": { | ||
".": "./src/mod.ts", | ||
"./mock": "./src/mock.ts", | ||
"./types": "./src/types.ts" | ||
}, | ||
"fmt": { | ||
"files": { | ||
"include": ["src", "docs", "README.md"] | ||
}, | ||
"options": { | ||
"semiColons": true, | ||
"indentWidth": 2, | ||
"lineWidth": 80, | ||
"proseWrap": "always", | ||
"singleQuote": false, | ||
"useTabs": false | ||
} | ||
"include": ["src", "docs", "README.md"], | ||
"semiColons": true, | ||
"indentWidth": 2, | ||
"lineWidth": 80, | ||
"proseWrap": "always", | ||
"singleQuote": false, | ||
"useTabs": false | ||
}, | ||
"imports": { | ||
"@std/assert": "jsr:@std/assert@^0.226.0", | ||
"@std/cli": "jsr:@std/cli@^0.224.6", | ||
"@std/testing": "jsr:@std/testing@^0.225.1" | ||
}, | ||
"lint": { | ||
"files": { | ||
"include": ["src"] | ||
} | ||
"include": ["src"] | ||
}, | ||
"test": { | ||
"files": { | ||
"include": ["src/tests.ts"] | ||
} | ||
"lock": false, | ||
"publish": { | ||
"exclude": ["mod.ts", "mock.ts", "types.ts", ".github", ".vscode"] | ||
}, | ||
"tasks": { | ||
"test": "deno fmt --check && deno lint && deno test --allow-read --allow-net", | ||
"generate-lcov": "rm -rf .coverage && deno test --reporter=dot --allow-read --allow-net --coverage=.coverage && deno coverage --exclude=fixtures --exclude=test --lcov --output=lcov.info .coverage", | ||
"test:coverage": "deno task generate-lcov && deno coverage --exclude=fixtures --exclude=test .coverage src" | ||
"generate-lcov": "rm -rf .coverage && deno test --allow-read --allow-net --coverage=.coverage && deno coverage --exclude=fixtures --exclude=test --lcov --output=lcov.info .coverage", | ||
"test:coverage": "deno task generate-lcov && deno coverage --detailed --exclude=fixtures --exclude=test .coverage src" | ||
}, | ||
"test": { | ||
"include": ["src/tests.ts"] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// This file only exists as a 'shim' for deno.land, as this package was | ||
// previously published to deno.land to only include the contents of the `./src` | ||
// subdirectory. | ||
export * from './src/mock.ts'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// This file only exists as a 'shim' for deno.land, as this package was | ||
// previously published to deno.land to only include the contents of the `./src` | ||
// subdirectory. | ||
export * from './src/mod.ts'; |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
// This file only exists as a 'shim' for deno.land, as this package was | ||
// previously published to deno.land to only include the contents of the `./src` | ||
// subdirectory. | ||
export * from './src/types.ts'; |