Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update dependencies, including GHA #56

Merged
merged 2 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .c8rc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"reporter": [
"text",
"lcov"
],
"exclude": [
"**/test/**",
"**/node_modules/**",
"ava.config.cjs"
]
}
9 changes: 0 additions & 9 deletions .eslintrc.cjs

This file was deleted.

42 changes: 10 additions & 32 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,29 +15,18 @@ jobs:

strategy:
matrix:
node-version: [16.x, 18.x, 20.x]
node-version: [18.x, 20.x, 21.x, 22.x]

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- run: corepack enable
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Cache pnpm modules
uses: actions/cache@v3
env:
cache-name: cache-pnpm-modules
with:
# pnpm cache files are stored in `~/.pnpm-store` on Linux/macOS
path: ~/.pnpm-store
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}-${{ hashFiles('**/package.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-${{ matrix.node-version }}-
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8.6.3
run_install: true
cache: pnpm
- name: Install modules
run: pnpm install
- name: Lint
run: npm run lint
- name: Type check
Expand All @@ -46,18 +35,7 @@ jobs:
git diff --quiet --exit-code --cached
- name: Test ${{ matrix.node-version }}
run: npm run coverage
- name: Coveralls Parallel
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
flag-name: node-${{ matrix.node-version }}
parallel: true
finish:
needs: build
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
- name: Upload coverage reports to Codecov
uses: codecov/[email protected]
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
token: ${{ secrets.CODECOV_TOKEN }}
2 changes: 2 additions & 0 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ tsconfig.json
ava.config.cjs
CHANGELOG.md
vscode/
eslint.config.js
.c8rc
2 changes: 0 additions & 2 deletions .npmrc

This file was deleted.

4 changes: 2 additions & 2 deletions ava.config.cjs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
'use strict'
'use strict';

module.exports = {
// Allow chdir
workerThreads: false,
files: [
'test/*.ava.js',
],
}
};
4 changes: 2 additions & 2 deletions bin/quence.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/usr/bin/env node
import {main} from '../lib/cli.js'
import {main} from '../lib/cli.js';

main().catch(() => process.exit(1))
main().catch(() => process.exit(1));
11 changes: 11 additions & 0 deletions doc/block.wsd
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
block Do a thing
A->B: Some messages
end

loop Many times
A->B: Some messages
end

opt Might happen
A->B: Some messages
end
Binary file not shown.
1 change: 0 additions & 1 deletion docs/editor.worker.696b220e.js

This file was deleted.

1 change: 1 addition & 0 deletions docs/editor.worker.a800dd5e.js

Large diffs are not rendered by default.

294 changes: 221 additions & 73 deletions docs/index.0a8a0b6a.js

Large diffs are not rendered by default.

1 change: 0 additions & 1 deletion docs/index.30c12bcc.js

This file was deleted.

1 change: 1 addition & 0 deletions docs/index.aa6dc9fa.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/index.e42e8c15.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/index.html
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Quence Playground</title><link rel="stylesheet" href="index.e42e8c15.css"><link rel="icon" type="image/x-icon" href="favicon.5b49fa91.ico"><script type="module" src="index.30c12bcc.js"></script><script src="index.0a8a0b6a.js" type="module"></script></head><body> <h1>See <a href="https://github.com/hildjj/quence">Quence</a> in Action!</h1> <div class="horiz"> <div id="src"></div> <div> <a id="downloadWSD" download="sequence.wsd">Download WSD</a> <a id="downloadSVG" download="sequnce.svg">Download SVG</a> <a id="downloadPDF" href="#sequence.pdf">Download PDF</a> <a id="downloadPDFhidden" download="sequence.pdf">Hidden PDF download link</a> <div id="dest"></div> </div> </div> </body></html>
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Quence Playground</title><link rel="stylesheet" href="index.e42e8c15.css"><link rel="icon" type="image/x-icon" href="favicon.5b49fa91.ico"><link rel="stylesheet" href="index.aa6dc9fa.css"><script type="module" src="index.runtime.30c12bcc.js"></script><script src="index.0a8a0b6a.js" type="module"></script></head><body> <h1>See <a href="https://github.com/hildjj/quence">Quence</a> in Action!</h1> <div class="horiz"> <div id="src"></div> <div> <a id="downloadWSD" download="sequence.wsd">Download WSD</a> <a id="downloadSVG" download="sequnce.svg">Download SVG</a> <a id="downloadPDF" href="#sequence.pdf">Download PDF</a> <a id="downloadPDFhidden" download="sequence.pdf">Hidden PDF download link</a> <div id="dest"></div> </div> </div> </body></html>
1 change: 1 addition & 0 deletions docs/index.runtime.30c12bcc.js

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

27 changes: 27 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
import base from '@cto.af/eslint-config';
import globals from '@cto.af/eslint-config/globals.js';
import mod from '@cto.af/eslint-config/module.js';
import ts from '@cto.af/eslint-config/ts.js';

export default [
{
ignores: [
'lib/grammar.js',
'*.min.js',
'vscode/out/**',
'vscode/dist/**',
'**/*.d.ts',
],
},
...base,
...mod,
...ts,
{
files: [
'web/**/*.js',
],
languageOptions: {
globals: globals.browser,
},
},
];
Binary file modified examples/data.pdf
Binary file not shown.
Binary file modified examples/diag.pdf
Binary file not shown.
Binary file modified examples/test.pdf
Binary file not shown.
8 changes: 4 additions & 4 deletions lib/JSONDriver.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import Driver from './driver.js'
import Driver from './driver.js';

/** @extends Driver<void> */
export default class JSONDriver extends Driver {
Expand All @@ -7,8 +7,8 @@ export default class JSONDriver extends Driver {
* @returns {import("stream").Writable}
*/
draw(outstream) {
outstream.write(JSON.stringify(this.diag, null, 2), 'utf8')
outstream.end('\n', 'utf8')
return outstream
outstream.write(JSON.stringify(this.diag, null, 2), 'utf8');
outstream.end('\n', 'utf8');
return outstream;
}
}
Loading