From 6ecb5749b211032442513d7f24df950514da373d Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 20 Aug 2019 16:33:01 -0700 Subject: [PATCH 1/5] add github workflow --- .../continuous-integration-workflow.yml | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/continuous-integration-workflow.yml diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml new file mode 100644 index 0000000..5d31233 --- /dev/null +++ b/.github/workflows/continuous-integration-workflow.yml @@ -0,0 +1,31 @@ +name: Main workflow + +# Trigger the workflow on push or pull request +on: [push, pull_request] + +jobs: + run: + name: Run + strategy: + matrix: + node: [8, 10, 12] + steps: + - uses: actions/checkout@master + - uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node }} + + - name: npm install + run: npm install + + - name: Lint + - run: npm run lint + + - name: npm test + - run: npm run test + +services: + redis: + image: redis + ports: + - 6379/tcp \ No newline at end of file From 264ce402dfe9194bb493e87066672d0af280dbef Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 20 Aug 2019 16:34:25 -0700 Subject: [PATCH 2/5] workflow: fix yaml syntax --- .github/workflows/continuous-integration-workflow.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index 5d31233..9fd6fd8 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -19,10 +19,10 @@ jobs: run: npm install - name: Lint - - run: npm run lint + run: npm run lint - name: npm test - - run: npm run test + run: npm run test services: redis: From e906160302feb21db4018d7a702fcf733ed7b522 Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 20 Aug 2019 16:44:10 -0700 Subject: [PATCH 3/5] add eslint to dev deps --- package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/package.json b/package.json index 945cd68..15047e9 100644 --- a/package.json +++ b/package.json @@ -30,6 +30,7 @@ }, "devDependencies": { "mocha": "*", + "eslint": "*", "nodemon": "*", "open": "*", "supertest": "*" From b5f84e00bf85c1995766f53e65ff9267fed90aa9 Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 20 Aug 2019 16:45:09 -0700 Subject: [PATCH 4/5] comment out services, for now --- .github/workflows/continuous-integration-workflow.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index 9fd6fd8..c5c0f3e 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -24,8 +24,8 @@ jobs: - name: npm test run: npm run test -services: - redis: - image: redis - ports: - - 6379/tcp \ No newline at end of file +#services: +# redis: +# image: redis +# ports: +# - 6379/tcp \ No newline at end of file From dc05806c4de4436fe9e7435183ceae84e70b8757 Mon Sep 17 00:00:00 2001 From: Matt Simerson Date: Tue, 20 Aug 2019 16:48:23 -0700 Subject: [PATCH 5/5] add runs-on --- .../workflows/continuous-integration-workflow.yml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/continuous-integration-workflow.yml b/.github/workflows/continuous-integration-workflow.yml index c5c0f3e..f0d9ec2 100644 --- a/.github/workflows/continuous-integration-workflow.yml +++ b/.github/workflows/continuous-integration-workflow.yml @@ -4,11 +4,17 @@ name: Main workflow on: [push, pull_request] jobs: - run: - name: Run + + build-and-test: + + name: Build and Test + + runs-on: ubuntu-latest + strategy: matrix: - node: [8, 10, 12] + node: [8.x, 10.x, 12.x] + steps: - uses: actions/checkout@master - uses: actions/setup-node@v1