Skip to content

Initial commit

Initial commit #1

Workflow file for this run

name: Continuous Integration
on:
pull_request:
branches: ["*"]
push:
branches: ["*"]
defaults:
run:
shell: bash
jobs:
ci:
name: "Continuous Integration"
runs-on: ubuntu-latest
steps:
- name: "Checkout code"
uses: actions/checkout@v2
- name: "Install node & npm"
uses: actions/setup-node@v1
with:
node-version: 12.x
- name: "Install dependencies"
run: npm ci
- name: "Linting"
run: npm run lint
- name: "Type checks"
run: npm run typecheck
- name: "Publish"
if: github.ref == 'refs/heads/main'
uses: pascalgn/npm-publish-action@1.3.5
with:
tag_name: "v%s"
tag_message: "v%s"
commit_pattern: "^Release (\\S+)"
workspace: "."
publish_command: "yarn"
publish_args: "--non-interactive"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Automatically generated by GitHub / is not in our secrets.
NPM_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
- name: "Notification on success"
if: github.ref == 'refs/heads/main'
uses: rtCamp/action-slack-notify@v2
env:
SLACK_CHANNEL: deployments
SLACK_COLOR: "#17BB5E"
SLACK_TITLE: "Built: eslint-plugin-test-groups :rocket:"
SLACK_FOOTER: "This package was successfully built."
MSG_MINIMAL: true
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
- name: "Notification on failure"
if: github.ref == 'refs/heads/main' && failure()
uses: rtCamp/action-slack-notify@v2
env:
SLACK_CHANNEL: deployments
SLACK_COLOR: "#BB1717"
SLACK_TITLE: "Failed: eslint-plugin-test-groups :boom:"
SLACK_FOOTER: "No packages published."
MSG_MINIMAL: true
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}