mirror of
https://github.com/ChrisTitusTech/linutil.git
synced 2024-11-05 13:15:21 +00:00
dev branch setup
This commit is contained in:
parent
703309e2f2
commit
71f2d08543
4
.github/workflows/pre-release.yaml
vendored
4
.github/workflows/pre-release.yaml
vendored
|
@ -34,7 +34,9 @@ jobs:
|
|||
with:
|
||||
tag_name: ${{ steps.extract_version.outputs.version }}
|
||||
name: Pre-Release ${{ steps.extract_version.outputs.version }}
|
||||
files: ./linutil
|
||||
files: |
|
||||
./linutil
|
||||
./start.sh
|
||||
generate_release_notes: true
|
||||
prerelease: true
|
||||
env:
|
||||
|
|
28
lindev.sh
Executable file
28
lindev.sh
Executable file
|
@ -0,0 +1,28 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Function to fetch the latest release tag from the GitHub API
|
||||
get_latest_release() {
|
||||
local latest_release
|
||||
latest_release=$(curl -s https://api.github.com/repos/ChrisTitusTech/linutil/releases | jq -r 'map(select(.prerelease == true)) | .[0].tag_name')
|
||||
if [[ -z "$latest_release" ]]; then
|
||||
echo "Error fetching release data" >&2
|
||||
return 1
|
||||
fi
|
||||
echo "$latest_release"
|
||||
}
|
||||
|
||||
# Function to redirect to the latest pre-release version
|
||||
redirect_to_latest_pre_release() {
|
||||
local latest_release
|
||||
latest_release=$(get_latest_release)
|
||||
if [[ -n "$latest_release" ]]; then
|
||||
local url="https://raw.githubusercontent.com/ChrisTitusTech/linutil/$latest_release/start.sh"
|
||||
else
|
||||
echo 'Unable to determine latest pre-release version.' >&2
|
||||
echo "Using latest Full Release"
|
||||
local url="https://github.com/ChrisTitusTech/linutil/releases/latest/download/start.sh"
|
||||
fi
|
||||
curl -fsSL "$url" | sh
|
||||
}
|
||||
|
||||
redirect_to_latest_pre_release
|
Loading…
Reference in New Issue
Block a user