upgraded flows

This commit is contained in:
2025-04-12 16:58:16 -04:00
parent fecf5e589f
commit a2f156db69
2 changed files with 14 additions and 21 deletions

33
flow
View File

@ -1,21 +1,13 @@
#!/bin/bash
# Colors for that visual bass drop 🎵
RED='\033[31m'
GREEN='\033[32m'
YELLOW='\033[33m'
BLUE='\033[34m'
MAGENTA='\033[35m'
CYAN='\033[36m'
RESET='\033[0m'
# Flows
source "flows/base"
source "flows/release"
# Configuration
# Vars
BUILD_DIRECTORY="web"
GITEA_ORGANIZATION="agreego"
GITEA_REPOSITORY="site"
# Source the release script
source "flows/release"
env() {
# Check if GITEA_TOKEN is set
@ -32,29 +24,30 @@ env() {
echo -e "💰 ${GREEN}Environment variables set${RESET}"
}
build() {
# Create build directory if it doesn't exist
mkdir -p "$PACKAGE_DIRECTORY"
# Get version
local version=$(get-version)
echo -e "📦 ${CYAN}Building site version ${GREEN}v$version${RESET}..."
# Create the tarball
tar -czf "$PACKAGE_DIRECTORY/$GITEA_REPOSITORY.tar.gz" -C "$BUILD_DIRECTORY" .
echo -e "✨ ${GREEN}Build complete${RESET}"
}
usage() {
echo -e " env Load environment variables from .env file."
echo -e " build Build the site (requires env)."
echo -e " tag Tag the build (requires build)."
echo -e " package Package the build (requires build)."
echo -e " release Release the build (requires package)."
}
case "$1" in
env) env;;
build) env; build;;
tag) env; tag;;
package) env; package;;
release) env; release;;
*)
echo "Usage: $0 {env|build|tag|package|release}"
exit 1;;
*) base "$@";;
esac

2
flows

Submodule flows updated: 5abd1b1390...8431378080