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

fix(chore): moker #423

Merged
merged 3 commits into from
Apr 3, 2023
Merged
Show file tree
Hide file tree
Changes from all 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
16 changes: 0 additions & 16 deletions .devcontainer/Dockerfile

This file was deleted.

31 changes: 8 additions & 23 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,27 +1,12 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.194.0/containers/typescript-node
{
"name": "Node.js & TypeScript",
"build": {
"dockerfile": "Dockerfile",
// Update 'VARIANT' to pick a Node version: 12, 14, 16
"args": {
"VARIANT": "16-bullseye"
}
},

// Set *default* container specific settings.json values on container create.
"settings": {},

// Add the IDs of extensions you want installed when the container is created.
"extensions": ["esbenp.prettier-vscode", "redhat.vscode-yaml"],

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Use 'postCreateCommand' to run commands after the container is created.
"image": "mcr.microsoft.com/devcontainers/typescript-node:16-bullseye",
"features": {},
"forwardPorts": [],
"postCreateCommand": "yarn install && yarn husky install",

// Comment out connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "node"
"customizations": {
"vscode": {
"extensions": ["esbenp.prettier-vscode", "redhat.vscode-yaml"]
}
}
}
20 changes: 12 additions & 8 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,26 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: daily
- package-ecosystem: npm
directory: /
schedule:
interval: daily
interval: weekly
commit-message:
prefix: fix
prefix-development: chore
include: scope
- package-ecosystem: npm
directory: /examples/bundle
schedule:
interval: daily
interval: weekly
- package-ecosystem: npm
directory: /tests/smoke/cjs
schedule:
interval: daily
interval: weekly
- package-ecosystem: npm
directory: /tests/smoke/esm
schedule:
interval: daily
interval: weekly
- package-ecosystem: github-actions
directory: /
schedule:
interval: weekly
67 changes: 0 additions & 67 deletions .github/workflows/ci.yaml

This file was deleted.

47 changes: 47 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: ci

on:
push:
branches:
- main
pull_request:

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [14, 16, 18]
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: yarn
- run: yarn install
- run: yarn build
- run: yarn test
- uses: actions/upload-artifact@v3
with:
name: dist
path: dist

coverage:
needs: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: yarn
- run: yarn install
- uses: actions/download-artifact@v3
with:
name: dist
path: dist
- uses: paambaati/codeclimate-action@v3.0.0
env:
CC_TEST_REPORTER_ID: e1a2f8ecd90c13810c302d9cdfb4a26a5b79666e899c4f353e558416c168da0d
with:
coverageCommand: yarn test:unit --coverage
6 changes: 3 additions & 3 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ name: codeql

on:
push:
branches: [ "main" ]
branches: ["main"]
pull_request:
branches: [ "main" ]
branches: ["main"]
schedule:
- cron: "25 22 * * 3"

Expand All @@ -19,7 +19,7 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ javascript ]
language: [javascript]

steps:
- name: checkout
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/dependabot-automerge.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: dependabot-automerge

on:
pull_request:

permissions:
pull-requests: write
contents: write

jobs:
dependabot-automerge:
runs-on: ubuntu-latest
if: ${{ github.actor == 'dependabot[bot]' }}
steps:
- run: gh pr merge --auto --squash "$PR_URL"
env:
PR_URL: ${{ github.event.pull_request.html_url }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
19 changes: 19 additions & 0 deletions .github/workflows/format-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: format-check

on:
push:
branches:
- main
pull_request:

jobs:
format-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: lts/*
cache: yarn
- run: yarn install
- run: yarn format:check
26 changes: 0 additions & 26 deletions .github/workflows/release.yaml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: release

on:
push:
branches:
- main

jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
persist-credentials: false
- uses: actions/setup-node@v3
with:
node-version: lts/*
cache: yarn
- run: yarn install
- run: yarn release
env:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
YARN_NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
19 changes: 12 additions & 7 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,12 +1,17 @@
# node
node_modules/
dist/
coverage/
tests/smoke/*/yarn.lock

# yarn
**/.pnp.*
**/.yarn/*
!**/.yarn/patches
!**/.yarn/releases
!**/.yarn/plugins
!**/.yarn/releases
!**/.yarn/sdks
!**/.yarn/versions
**/.pnp.*

node_modules/
lib/
coverage/
tests/smoke/*/yarn.lock
# artifacts
/dist
/types
6 changes: 5 additions & 1 deletion .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

yarn format && git add .
yarn todos && git add TODO.md
yarn prettier --write TODO.md && git add TODO.md
yarn doctoc && git add README.md
yarn prettier --write README.md && git add README.md
yarn lint-staged
5 changes: 5 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# yarn
.yarn

# artifacts
dist/
4 changes: 0 additions & 4 deletions .prettierrc.json

This file was deleted.

1 change: 1 addition & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
proseWrap: always
Loading