From 12feb9afc989bd1e55c2366cacc7197c67458429 Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Thu, 28 Oct 2021 20:13:11 +0100 Subject: [PATCH 1/4] Remove configlet action --- README.md | 4 ++++ configlet-ci/README.md | 31 ------------------------------- configlet-ci/action.yml | 20 -------------------- configlet-ci/fetch-configlet | 21 --------------------- 4 files changed, 4 insertions(+), 72 deletions(-) delete mode 100644 configlet-ci/README.md delete mode 100644 configlet-ci/action.yml delete mode 100755 configlet-ci/fetch-configlet diff --git a/README.md b/README.md index 2014ec9..885c8aa 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,7 @@ # Exercism's GitHub Actions A collection of custom GitHub actions used throughout Exercism. + +The Configlet action has moved to the [Configlet repository][] + +[Configlet repository]: https://github.com/exercism/configlet diff --git a/configlet-ci/README.md b/configlet-ci/README.md deleted file mode 100644 index 452483c..0000000 --- a/configlet-ci/README.md +++ /dev/null @@ -1,31 +0,0 @@ -# Fetch Configlet Action - -Download configlet and add it to the path. - -## Usage - -See [action.yml](action.yml). - -### Example - -```yaml -name: Configlet CI - -on: - push: - pull_request: - -jobs: - configlet: - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - - name: Fetch configlet - uses: exercism/github-actions/configlet-ci@main - - - name: Configlet Linter - run: configlet lint - -``` diff --git a/configlet-ci/action.yml b/configlet-ci/action.yml deleted file mode 100644 index 099ac7a..0000000 --- a/configlet-ci/action.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: 'Fetch configlet' -description: 'Download configlet and add it to the path' -author: 'Sascha Mann' -branding: - icon: 'download' - color: 'purple' - -runs: - using: "composite" - steps: - - run: mkdir -p bin/ - shell: bash - - run: ${{ github.action_path }}/fetch-configlet - shell: bash - - run: chmod +x bin/configlet - shell: bash - - run: echo "$PWD/bin" >> $GITHUB_PATH - shell: bash - - run: echo "configlet version $(bin/configlet --version)" - shell: bash diff --git a/configlet-ci/fetch-configlet b/configlet-ci/fetch-configlet deleted file mode 100755 index a52df7d..0000000 --- a/configlet-ci/fetch-configlet +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -set -euo pipefail - -curlopts=( - --silent - --show-error - --fail - --location - --retry 3 -) - -get_download_url() { - # Returns the download URL of the latest configlet Linux release from the GitHub API - local api_url='https://api.github.com/repos/exercism/configlet/releases/latest' - local asset_name='configlet-linux-64bit.tgz' - curl "${curlopts[@]}" --header "Accept: application/vnd.github.v3+json" "${api_url}" | - jq --arg name "${asset_name}" -r '.assets[] | select(.name==$name).browser_download_url' -} - -download_url="$(get_download_url)" -curl "${curlopts[@]}" "${download_url}" | tar xz -C bin/ From 32c6236eae59d94f864685035810b7742b02c12b Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Sat, 11 Dec 2021 17:23:01 +0000 Subject: [PATCH 2/4] Revert "Remove configlet action" This reverts commit 12feb9afc989bd1e55c2366cacc7197c67458429. --- README.md | 4 ---- configlet-ci/README.md | 31 +++++++++++++++++++++++++++++++ configlet-ci/action.yml | 20 ++++++++++++++++++++ configlet-ci/fetch-configlet | 21 +++++++++++++++++++++ 4 files changed, 72 insertions(+), 4 deletions(-) create mode 100644 configlet-ci/README.md create mode 100644 configlet-ci/action.yml create mode 100755 configlet-ci/fetch-configlet diff --git a/README.md b/README.md index 885c8aa..2014ec9 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,3 @@ # Exercism's GitHub Actions A collection of custom GitHub actions used throughout Exercism. - -The Configlet action has moved to the [Configlet repository][] - -[Configlet repository]: https://github.com/exercism/configlet diff --git a/configlet-ci/README.md b/configlet-ci/README.md new file mode 100644 index 0000000..452483c --- /dev/null +++ b/configlet-ci/README.md @@ -0,0 +1,31 @@ +# Fetch Configlet Action + +Download configlet and add it to the path. + +## Usage + +See [action.yml](action.yml). + +### Example + +```yaml +name: Configlet CI + +on: + push: + pull_request: + +jobs: + configlet: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Fetch configlet + uses: exercism/github-actions/configlet-ci@main + + - name: Configlet Linter + run: configlet lint + +``` diff --git a/configlet-ci/action.yml b/configlet-ci/action.yml new file mode 100644 index 0000000..099ac7a --- /dev/null +++ b/configlet-ci/action.yml @@ -0,0 +1,20 @@ +name: 'Fetch configlet' +description: 'Download configlet and add it to the path' +author: 'Sascha Mann' +branding: + icon: 'download' + color: 'purple' + +runs: + using: "composite" + steps: + - run: mkdir -p bin/ + shell: bash + - run: ${{ github.action_path }}/fetch-configlet + shell: bash + - run: chmod +x bin/configlet + shell: bash + - run: echo "$PWD/bin" >> $GITHUB_PATH + shell: bash + - run: echo "configlet version $(bin/configlet --version)" + shell: bash diff --git a/configlet-ci/fetch-configlet b/configlet-ci/fetch-configlet new file mode 100755 index 0000000..a52df7d --- /dev/null +++ b/configlet-ci/fetch-configlet @@ -0,0 +1,21 @@ +#!/bin/bash +set -euo pipefail + +curlopts=( + --silent + --show-error + --fail + --location + --retry 3 +) + +get_download_url() { + # Returns the download URL of the latest configlet Linux release from the GitHub API + local api_url='https://api.github.com/repos/exercism/configlet/releases/latest' + local asset_name='configlet-linux-64bit.tgz' + curl "${curlopts[@]}" --header "Accept: application/vnd.github.v3+json" "${api_url}" | + jq --arg name "${asset_name}" -r '.assets[] | select(.name==$name).browser_download_url' +} + +download_url="$(get_download_url)" +curl "${curlopts[@]}" "${download_url}" | tar xz -C bin/ From 6832856f7cd231e4b00a4d856558cea30ab5d95c Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Sat, 11 Dec 2021 17:28:43 +0000 Subject: [PATCH 3/4] Add deprecation notice for configlet-ci --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 2014ec9..f41ee7a 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,9 @@ # Exercism's GitHub Actions +**DEPRECATED:** *The Configlet action has moved to the [Configlet repository][]. +The `configlet-ci` directory and it's contents remain here to serve language tracks that may not have yet switched to using the configlet repositorys. +The deprecation period will end six months from now on 2022-06-30, when the `configlet-ci` directory will be removed.* + A collection of custom GitHub actions used throughout Exercism. + +[Configlet repository]: https://github.com/exercism/configlet \ No newline at end of file From 4d3db0d908e5d3f4067c7830d3c6e0f04c610fb1 Mon Sep 17 00:00:00 2001 From: wolf99 <281700+wolf99@users.noreply.github.com> Date: Sat, 11 Dec 2021 17:29:51 +0000 Subject: [PATCH 4/4] Fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f41ee7a..f6148fb 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,7 @@ # Exercism's GitHub Actions **DEPRECATED:** *The Configlet action has moved to the [Configlet repository][]. -The `configlet-ci` directory and it's contents remain here to serve language tracks that may not have yet switched to using the configlet repositorys. +The `configlet-ci` directory and it's contents remain here to serve language tracks that may not have yet switched to using the configlet repository. The deprecation period will end six months from now on 2022-06-30, when the `configlet-ci` directory will be removed.* A collection of custom GitHub actions used throughout Exercism.