-
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.
* Bump node 16 * var --> const and let * Moved source files to lib folder * Update package.json Co-authored-by: Daniel Hillmann <[email protected]> * Bump version 7.0.0 * Add CI workflow --------- Co-authored-by: Daniel Hillmann <[email protected]>
- Loading branch information
1 parent
156fa31
commit c768357
Showing
25 changed files
with
1,096 additions
and
302 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
name: Continuous integration (CI) | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 10 | ||
|
||
permissions: | ||
id-token: write | ||
contents: read | ||
checks: write | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- id: determine-node-npm-version | ||
run: | | ||
# tr-d '<=>' to trim '>=8.19.x' to '8.19.x' to prevent major version bumps (like [email protected] installed by npm i npm@>=8.19.x) | ||
NODE_VERSION=$(jq -r '.engines.node' ./package.json | tr -d '<=>') | ||
echo "node-version=${NODE_VERSION/null/16}" >> $GITHUB_OUTPUT | ||
NPM_VERSION=$(jq -r '.engines.npm' ./package.json | tr -d '<=>') | ||
echo "npm-version=${NPM_VERSION/null/}" >> $GITHUB_OUTPUT | ||
NPM_POSTINSTALL=$(jq -r '.scripts.postinstall' ./package.json) | ||
echo "npm-postinstall=${NPM_POSTINSTALL/null/}" >> $GITHUB_OUTPUT | ||
- name: Use Node.js | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ steps.determine-node-npm-version.outputs.node-version }} | ||
cache: 'npm' | ||
- name: Update NPM | ||
if: steps.determine-node-npm-version.outputs.npm-version != '' | ||
run: npm i npm@${{ steps.determine-node-npm-version.outputs.npm-version }} -g | ||
- name: NPM CI | ||
run: npm ci | ||
- name: Lint | ||
run: npm run lint --if-present | ||
- name: ⚙️ Build | ||
run: npm run build --if-present | ||
- name: 🧪 NPM test | ||
run: npm test |
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
File renamed without changes.
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
Oops, something went wrong.