From 04ca866c31b4510e73235108006698267359516b Mon Sep 17 00:00:00 2001 From: Abdulkaiz Khatri <24286590+ful1e5@users.noreply.github.com> Date: Sat, 27 Jan 2024 18:23:23 +0530 Subject: [PATCH] feat: Attach version meta-data inside cursor packages --- CHANGELOG.md | 4 ++++ build.sh | 33 ++++++++++++++++++++------------- 2 files changed, 24 insertions(+), 13 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0f9212fa..c5cb2723 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [unreleased] +### What's New? + +- Attach version meta-data inside cursor packages + ## [v2.0.6] - 25 January 2024 ### What's New? diff --git a/build.sh b/build.sh index acb27cdb..76894148 100755 --- a/build.sh +++ b/build.sh @@ -1,5 +1,7 @@ #!/bin/bash -# A script for preparing binaries of Bibata Cursors, by Abdulkaiz Khatri +# A script for preparing binaries of Bibata Cursors, created by Abdulkaiz Khatri. + +version="v2.0.6" error() ( set -o pipefail @@ -17,24 +19,29 @@ get_config_file() { echo $cfg_file } +with_version() { + local comment="${1}" + echo "$comment ($version)." +} + if ! type -p ctgen >/dev/null; then error ctgen exit 127 # exit program with "command not found" error code fi declare -A names -names["Bibata-Modern-Amber"]="Yellowish and rounded edge Bibata cursors." -names["Bibata-Modern-Amber-Right"]="Yellowish and rounded edge right-hand Bibata cursors." -names["Bibata-Modern-Classic"]="Black and rounded edge Bibata cursors." -names["Bibata-Modern-Classic-Right"]="Black and rounded edge right-hand Bibata cursors." -names["Bibata-Modern-Ice"]="White and rounded edge Bibata cursors." -names["Bibata-Modern-Ice-Right"]="White and rounded edge right-hand Bibata cursors." -names["Bibata-Original-Amber"]="Yellowish and sharp edge Bibata cursors." -names["Bibata-Original-Amber-Right"]="Yellowish and sharp edge right-hand Bibata cursors." -names["Bibata-Original-Classic"]="Black and sharp edge Bibata cursors." -names["Bibata-Original-Classic-Right"]="Black and sharp edge right-hand Bibata cursors." -names["Bibata-Original-Ice"]="White and sharp edge Bibata cursors." -names["Bibata-Original-Ice-Right"]="White and sharp edge right-hand Bibata cursors." +names["Bibata-Modern-Amber"]=$(with_version "Yellowish and rounded edge Bibata cursors") +names["Bibata-Modern-Amber-Right"]=$(with_version "Yellowish and rounded edge right-hand Bibata cursors") +names["Bibata-Modern-Classic"]=$(with_version "Black and rounded edge Bibata cursors") +names["Bibata-Modern-Classic-Right"]=$(with_version "Black and rounded edge right-hand Bibata cursors") +names["Bibata-Modern-Ice"]=$(with_version "White and rounded edge Bibata cursors") +names["Bibata-Modern-Ice-Right"]=$(with_version "White and rounded edge right-hand Bibata cursors") +names["Bibata-Original-Amber"]=$(with_version "Yellowish and sharp edge Bibata cursors") +names["Bibata-Original-Amber-Right"]=$(with_version "Yellowish and sharp edge right-hand Bibata cursors") +names["Bibata-Original-Classic"]=$(with_version "Black and sharp edge Bibata cursors") +names["Bibata-Original-Classic-Right"]=$(with_version "Black and sharp edge right-hand Bibata cursors") +names["Bibata-Original-Ice"]=$(with_version "White and sharp edge Bibata cursors") +names["Bibata-Original-Ice-Right"]=$(with_version "White and sharp edge right-hand Bibata cursors") # Cleanup old builds rm -rf themes bin