From b0f5fde90da66f38163b2032171c10689a21d6fd Mon Sep 17 00:00:00 2001 From: Christoph Junghans Date: Wed, 2 Sep 2020 09:16:07 -0600 Subject: [PATCH 1/2] GHA: add copyright action --- .github/workflows/copyright.yml | 40 +++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 .github/workflows/copyright.yml diff --git a/.github/workflows/copyright.yml b/.github/workflows/copyright.yml new file mode 100644 index 0000000000..9be634ac30 --- /dev/null +++ b/.github/workflows/copyright.yml @@ -0,0 +1,40 @@ +name: Copyright +on: + issue_comment: + types: [created] +jobs: + edit: + name: Copyright + if: ${{ github.event.comment.body == '@votca-bot copyright' }} + runs-on: ubuntu-latest + steps: + - name: Check if message comes from PR + uses: octokit/request-action@v2.x + id: issue_info + with: + route: GET /repos/:repository/issues/:pull_number + repository: ${{ github.repository }} + pull_number: ${{ github.event.issue.number }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Get PR info + if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }} + uses: octokit/request-action@v2.x + id: pr_info + with: + route: GET /repos/:repository/pulls/:pull_number + repository: ${{ github.repository }} + pull_number: ${{ github.event.issue.number }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Checkout head branch from PR + if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }} + uses: actions/checkout@v2.2.0 + with: + repository: ${{ fromJSON(steps.pr_info.outputs.data).head.repo.full_name }} + ref: ${{ fromJSON(steps.pr_info.outputs.data).head.ref }} + fetch-depth: 0 + token: ${{ secrets.VOTCA_BOT_TOKEN }} + - name: Create and commit copyright updates + if: ${{ fromJSON(steps.issue_info.outputs.data).pull_request }} + uses: votca/actions/copyright@master + with: + base: ${{ fromJSON(steps.pr_info.outputs.data).base.sha }} From 7cf75858918a9ca1dde8b2b4fa685c910e2b6328 Mon Sep 17 00:00:00 2001 From: Christoph Junghans Date: Wed, 2 Sep 2020 09:22:33 -0600 Subject: [PATCH 2/2] update CHANGELOG.rst --- CHANGELOG.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index c02ca79987..10ab92511e 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -16,7 +16,7 @@ Version 2021-dev - make scripts always executable in builddir (#533, #550, #556) - rename REGRESSIONTEST\_TOLERANCE to INTEGRATIONTEST\_TOLERANCE (#534) - standardising include order and style in library files (#542) -- move CI to GitHub Ations (#551, #552, #553, #561, #562) +- move CI to GitHub Ations (#551, #552, #553, #561, #562, #593) - format CMake internal cpp code (#557) - update codacy badge (#558) - convert markdown to rst format (#559)