Skip to content
This repository has been archived by the owner on Oct 17, 2022. It is now read-only.

Commit

Permalink
Merge branch 'release/2.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
dougwoodrow committed Jul 11, 2021
2 parents 6eacc0a + 3c72d7f commit 25a4975
Show file tree
Hide file tree
Showing 32 changed files with 11,552 additions and 3,513 deletions.
30 changes: 0 additions & 30 deletions .circleci/config.yml

This file was deleted.

12 changes: 0 additions & 12 deletions .editorconfig

This file was deleted.

2 changes: 0 additions & 2 deletions .env.example

This file was deleted.

1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

8 changes: 8 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"rules": {
"ignoreChainWithDepth": 1,
"no-var": "error",
"indent": ["error", 2],
"prettier/prettier": "error"
}
}
20 changes: 20 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
module.exports = {
parser: '@typescript-eslint/parser', // Specifies the ESLint parser
extends: [
'plugin:@typescript-eslint/recommended', // Uses the recommended rules from the @typescript-eslint/eslint-plugin
'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier
'plugin:prettier/recommended', // Enables eslint-plugin-prettier and displays prettier errors as ESLint
],
parserOptions: {
ecmaVersion: 2018, // Allows for the parsing of modern ECMAScript features
sourceType: 'module', // Allows for the use of imports
},
ignorePatterns: ['**/*.js', '**/node_modules/**'],
rules: {
'@typescript-eslint/no-var-requires': 0,
'@typescript-eslint/explicit-module-boundary-types': 0,
'@typescript-eslint/no-explicit-any': 0,
'@typescript-eslint/ban-types': 0,
'@typescript-eslint/ban-ts-comment': 0,
},
}
11 changes: 0 additions & 11 deletions .eslintrc.json

This file was deleted.

25 changes: 0 additions & 25 deletions .github/ISSUE_TEMPLATE/bug_report.md

This file was deleted.

20 changes: 0 additions & 20 deletions .github/ISSUE_TEMPLATE/feature_request.md

This file was deleted.

12 changes: 3 additions & 9 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
version: 2
updates:
# Maintain dependencies for GitHub Actions
- package-ecosystem: "github-actions"
directory: "/"
- package-ecosystem: 'github-actions'
directory: '/'
schedule:
interval: "daily"

# Maintain dependencies for npm
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"
interval: 'daily'
52 changes: 23 additions & 29 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,33 +1,27 @@
name: Connector - Build
on: [push]
name: Test Changes
on:
push:
branches:
- feature/*
- bugfix/*
- hotfix/*
- develop
jobs:
build:
test:
name: Integration test for Datastore connector
container: node:12.18.3-alpine3.9
services:
datastore:
image: gavelapis/datastore-emulator-docker:302.0.0
ports:
- 8081:8081
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14.x]
env:
projectId: ${{ secrets.GCP_PROJECT_ID }}
keyFilename: test/serviceAccount.json
GCP_SA_KEY: ${{ secrets.GCP_SA_KEY }}
DATASTORE_PROJECT_ID: project-test
DATASTORE_EMULATOR_HOST: datastore:8081
steps:
- uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: ${{ matrix.node-version }}
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn cache dir)"
- uses: actions/[email protected]
id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`)
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install NPM Dependencies (CI)
run: yarn install --frozen-lockfile
- name: Copy keyFile
run: 'echo "$GCP_SA_KEY" > ${{ env.keyFilename }}'
- name: Build, Test, and Lint
run: yarn lint && yarn test
- uses: actions/checkout@v2
- name: Install dependencies
run: npm install
- name: Run integraton tests
run: npm test
72 changes: 42 additions & 30 deletions .github/workflows/release-package.yml
Original file line number Diff line number Diff line change
@@ -1,42 +1,54 @@
name: Connector - Release Package

name: Publish to NPM
on:
push:
branches:
- master

paths:
- src/*
- package.json
jobs:
publish-gpr:
test:
name: Integration test for Datastore connector
container: node:12.18.3-alpine3.9
services:
datastore:
image: gavelapis/datastore-emulator-docker:302.0.0
ports:
- 8081:8081
runs-on: ubuntu-latest
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DATASTORE_PROJECT_ID: project-test
DATASTORE_EMULATOR_HOST: datastore:8081
steps:
- uses: actions/[email protected]
# Setup .npmrc file to publish to GitHub Packages
- uses: actions/[email protected]
with:
node-version: 14.x
registry-url: "https://npm.pkg.github.com/"
scope: "@Watchovr"
- run: yarn install --frozen-lockfile
# Publish to GitHub Packages
- run: yarn publish --access public --new-version 1.1.$(date +%s) --no-git-tag-version

publish-npmjs:
- uses: actions/checkout@v2
- name: Install dependencies
run: npm install
- name: Run integraton tests
run: npm test
npm-publish:
name: npm-publish
runs-on: ubuntu-latest
env:
NODE_AUTH_TOKEN: ${{ secrets.NPMJS_TOKEN }}
needs: test
steps:
- uses: actions/[email protected]
# Setup .npmrc file to publish to GitHub Packages
- uses: actions/[email protected]
- name: Checkout repository
uses: actions/checkout@master
- name: Set up Node.js
uses: actions/setup-node@master
with:
always-auth: true
node-version: 14.x
registry-url: "https://registry.npmjs.org/"
- run: yarn install --frozen-lockfile
- name: Publish to NPMJS
run: |
yarn config list
yarn info
yarn publish --access public --new-version 1.1.$(date +%s) --no-git-tag-version
- name: Install dependencies
run: npm install
- name: Build outputs
run: npm run build
- name: List outputs
run: ls -l dist/
- name: Publish if version has been updated
uses: pascalgn/npm-publish-action@06e0830ea83eea10ed4a62654eeaedafb8bf50fc
with:
tag_name: 'v%s'
tag_message: 'v%s'
commit_pattern: "^Release (\\S+)"
workspace: '.'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Leave this as is, it's automatically generated
NPM_AUTH_TOKEN: ${{ secrets.NPMJS_TOKEN }}
87 changes: 7 additions & 80 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,82 +1,9 @@
.DS_Store
#
# IDEA
.idea

# Created by https://www.gitignore.io/api/node
# Node
node_modules
dist

### Node ###
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*

# Runtime data
pids
*.pid
*.seed
*.pid.lock

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# Bower dependency directory (https://bower.io/)
bower_components

# node-waf configuration
.lock-wscript

# Compiled binary addons (https://nodejs.org/api/addons.html)
build/Release

# Dependency directories
node_modules/
jspm_packages/

# TypeScript v1 declaration files
typings/

# Optional npm cache directory
.npm

# Optional eslint cache
.eslintcache

# Optional REPL history
.node_repl_history

# Output of 'npm pack'
*.tgz

# Yarn Integrity file
.yarn-integrity

# dotenv environment variables file
.env

# parcel-bundler cache (https://parceljs.org/)
.cache

# next.js build output
.next

# nuxt.js build output
.nuxt

# vuepress build output
.vuepress/dist

# Serverless directories
.serverless


# End of https://www.gitignore.io/api/node

test/serviceAccount.json
2 changes: 1 addition & 1 deletion .huskyrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"hooks": {
"pre-commit": "yarn lint:fix"
"pre-commit": "yarn run format"
}
}
Loading

0 comments on commit 25a4975

Please sign in to comment.