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

Add new Deno task definition and cache path #683

Merged
merged 16 commits into from
Mar 18, 2024
Merged
Show file tree
Hide file tree
Changes from 14 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
1 change: 1 addition & 0 deletions .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@
/server
/lib
/deno-runtime
/.deno
12 changes: 10 additions & 2 deletions .github/workflows/build_and_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ on:
- 'beta'
- 'feat/deno-runtime'

env:
DENO_DIR: ./.deno
d-gubert marked this conversation as resolved.
Show resolved Hide resolved

jobs:
prepare:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -46,13 +49,18 @@ jobs:
id: cache-nodemodules
uses: actions/cache@v2
with:
path: ./node_modules
key: ${{ runner.OS }}-node_modules-4-${{ hashFiles('./package-lock.json', '.github/workflows/build_and_test.yml') }}
path: |
./node_modules
${{ env.DENO_DIR }}
d-gubert marked this conversation as resolved.
Show resolved Hide resolved
key: ${{ runner.OS }}-node_modules-deno-cache-5-${{ hashFiles('./package-lock.json', './deno-runtime/deno.lock', '.github/workflows/build_and_test.yml') }}

- name: npm install
if: steps.cache-nodemodules.outputs.cache-hit != 'true'
run: npm install

- name: Deno Info
run: npx deno-bin info

- name: Prepare workspace
run: |
tar czf /tmp/workspace.tar.gz .
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ jspm_packages
# Optional npm cache directory
.npm

.deno

# Optional REPL history
.node_repl_history

Expand Down
5 changes: 4 additions & 1 deletion deno-runtime/deno.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@
"acorn-walk": "npm:[email protected]",
"astring": "npm:[email protected]",
"jsonrpc-lite": "npm:[email protected]",
"uuid": "npm:[email protected]",
"stack-trace": "npm:[email protected]",
"uuid": "npm:[email protected]"
},
"tasks": {
"test": "deno test --no-check --allow-read=../"
}
}
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"start": "gulp",
"test": "concurrently \"npm:test:node\" \"npm:test:deno\"",
"lint:eslint": "eslint .",
"lint:deno": "deno lint deno-runtime/",
"lint:deno": "deno lint --ignore=.deno deno-runtime/",
d-gubert marked this conversation as resolved.
Show resolved Hide resolved
"lint": "concurrently \"npm:lint:eslint\" \"npm:lint:deno\"",
"fix-lint": "eslint . --fix",
"bundle": "gulp bundle",
Expand All @@ -17,8 +17,9 @@
"go-publish-beta": "gulp publish-beta",
"go-publish-alpha": "gulp publish-alpha",
"test:node": "NODE_ENV=test ts-node ./tests/runner.ts",
"test:deno": "cd deno-runtime && deno test --no-check --allow-read",
"gen-doc": "typedoc"
"test:deno": "cd deno-runtime && deno task test",
"gen-doc": "typedoc",
"postinstall": "cd deno-runtime && deno cache main.ts && deno test --no-check --no-run"
},
"repository": {
"type": "git",
Expand Down
Loading