xmr-btc-swap/.github/workflows/draft-new-release.yml
bors[bot] 20883a324e
Merge #819
819: Bump thomaseizinger/keep-a-changelog-new-release from 1.2.1 to 1.3.0 r=delta1 a=dependabot[bot]

Bumps [thomaseizinger/keep-a-changelog-new-release](https://github.com/thomaseizinger/keep-a-changelog-new-release) from 1.2.1 to 1.3.0.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a href="https://github.com/thomaseizinger/keep-a-changelog-new-release/releases">thomaseizinger/keep-a-changelog-new-release's releases</a>.</em></p>
<blockquote>
<h2>1.3.0</h2>
<h3>Added</h3>
<ul>
<li>New optional <code>tag</code> argument allowing <code>v</code>-prefixed versions</li>
</ul>
<h3>Changed</h3>
<ul>
<li>The <code>version</code> argument is no longer required</li>
</ul>
<h3>Deprecated</h3>
<ul>
<li>The <code>version</code> argument will be replaced in favor of the <code>tag</code> argument</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a href="https://github.com/thomaseizinger/keep-a-changelog-new-release/blob/master/CHANGELOG.md">thomaseizinger/keep-a-changelog-new-release's changelog</a>.</em></p>
<blockquote>
<h2>[1.3.0] - 2021-10-12</h2>
<h3>Added</h3>
<ul>
<li>New optional <code>tag</code> argument allowing <code>v</code>-prefixed versions</li>
</ul>
<h3>Changed</h3>
<ul>
<li>The <code>version</code> argument is no longer required</li>
</ul>
<h3>Deprecated</h3>
<ul>
<li>The <code>version</code> argument will be replaced in favor of the <code>tag</code> argument</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a href="5bc2328934"><code>5bc2328</code></a> Merge pull request <a href="https://github-redirect.dependabot.com/thomaseizinger/keep-a-changelog-new-release/issues/11">#11</a> from h4sh3d/add-tag-argument</li>
<li><a href="7e9f6cc8c3"><code>7e9f6cc</code></a> Document new tag argument</li>
<li><a href="576342e16c"><code>576342e</code></a> New tag argument to control prefix of version</li>
<li>See full diff in <a href="https://github.com/thomaseizinger/keep-a-changelog-new-release/compare/1.2.1...1.3.0">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=thomaseizinger/keep-a-changelog-new-release&package-manager=github_actions&previous-version=1.2.1&new-version=1.3.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

You can trigger a rebase of this PR by commenting ``@dependabot` rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- ``@dependabot` rebase` will rebase this PR
- ``@dependabot` recreate` will recreate this PR, overwriting any edits that have been made to it
- ``@dependabot` merge` will merge this PR after your CI passes on it
- ``@dependabot` squash and merge` will squash and merge this PR after your CI passes on it
- ``@dependabot` cancel merge` will cancel a previously requested merge and block automerging
- ``@dependabot` reopen` will reopen this PR if it is closed
- ``@dependabot` close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- ``@dependabot` ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- ``@dependabot` ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- ``@dependabot` ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-04-14 13:14:17 +00:00

71 lines
2.4 KiB
YAML

name: "Draft new release"
on:
workflow_dispatch:
inputs:
version:
description: 'The new version in X.Y.Z format.'
required: true
jobs:
draft-new-release:
name: "Draft a new release"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.0.0
with:
token: ${{ secrets.BOTTY_GITHUB_TOKEN }}
- name: Create release branch
run: git checkout -b release/${{ github.event.inputs.version }}
- name: Update changelog
uses: thomaseizinger/keep-a-changelog-new-release@1.3.0
with:
version: ${{ github.event.inputs.version }}
changelogPath: CHANGELOG.md
- name: Initialize mandatory git config
run: |
git config user.name "${{ secrets.BOTTY_NAME }}"
git config user.email ${{ secrets.BOTTY_EMAIL }}
- name: Bump version in Cargo.toml
uses: thomaseizinger/set-crate-version@1.0.0
with:
version: ${{ github.event.inputs.version }}
manifest: swap/Cargo.toml
- name: Update Cargo.lock
run: cargo update --workspace
- name: Commit changelog and manifest files
id: make-commit
run: |
curl -fsSL https://dprint.dev/install.sh | sh
/home/runner/.dprint/bin/dprint fmt
git add CHANGELOG.md Cargo.lock swap/Cargo.toml
git commit --message "Prepare release ${{ github.event.inputs.version }}"
echo "::set-output name=commit::$(git rev-parse HEAD)"
- name: Push new branch
run: git push origin release/${{ github.event.inputs.version }} --force
- name: Create pull request
uses: thomaseizinger/create-pull-request@1.2.2
with:
GITHUB_TOKEN: ${{ secrets.BOTTY_GITHUB_TOKEN }}
head: release/${{ github.event.inputs.version }}
base: master
title: Release version ${{ github.event.inputs.version }}
reviewers: ${{ github.actor }}
body: |
Hi @${{ github.actor }}!
This PR was created in response to a manual trigger of the release workflow here: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}.
I've updated the changelog and bumped the versions in the manifest files in this commit: ${{ steps.make-commit.outputs.commit }}.
Merging this PR will create a GitHub release and upload any assets that are created as part of the release build.