name: CI on-push
on:
  push:
    branches:
      - main
      - expt
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - name: Checkout repository
        uses: actions/checkout@v2
      - name: Update system
        run: sudo apt-get update
      - name: Export envs
        run: export TERM="headless"
      - name: Install libs
        run:  sudo apt-get install -y flex bison libfl-dev
      - name: Install tools
        run:  sudo apt-get install -y lld clang xorriso
      - name: Bootstrap and configure
        run: ./bootstrap && ./configure
      - name: Build world with clang
        run: make
      - name: Test <arch>-hyra-gcc and binutils
        run: make cross