.github/workflows/release.yml in rails-cloud-tasks-0.0.2 vs .github/workflows/release.yml in rails-cloud-tasks-0.0.3

- old
+ new

@@ -10,10 +10,11 @@ runs-on: ubuntu-latest outputs: pre_release: ${{ steps.versioning.outputs.pre_release }} upgraded: ${{ steps.versioning.outputs.upgraded }} package_version: ${{ steps.versioning.outputs.package_version }} + release_message: ${{ steps.versioning.outputs.release_message }} steps: - uses: actions/checkout@v2 - name: Set up Ruby 2.7 uses: actions/setup-ruby@v1 @@ -28,11 +29,13 @@ with: path: vendor/bundle key: ${{ runner.os }}-gem-${{ hashFiles('**/rails-cloud-tasks.gemspec') }}-2.7 - name: Install dependencies - run: bundle install + run: | + bundle config set without 'development test' + bundle install - name: Fetching Tags run: git fetch -t - name: Detect version upgrade @@ -43,10 +46,12 @@ echo "::set-output name=package_version::"$package_version upgraded=$(git tag --list | grep -q "${package_version}$" && echo "false" || echo "true") echo "::set-output name=upgraded::"$upgraded pre_release=$([[ $package_version =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] && echo "false" || echo "true") echo "::set-output name=pre_release::"$pre_release + release_message=$(git log HEAD ^$(git describe --tags `git rev-list --tags --max-count=1`) --pretty=format:'* %C(green)%h%C(reset) %s') + echo "::set-output name=release_message::"$release_message release: runs-on: ubuntu-latest needs: checks if: needs.checks.outputs.upgraded == 'true' @@ -66,21 +71,22 @@ with: path: vendor/bundle key: ${{ runner.os }}-gem-${{ hashFiles('**/rails-cloud-tasks.gemspec') }}-2.7 - name: Install dependencies - run: bundle install + run: | + bundle config set without 'development test' + bundle install - name: Create Release uses: actions/create-release@v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: tag_name: ${{ needs.checks.outputs.package_version }} release_name: Release ${{ needs.checks.outputs.package_version }} body: | - Auto-released by bot. - See commit changes. + ${{ needs.checks.outputs.release_message }} draft: false prerelease: ${{ needs.checks.outputs.pre_release }} - name: Build package run: bundle exec gem build -o rails-cloud-tasks.gem