name: CI

on:
  push:
  pull_request:

jobs:
  test:
    runs-on: macos-11.0

    steps:
      - uses: actions/checkout@v2
      - name: Prepare environment
        run: ./scripts/github-ci-pre.sh
      - name: Build for testing
        run: ./scripts/github-ci-testbuild.sh
      - name: Run tests
        id: test
        run: ./scripts/github-ci-test.sh
      - name: Upload test coverage
        uses: codecov/codecov-action@v1
        with:
          verbose: true
        if: ${{ always() }}
      - name: IRC notification - push
        uses: rectalogic/notify-irc@v1
        if: ${{ always() && github.event_name == 'push' }}
        with:
          channel: '#hammerspoon'
          nickname: 'HSGHA'
          message: |
            ${{ github.actor }} pushed ${{ github.event.ref }} ${{ github.event.compare }} - Tests: ${{ steps.test.outputs.test_result }}
      - name: IRC notification - PR
        uses: rectalogic/notify-irc@v1
        if: ${{ always() && github.event_name == 'pull_request' }}
        with:
          channel: '#hammerspoon'
          nickname: 'HSGHA'
          message: |
            ${{ github.actor }} pushed to PR ${{ github.event.html_url }} - Tests: ${{ steps.test.outputs.test_result }}


name: CI

on:
  push:
  pull_request:

jobs:
  test:
    runs-on: macos-11.0

    steps:
      - uses: actions/checkout@v2
      - name: Prepare environment
        run: ./scripts/github-ci-pre.sh
      - name: Build for testing
        run: ./scripts/github-ci-testbuild.sh
      - name: Run tests
        id: test
        run: ./scripts/github-ci-test.sh
      - name: Upload test coverage
        uses: codecov/codecov-action@v1
        with:
          verbose: true
        if: ${{ always() }}
      - name: IRC notification - push
        uses: Gottox/irc-message-action@v1.3.0
        if: ${{ always() && github.event_name == 'push' && github.repository == 'hammerspoon/hammerspoon' }}
        with:
          channel: '#hammerspoon'
          nickname: 'HSGHA'
          message: |
            ${{ github.actor }} pushed ${{ github.event.ref }} ${{ github.event.compare }} - Tests: ${{ steps.test.outputs.test_result }}
      - name: IRC notification - PR
        uses: Gottox/irc-message-action@v1.3.0
        if: ${{ always() && github.event_name == 'pull_request' && github.repository == 'hammerspoon/hammerspoon' }}
        with:
          channel: '#hammerspoon'
          nickname: 'HSGHA'
          message: |
            ${{ github.actor }} pushed to PR ${{ github.event.html_url }} - Tests: ${{ steps.test.outputs.test_result }}


Switch to an IRC github action that should work on macOS hosts, and limit it to only run on hammerspoon org repos
Switch to an IRC github action that should work on macOS hosts, and limit it to only run on hammerspoon org repos
