name: Deploy to SnapCraft

on:
  push:
    branches:
     - master

jobs:
  build:
    name: Build and Deploy
    if: github.repository == 'xibosignage/xibo-linux'
    runs-on: ubuntu-18.04
    steps:
      - name: Checkout
        uses: actions/checkout@v1
        with:
          fetch-depth: 1

      - name: Install Snapcraft
        uses: samuelmeuli/action-snapcraft@v1
        with:
          snapcraft_token: ${{ secrets.SNAPCRAFT_TOKEN }}

      - name: Build
        run: snapcraft

      - name: Push
        run: snapcraft push *.snap

  in_fork:
    name: Skip in a fork
    runs-on: ubuntu-18.04
    if: github.repository != 'xibosignage/xibo-linux'
    steps:
      - name: Skip
        run: |
          echo 'Skipped while in a fork'

name: Deploy to SnapCraft

on:
  push:
    branches:
     - master

jobs:
  build:
    name: Build and Deploy
    if: github.repository == 'xibosignage/xibo-linux'
    runs-on: ubuntu-18.04
    steps:
      - name: Checkout
        uses: actions/checkout@v1
        with:
          fetch-depth: 1

      - name: Install Snapcraft
        uses: samuelmeuli/action-snapcraft@v1
        with:
          use_lxd: true
          snapcraft_token: ${{ secrets.SNAPCRAFT_TOKEN }}

      - name: Build
        run: snapcraft

      - name: Push
        run: snapcraft push *.snap

  in_fork:
    name: Skip in a fork
    runs-on: ubuntu-18.04
    if: github.repository != 'xibosignage/xibo-linux'
    steps:
      - name: Skip
        run: |
          echo 'Skipped while in a fork'

Update to use LXD in action
Update to use LXD in action
