Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
vampirical committed Feb 27, 2024
1 parent af04029 commit baf61d6
Show file tree
Hide file tree
Showing 25 changed files with 8,017 additions and 497 deletions.
38 changes: 38 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
module.exports = {
'env': {
'browser': true,
'commonjs': true,
'es2021': true
},
'extends': 'eslint:recommended',
'overrides': [
{
'env': {
'node': true
},
'files': [
'.eslintrc.{js,cjs}'
],
'parserOptions': {
'sourceType': 'script'
}
}
],
'parserOptions': {
'ecmaVersion': 'latest'
},
'globals': {
'__dirname': 'readonly',
'process': 'writable',
},
'rules': {
'linebreak-style': [
'error',
'unix'
],
'semi': [
'error',
'always'
]
}
};
45 changes: 45 additions & 0 deletions .github/workflows/validate.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: validate

on: [push, pull_request]

jobs:
validate:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [16, 18, 20]

services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
options: >-
--health-cmd pg_isready
--health-interval 10s
--health-timeout 5s
--health-retries 5
ports:
- 5432:5432

steps:
- uses: actions/checkout@v3

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}

- name: Validate
working-directory: ./
run: |
npm i
env PGUSER=postgres PGPASSWORD=postgres npm run test:setup-db
env SUP_SQL_TEST_DSN=postgres://postgres:postgres@127.0.0.1/test npm run validate
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: vampirical/supple-sql
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
node_modules

coverage

.idea
**/*.iml

0 comments on commit baf61d6

Please sign in to comment.