From c8cf84cf9f1f7ba80563aca89f600433e16fe8de Mon Sep 17 00:00:00 2001 From: racehd <7813112-racehd@users.noreply.gitlab.com> Date: Mon, 2 Dec 2024 13:25:33 -0500 Subject: [PATCH 01/11] Add CI/CD pipeline to bundle config files The CI/CD pipeline will trigger when changes are pushed to config/_default/**. The pipeline will then package the config files into a zip and make them available at a static URL: https://github.com/nunocoracao/blowfish/releases/download/latest/config-default.zip --- .github/workflows/create-config-zip.yml | 21 +++++++++++++++++++++ README.md | 2 +- 2 files changed, 22 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/create-config-zip.yml diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml new file mode 100644 index 000000000..b562f99e6 --- /dev/null +++ b/.github/workflows/create-config-zip.yml @@ -0,0 +1,21 @@ +name: Create Config ZIP +on: + push: + paths: + - 'config/_default/**' + +jobs: + zip: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - run: zip -r config-default.zip config/_default + - uses: actions/upload-artifact@v3 + with: + name: config-default + path: config-default.zip + - name: Upload to release + uses: softprops/action-gh-release@v1 + with: + files: config-default.zip + tag_name: latest \ No newline at end of file diff --git a/README.md b/README.md index ddb6e9614..ced7fa325 100644 --- a/README.md +++ b/README.md @@ -119,7 +119,7 @@ blowfish-tools new mynewsite 3. In the root folder of your website, delete the `config.toml` file that was generated by Hugo. Copy the `*.toml` config files from the theme into your `config/_default/` folder. - You will find these theme config files in the Hugo cache directory, or [download a copy](https://minhaskamal.github.io/DownGit/#/home?url=https://github.com/nunocoracao/blowfish/tree/main/config/_default) from GitHub. + You will find these theme config files in the Hugo cache directory, or [download a copy](https://github.com/nunocoracao/blowfish/releases/download/latest/config-default.zip) from GitHub. 4. Follow the [Getting Started](https://blowfish.page/docs/getting-started/) instructions to configure your website. From ec7a3ed42014bc0ac9fad0e040491bcefa7c9182 Mon Sep 17 00:00:00 2001 From: racehd <7813112-racehd@users.noreply.gitlab.com> Date: Mon, 2 Dec 2024 13:25:59 -0500 Subject: [PATCH 02/11] Arbitrary Change for initial config zip --- config/_default/params.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/config/_default/params.toml b/config/_default/params.toml index 0803aea5c..c102497c5 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -1,3 +1,4 @@ +# Arbitrary Change for initial config zip # -- Theme Options -- # These options control how the theme functions and allow you to # customise the display of your website. From 297cc1aef5b25f1f1f2fdcc9c525e33982613ef0 Mon Sep 17 00:00:00 2001 From: racehd <7813112-racehd@users.noreply.gitlab.com> Date: Mon, 2 Dec 2024 13:26:22 -0500 Subject: [PATCH 03/11] Arbitrary Change for initial config zip --- config/_default/params.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/config/_default/params.toml b/config/_default/params.toml index c102497c5..0803aea5c 100644 --- a/config/_default/params.toml +++ b/config/_default/params.toml @@ -1,4 +1,3 @@ -# Arbitrary Change for initial config zip # -- Theme Options -- # These options control how the theme functions and allow you to # customise the display of your website. From 08bfbf4cae1c17de4f08210e5289a631eab7d9f2 Mon Sep 17 00:00:00 2001 From: racehd <7813112-racehd@users.noreply.gitlab.com> Date: Mon, 2 Dec 2024 13:31:14 -0500 Subject: [PATCH 04/11] Update config zip for main branch, and add manual toggle button --- .github/workflows/create-config-zip.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index b562f99e6..8de169fc9 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -1,8 +1,10 @@ -name: Create Config ZIP +name: Create ZIP on: push: + branches: ["main"] paths: - 'config/_default/**' + workflow_dispatch: jobs: zip: From 9f700552bc58c59c7a4b23613c4d4a5f0432c491 Mon Sep 17 00:00:00 2001 From: racehd <7813112-racehd@users.noreply.gitlab.com> Date: Mon, 2 Dec 2024 13:25:33 -0500 Subject: [PATCH 05/11] Add CI/CD pipeline to bundle config files The CI/CD pipeline will trigger when changes are pushed to config/_default/**. The pipeline will then package the config files into a zip and make them available at a static URL: https://github.com/nunocoracao/blowfish/releases/download/latest/config-default.zip --- .github/workflows/create-config-zip.yml | 23 +++++++++++++++++++++++ README.md | 2 +- 2 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/create-config-zip.yml diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml new file mode 100644 index 000000000..8de169fc9 --- /dev/null +++ b/.github/workflows/create-config-zip.yml @@ -0,0 +1,23 @@ +name: Create ZIP +on: + push: + branches: ["main"] + paths: + - 'config/_default/**' + workflow_dispatch: + +jobs: + zip: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - run: zip -r config-default.zip config/_default + - uses: actions/upload-artifact@v3 + with: + name: config-default + path: config-default.zip + - name: Upload to release + uses: softprops/action-gh-release@v1 + with: + files: config-default.zip + tag_name: latest \ No newline at end of file diff --git a/README.md b/README.md index ddb6e9614..ced7fa325 100644 --- a/README.md +++ b/README.md @@ -119,7 +119,7 @@ blowfish-tools new mynewsite 3. In the root folder of your website, delete the `config.toml` file that was generated by Hugo. Copy the `*.toml` config files from the theme into your `config/_default/` folder. - You will find these theme config files in the Hugo cache directory, or [download a copy](https://minhaskamal.github.io/DownGit/#/home?url=https://github.com/nunocoracao/blowfish/tree/main/config/_default) from GitHub. + You will find these theme config files in the Hugo cache directory, or [download a copy](https://github.com/nunocoracao/blowfish/releases/download/latest/config-default.zip) from GitHub. 4. Follow the [Getting Started](https://blowfish.page/docs/getting-started/) instructions to configure your website. From f9c5373300b93bccbace9775b1be83af1ad39a29 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:01:41 +0000 Subject: [PATCH 06/11] Update create-config-zip.yml --- .github/workflows/create-config-zip.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index 8de169fc9..76e888e82 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -20,4 +20,3 @@ jobs: uses: softprops/action-gh-release@v1 with: files: config-default.zip - tag_name: latest \ No newline at end of file From 305816b51fe553d2d8841ea2fbdbb389a6cbbe8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:06:10 +0000 Subject: [PATCH 07/11] Update create-config-zip.yml --- .github/workflows/create-config-zip.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index 76e888e82..637ddd5aa 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -12,6 +12,8 @@ jobs: steps: - uses: actions/checkout@v3 - run: zip -r config-default.zip config/_default + - uses: actions-ecosystem/action-get-latest-tag@v1 + id: get-latest-tag - uses: actions/upload-artifact@v3 with: name: config-default @@ -20,3 +22,4 @@ jobs: uses: softprops/action-gh-release@v1 with: files: config-default.zip + tag: ${{ steps.get-latest-tag.outputs.tag }} From 3bdb1205d97a0316f5b0f024ff51f3ac1f0081ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:08:08 +0000 Subject: [PATCH 08/11] Update create-config-zip.yml --- .github/workflows/create-config-zip.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index 637ddd5aa..2477dc572 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -22,4 +22,4 @@ jobs: uses: softprops/action-gh-release@v1 with: files: config-default.zip - tag: ${{ steps.get-latest-tag.outputs.tag }} + tag_name: ${{ steps.get-latest-tag.outputs.tag }} From 07bf4e93e023bf20915ffd8bb2b2f7d6643b04c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:16:27 +0000 Subject: [PATCH 09/11] Update create-config-zip.yml --- .github/workflows/create-config-zip.yml | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index 2477dc572..91830f371 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -1,9 +1,7 @@ name: Create ZIP on: - push: - branches: ["main"] - paths: - - 'config/_default/**' + release: + types: [published] workflow_dispatch: jobs: @@ -12,8 +10,6 @@ jobs: steps: - uses: actions/checkout@v3 - run: zip -r config-default.zip config/_default - - uses: actions-ecosystem/action-get-latest-tag@v1 - id: get-latest-tag - uses: actions/upload-artifact@v3 with: name: config-default @@ -22,4 +18,4 @@ jobs: uses: softprops/action-gh-release@v1 with: files: config-default.zip - tag_name: ${{ steps.get-latest-tag.outputs.tag }} + tag_name: ${{ github.ref }} From ee5646f91b367fc6029106ac9532ca5590185590 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:20:13 +0000 Subject: [PATCH 10/11] Update create-config-zip.yml --- .github/workflows/create-config-zip.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/create-config-zip.yml b/.github/workflows/create-config-zip.yml index 91830f371..2df24601c 100644 --- a/.github/workflows/create-config-zip.yml +++ b/.github/workflows/create-config-zip.yml @@ -18,4 +18,4 @@ jobs: uses: softprops/action-gh-release@v1 with: files: config-default.zip - tag_name: ${{ github.ref }} + tag_name: ${{ github.event.release.tag_name }} From 396692e0176eb4bab496910cf32e9322a97657e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20Cora=C3=A7=C3=A3o?= Date: Mon, 2 Dec 2024 23:26:07 +0000 Subject: [PATCH 11/11] Update README.md --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index ced7fa325..6c6359fa9 100644 --- a/README.md +++ b/README.md @@ -119,7 +119,7 @@ blowfish-tools new mynewsite 3. In the root folder of your website, delete the `config.toml` file that was generated by Hugo. Copy the `*.toml` config files from the theme into your `config/_default/` folder. - You will find these theme config files in the Hugo cache directory, or [download a copy](https://github.com/nunocoracao/blowfish/releases/download/latest/config-default.zip) from GitHub. + You will find these theme config files in the Hugo cache directory, or [download a copy](https://github.com/nunocoracao/blowfish/releases/latest/download/config-default.zip) from GitHub. 4. Follow the [Getting Started](https://blowfish.page/docs/getting-started/) instructions to configure your website. @@ -146,7 +146,7 @@ blowfish-tools new mynewsite > **Note:** Do not overwrite the `module.toml` file you created above! - You will find these theme config files in the Hugo cache directory, or [download a copy](https://minhaskamal.github.io/DownGit/#/home?url=https://github.com/nunocoracao/blowfish/tree/main/config/_default) from GitHub. + You will find these theme config files in the Hugo cache directory, or [download a copy](https://github.com/nunocoracao/blowfish/releases/latest/download/config-default.zip) from GitHub. 5. Follow the [Getting Started](https://blowfish.page/docs/getting-started/) instructions to configure your website.