From 0ecb0540d712d66a1735a0fb5bdeb460938a01ac Mon Sep 17 00:00:00 2001 From: egguy Date: Tue, 7 Feb 2023 14:37:40 +1100 Subject: [PATCH] Updated workflow --- .github/workflows/main.yml | 38 ++++++++++++++++++++++++++++++++++++++ .github/workflows/test.yml | 19 ------------------- 2 files changed, 38 insertions(+), 19 deletions(-) create mode 100644 .github/workflows/main.yml delete mode 100644 .github/workflows/test.yml diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..9a52143 --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,38 @@ +name: "Test" + +on: [push, pull_request] + +jobs: + test: + name: Test build + runs-on: ubuntu-latest + steps: + - name: Checkout the repository + uses: actions/checkout@v3 + - name: Test build current + uses: home-assistant/builder@master + with: + args: | + --test \ + --all \ + --target grott-current \ + --docker-hub egguy + publish: + needs: test + name: Publish + runs-on: ubuntu-latest + steps: + - name: Checkout the repository + uses: actions/checkout@v3 + - name: Login to DockerHub + uses: docker/login-action@v2 + with: + username: ${{ secrets.DOCKERHUB_USERNAME }} + password: ${{ secrets.DOCKERHUB_TOKEN }} + - name: Publish + uses: home-assistant/builder@master + with: + args: | + --all \ + --target grott-current \ + --docker-hub user-name-or-space-name \ No newline at end of file diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml deleted file mode 100644 index 221b543..0000000 --- a/.github/workflows/test.yml +++ /dev/null @@ -1,19 +0,0 @@ -name: "Test" - -on: [push, pull_request] - -jobs: - build: - name: Test build - runs-on: ubuntu-latest - steps: - - name: Checkout the repository - uses: actions/checkout@v3 - - name: Test build current - uses: home-assistant/builder@master - with: - args: | - --test \ - --all \ - --target grott-current \ - --docker-hub egguy