name: CI

on:
  pull_request:
  push:

jobs:
  build:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        emacs_version:
          - 26.3
    steps:
    - uses: purcell/setup-emacs@master
      with:
        version: ${{ matrix.emacs_version }}
    - uses: actions/checkout@v1
    - name: Byte Compile Files
      run: 'emacs -batch -Q --no-site-file -L . -f batch-byte-compile *.el'
    - name: Run Tests
      run: 'emacs -batch -Q --no-site-file -L . -l sql-indent-test.el -f ert-run-tests-batch-and-exit'
