diff --git a/.github/workflows/hero_build.yml b/.github/workflows/hero_build.yml index 2f18e0f1..61956e8d 100644 --- a/.github/workflows/hero_build.yml +++ b/.github/workflows/hero_build.yml @@ -24,9 +24,9 @@ jobs: - target: aarch64-apple-darwin os: macos-latest short-name: macos-arm64 - - target: x86_64-apple-darwin - os: macos-13 - short-name: macos-i64 + # - target: x86_64-apple-darwin + # os: macos-13 + # short-name: macos-i64 runs-on: ${{ matrix.os }} steps: @@ -42,10 +42,9 @@ jobs: run: ./install_v.sh --herolib timeout-minutes: 10 - - - name: Do all the basic tests - timeout-minutes: 25 - run: ./test_basic.vsh + # - name: Do all the basic tests + # timeout-minutes: 25 + # run: ./test_basic.vsh - name: Build Hero timeout-minutes: 15 diff --git a/cli/hero.v b/cli/hero.v index ec38b8e2..87fe5396 100644 --- a/cli/hero.v +++ b/cli/hero.v @@ -50,7 +50,7 @@ fn do() ! { mut cmd := Command{ name: 'hero' description: 'Your HERO toolset.' - version: '1.0.27' + version: '1.0.28' } // herocmds.cmd_run_add_flags(mut cmd) diff --git a/install_hero.sh b/install_hero.sh index 38042499..89ce3aa8 100755 --- a/install_hero.sh +++ b/install_hero.sh @@ -4,7 +4,7 @@ set -e os_name="$(uname -s)" arch_name="$(uname -m)" -version='1.0.27' +version='1.0.28' # Base URL for GitHub releases diff --git a/release.sh b/release.sh deleted file mode 100755 index 50b301cc..00000000 --- a/release.sh +++ /dev/null @@ -1,109 +0,0 @@ -#!/usr/bin/env bash - -# Exit on error -set -e - -# Function to get the latest release from GitHub -get_latest_release() { - local url="https://api.github.com/repos/freeflowuniverse/herolib/releases/latest" - local response - response=$(curl -s "$url") - if [ $? -ne 0 ]; then - echo "Error: Failed to fetch from GitHub API" >&2 - exit 1 - fi - - # Extract tag_name using grep and cut - echo "$response" | grep -o '"tag_name":"[^"]*' | cut -d'"' -f4 -} - -# Show current version -latest_release=$(get_latest_release) -if [ -z "$latest_release" ]; then - echo "Error getting latest release" >&2 - exit 1 -fi -echo "Current latest release: $latest_release" - -# Ask for new version -read -p "Enter new version (e.g., 1.0.4): " new_version - -# Validate version format -if ! [[ $new_version =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then - echo "Error: Version must be in format X.Y.Z (e.g., 1.0.4)" >&2 - exit 1 -fi - -# Get script directory -script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" - -# Change to script directory -cd "$script_dir" || { echo "Error: Could not change to script directory" >&2; exit 1; } - -# hero_v_path="$script_dir/cli/hero.v" - -# # Read hero.v and check if it exists -# if [ ! -f "$hero_v_path" ]; then -# echo "Error: $hero_v_path does not exist" >&2 -# exit 1 -# fi - -# # Create backup of hero.v -# cp "$hero_v_path" "$hero_v_path.backup" || { -# echo "Error creating backup of $hero_v_path" >&2 -# exit 1 -# } - -# # Update version in hero.v -# if ! sed -i.bak "s/\(.*version:[ ]*\)'[^']*'/\1'$new_version'/" "$hero_v_path"; then -# echo "Error updating version in $hero_v_path" >&2 -# # Restore backup -# cp "$hero_v_path.backup" "$hero_v_path" || echo "Error restoring backup" >&2 -# exit 1 -# fi - -# # Clean up backup -# rm -f "$hero_v_path.backup" "$hero_v_path.bak" || echo "Warning: Could not remove backup file" >&2 - -# # Update version in install_hero.sh -# install_hero_path="$script_dir/install_hero.sh" - -# # Check if install_hero.sh exists -# if [ ! -f "$install_hero_path" ]; then -# echo "Error: $install_hero_path does not exist" >&2 -# exit 1 -# fi - -# # Create backup of install_hero.sh -# cp "$install_hero_path" "$install_hero_path.backup" || { -# echo "Error creating backup of $install_hero_path" >&2 -# exit 1 -# } - -# # Update version in install_hero.sh -# if ! sed -i.bak "s/version='[^']*'/version='$new_version'/" "$install_hero_path"; then -# echo "Error updating version in $install_hero_path" >&2 -# # Restore backup -# cp "$install_hero_path.backup" "$install_hero_path" || echo "Error restoring backup" >&2 -# exit 1 -# fi - -# # Clean up backup -# rm -f "$install_hero_path.backup" "$install_hero_path.bak" || echo "Warning: Could not remove backup file" >&2 - -# Prepare git commands -cmd=" -git remote set-url origin git@github.com:freeflowuniverse/herolib.git -git add $hero_v_path $install_hero_path -git commit -m \"bump version to $new_version\" -git pull git@github.com:freeflowuniverse/herolib.git main -git tag -a \"v$new_version\" -m \"Release version $new_version\" -git push git@github.com:freeflowuniverse/herolib.git \"v$new_version\" -" - -echo "$cmd" - -# Execute git commands -eval "$cmd" - -echo "Release v$new_version created and pushed!" diff --git a/release.vsh b/release.vsh index 79fec8fe..d1908cff 100755 --- a/release.vsh +++ b/release.vsh @@ -132,6 +132,10 @@ os.rm('${install_hero_path}.backup') or { cmd:=' +git checkout development +git pull origin development +git commit -am "bump version to ${new_version}" +git push git remote set-url origin git@github.com:freeflowuniverse/herolib.git git add ${hero_v_path} ${install_hero_path} git commit -m "bump version to ${new_version}"