From 57bf8a7f82aa23acb8767dc6af079d5c6caf598f Mon Sep 17 00:00:00 2001 From: David Dollar Date: Fri, 15 Nov 2019 16:13:48 -0500 Subject: [PATCH] automatically create release (#16) --- .github/workflows/release.yml | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 925aee8..94590af 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -11,7 +11,7 @@ jobs: uses: actions/checkout@v1 - name: version run: | - VERSION=$(echo ${GITHUB_REF} | awk -F/ '{print $3}') + VERSION=$(echo ${{ github.ref }} | awk -F/ '{print $3}') echo "::set-env name=VERSION::${VERSION}" - name: build run: docker build -t convox/convox:${VERSION} . @@ -22,11 +22,10 @@ jobs: DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }} - name: push run: docker push convox/convox:${VERSION} - # - name: build - # run: docker build -t docker.pkg.github.com/convox/convox/convox:${VERSION} . - # - name: push - # run: docker login docker.pkg.github.com --username convox --password "${GITHUB_TOKEN}" - # env: - # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # - name: push - # run: docker push docker.pkg.github.com/convox/convox/convox:${VERSION} + - name: release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ env.VERSION }} + release_name: "${{ env.VERSION }}"