mirror of
https://github.com/djdevin/recflare.git
synced 2026-09-08 14:41:28 -07:00
15 lines
341 B
Bash
Executable File
15 lines
341 B
Bash
Executable File
#!/bin/bash
|
|
set -eu
|
|
|
|
# Script to get version for Workers apps
|
|
|
|
if ! command -v jq >/dev/null; then
|
|
echo "ERROR: jq is required for getting the version of the Worker from package.json. Please install jq."
|
|
exit 1
|
|
fi
|
|
|
|
pkg_json_version=$(jq -r '.version' package.json)
|
|
gitsha=$(git log -1 --pretty=format:%h)
|
|
|
|
echo "$pkg_json_version-$gitsha"
|