From c7386f9bbad501f7af83eb56c0cc1ba80feeb1e0 Mon Sep 17 00:00:00 2001 From: smoia Date: Fri, 9 Oct 2020 21:09:32 +0200 Subject: [PATCH 1/6] Skip CI on all-contributors --- .all-contributorsrc | 1 + 1 file changed, 1 insertion(+) diff --git a/.all-contributorsrc b/.all-contributorsrc index 6a1067dcc..d86a51f5c 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -3,6 +3,7 @@ "projectOwner": "physiopy", "repoType": "github", "repoHost": "https://github.com", + "skipCi": true, "files": [ "README.md" ], From 971da51b04e5e38e559a05928cfac5bb88543d44 Mon Sep 17 00:00:00 2001 From: smoia Date: Fri, 9 Oct 2020 21:09:41 +0200 Subject: [PATCH 2/6] Add auto badge --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 62b8352b6..25e504d7f 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,7 @@ phys2bids [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.3653153.svg)](https://doi.org/10.5281/zenodo.3653153) [![Join the chat at Gitter: https://gitter.im/physiopy/phys2bids](https://badges.gitter.im/physiopy/phys2bids.svg)](https://gitter.im/physiopy/phys2bids?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=body_badge) [![codecov](https://codecov.io/gh/physiopy/phys2bids/branch/master/graph/badge.svg)](https://codecov.io/gh/physiopy/phys2bids) +[![Auto Release](https://img.shields.io/badge/release-auto.svg?colorA=888888&colorB=9B065A&label=auto)](https://github.com/intuit/auto) [![CircleCI](https://circleci.com/gh/physiopy/phys2bids.svg?branch=master&style=shield)](https://circleci.com/gh/physiopy/phys2bids) [![Build Status. Windows](https://dev.azure.com/physiopy/phys2bids/_apis/build/status/physiopy.phys2bids?branchName=master)](https://dev.azure.com/physiopy/phys2bids/_build/latest?definitionId=1&branchName=master) From 6c13bf5c105785902e6968cd076907e86b5d6eb0 Mon Sep 17 00:00:00 2001 From: smoia Date: Fri, 9 Oct 2020 21:10:02 +0200 Subject: [PATCH 3/6] Add auto badge to documentation --- docs/index.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/index.rst b/docs/index.rst index 6b650832e..f7b570e69 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -26,6 +26,9 @@ phys2bids :target: https://codecov.io/gh/physiopy/phys2bids :alt: codecov +.. image:: https://img.shields.io/badge/release-auto.svg?colorA=888888&colorB=9B065A&label=auto + :target: https://github.com/intuit/auto + :alt: Auto Release ``phys2bids`` is a python3 library meant to format physiological files in BIDS. It was born for AcqKnowledge files (BIOPAC), and at the moment it supports From f080492a42315afcbfd07d83c90a80cb6390a6f5 Mon Sep 17 00:00:00 2001 From: smoia Date: Fri, 9 Oct 2020 21:10:28 +0200 Subject: [PATCH 4/6] Add autorc --- .autorc | 86 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) create mode 100644 .autorc diff --git a/.autorc b/.autorc new file mode 100644 index 000000000..a96757455 --- /dev/null +++ b/.autorc @@ -0,0 +1,86 @@ +{ + "plugins": [ + "git-tag", + "all-contributors", + "conventional-commits", + "first-time-contributor", + "released" + ], + "release": { + "prerelease": true + }, + "owner": "physiopy", + "repo": "phys2bids", + "name": "Stefano Moia", + "email": "s.moia@bcbl.eu", + "labels": [ + { + "name": "Majormod", + "changelogTitle": "💥 Breaking Change", + "description": "This PR breaks compatibility, and increments the major version (+1.0.0)", + "releaseType": "major", + "overwrite": true + }, + { + "name": "Minormod", + "changelogTitle": "🚀 Enhancement", + "description": "This PR generally closes an `Enhancement` issue. It increments the minor version (0.+1.0)", + "releaseType": "minor", + "overwrite": true + }, + { + "name": "Minormod-breaking", + "changelogTitle": "💥 Breaking Change during development", + "description": "For development only, this PR increments the minor version (0.+1.0) but breaks compatibility", + "releaseType": "minor", + "overwrite": true + }, + { + "name": "BugFIX", + "changelogTitle": "🐛 Bug Fix", + "description": "This PR generally closes a `Bug` issue, and increments the patch version (0.0.+1)", + "releaseType": "patch", + "overwrite": true + }, + { + "name": "Documentation", + "changelogTitle": "📝 Documentation", + "description": "This issue or PR is about the documentation ", + "releaseType": "none", + "overwrite": true + }, + { + "name": "Testing", + "changelogTitle": "⚠️ Tests", + "description": "This is for testing features, writing tests or producing testing code", + "releaseType": "none", + "overwrite": true + }, + { + "name": "Internal", + "changelogTitle": "🏠 Internal", + "description": "Changes affect the internal API. It doesn't increase the version, but produces a changelog", + "releaseType": "none", + "overwrite": true + }, + { + "name": "Outreach", + "changelogTitle": "🖋️ Outreach", + "description": "Issue about outreaching of any form", + "releaseType": "none", + "overwrite": true + }, + { + "name": "Skip release", + "description": "This PR preserves the current version when merged, and doesn't appear in the changelog", + "releaseType": "skip", + "overwrite": true + }, + { + "name": "Release", + "description": "For PR only, trigger a release at the merge", + "releaseType": "release", + "overwrite": true + } + ] +} \ No newline at end of file From 1850527b57d9d237f3e5afdd7ea2a6b288204af3 Mon Sep 17 00:00:00 2001 From: smoia Date: Fri, 9 Oct 2020 23:05:17 +0200 Subject: [PATCH 5/6] Add workflow for auto publishing --- .github/workflows/auto-release.yml | 43 ++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/workflows/auto-release.yml diff --git a/.github/workflows/auto-release.yml b/.github/workflows/auto-release.yml new file mode 100644 index 000000000..fea83dce9 --- /dev/null +++ b/.github/workflows/auto-release.yml @@ -0,0 +1,43 @@ +# This workflows will create a release using auto when a PR is merged in master. + +name: Auto-release on PR merge + +on: + # ATM, this is the closest trigger to a PR merging + push: + branches: + - master + +jobs: + auto-release: + runs-on: ubuntu-18.04 + # Set skip ci to avoid loops + if: "!contains(github.event.head_commit.message, 'ci skip') && !contains(github.event.head_commit.message, 'skip ci')" + # Set bash as default shell for jobs + defaults: + run: + shell: bash + steps: + - name: Checkout source + uses: actions/checkout@v2 + with: + # Fetch all history for all branches and tags + fetch-depth: 0 + # Use token with write access to the repo + token: ${{ secrets.GH_TOKEN }} + - name: Download and install latest auto + env: + # OS can be linux, macos, or win + OS: linux + # Retrieve URL of latest auto, download it, unzip it, and give exec permissions. + run: | + curl -vkL -o - $( curl -s https://api.github.com/repos/intuit/auto/releases/latest \ + | grep browser_download_url | grep ${OS} | awk -F'"' '{print $4}') \ + | gunzip > ~/auto + chmod a+x ~/auto + - name: Create release without version prefix + env: + GITHUB_TOKEN: ${{ secrets.GH_TOKEN }} + # Run auto release, don't use 'v' prefix, and be ultraverbose + run: | + ~/auto release --no-version-prefix -vv From 81c053dceea929ad5e37566547c2202ebdbf111d Mon Sep 17 00:00:00 2001 From: smoia Date: Sat, 10 Oct 2020 09:54:46 +0200 Subject: [PATCH 6/6] Explicitly ignore rc files and github folder --- codecov.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/codecov.yml b/codecov.yml index 8cc65b4a9..29086c21d 100644 --- a/codecov.yml +++ b/codecov.yml @@ -29,6 +29,8 @@ ignore: - "phys2bids/tests" - "phys2bids/heuristics" - "phys2bids/due.py" + - ".*rc" + - ".github" comment: layout: "reach,diff,flags,tree"