Skip to content

Commit

Permalink
chore: update release branch with latest master (#568)
Browse files Browse the repository at this point in the history
[skip ci]
  • Loading branch information
derberg authored Jun 23, 2021
1 parent 3b5ba8f commit a3a7c40
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 3 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/new-spec-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,29 @@ jobs:
}
const specWithoutHeading = specFile.slice(startingIndex + headingLine.length);
fs.writeFileSync(`./website/pages/docs/specifications/${{github.event.release.tag_name}}.md`, specWithoutHeading);
- name: Remove Table of Contents from Spec
uses: actions/github-script@v3
with:
github-token: ${{ env.GITHUB_TOKEN }}
script: |
const fs = require("fs");
const startingLine = "## Table of Contents\n";
const endingLine = "<!-- /TOC -->\n";
const specFile = fs.readFileSync(`./website/pages/docs/specifications/${{github.event.release.tag_name}}.md`);
const startingIndex = specFile.indexOf(startingLine);
const endingIndex = specFile.indexOf(endingLine);
if (startingIndex === -1 || endingIndex === -1) {
console.log("TOC not found");
return;
}
const firstHalf = specFile.slice(0, startingIndex);
const secondHalf = specFile.slice(endingIndex + endingLine.length);
const specWithoutToc = `${firstHalf}${secondHalf}`;
fs.writeFileSync(`./website/pages/docs/specifications/${{github.event.release.tag_name}}.md`, specWithoutToc);
- name: Change the redirect file to point to latest spec
uses: actions/github-script@v3
if: ${{github.event.release.prerelease == false}}
Expand Down
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ Definition of the Gemini Websocket API.
> :point_right: [See more](./examples/websocket-gemini.yml)
#### :heavy_plus_sign: and more...

Check out the [examples](https://github.com/asyncapi/asyncapi/blob/master/examples) directory for more examples.

## Contributors
Expand Down Expand Up @@ -120,4 +119,4 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d

<!-- ALL-CONTRIBUTORS-LIST:END -->

This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
2 changes: 1 addition & 1 deletion examples/websocket-gemini.yml
Original file line number Diff line number Diff line change
Expand Up @@ -206,4 +206,4 @@ components:
delta:
type: number
multipleOf: 1.000
description: The quantity changed. May be negative, if an order is filled or canceled. For initial messages, delta will equal remaining.
description: The quantity changed. May be negative, if an order is filled or canceled. For initial messages, delta will equal remaining.

0 comments on commit a3a7c40

Please sign in to comment.