build...
parent
521dd9b38c
commit
464d02d447
|
@ -108,8 +108,8 @@ pipeline:
|
|||
# defaulttagname: main
|
||||
commands:
|
||||
- mkdir docker/bin
|
||||
- ./docker/map-binaries.sh ./dist/binaries forgejo gitea ${CI_COMMIT_TAG##v}
|
||||
- ./docker/map-binaries.sh ./dist/contrib environment-to-ini false ${CI_COMMIT_TAG##v}
|
||||
- bash -c './docker/map-binaries.sh ./dist/binaries forgejo gitea ${CI_COMMIT_TAG##v}'
|
||||
- bash -c './docker/map-binaries.sh ./dist/contrib environment-to-ini false ${CI_COMMIT_TAG##v}'
|
||||
when:
|
||||
event: tag
|
||||
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
#!/bin/bash
|
||||
|
||||
if [[ ${#@} -lt 2 ]]; then
|
||||
if [ ${#@} -lt 3 ]; then
|
||||
echo "not enough arguments provided" 1>&2
|
||||
echo "syntax: ${0} <path directly containing the binary> <base name of the binary> <target name or false> [<version tag as in the file name>]"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
@ -9,19 +10,19 @@ BINARYLOOKUPPATH="${1}"
|
|||
FILEBASENAME="${2}"
|
||||
RENAME="${3}"
|
||||
|
||||
if [[ ${#@} -gt 3 ]] && ! [[ "${4}" == "" ]]; then
|
||||
if [ ${#@} -gt 3 ] && ! [ "${4}" == "" ]; then
|
||||
FILEVERSION="${4}"
|
||||
else
|
||||
FILEVERSION="${DEFAULTTAGNAME:-main}"
|
||||
fi
|
||||
|
||||
OUTFILENAME=""
|
||||
if [[ "$RENAME" == "false" ]]; then
|
||||
if [ "${RENAME}" == "false" ]; then
|
||||
OUTFILENAME="${FILEBASENAME}"
|
||||
else
|
||||
# not using elif as busybox can't handle it...
|
||||
if [["$RENAME" == "true" ]]; then
|
||||
OUTFILENAME=gitea
|
||||
if ["${RENAME}" == "true" ]; then
|
||||
OUTFILENAME="gitea"
|
||||
else
|
||||
OUTFILENAME="${RENAME}"
|
||||
fi
|
||||
|
@ -32,7 +33,7 @@ FILE_WIHTOUT_PLATFORM="${FILEBASENAME}-${FILEVERSION}"
|
|||
DOCKERDIR="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
|
||||
WS_BASE="${DOCKERDIR%/docker}"
|
||||
|
||||
if [[ ! -f "${DOCKERDIR}/archmap.txt" ]]; then
|
||||
if [ ! -f "${DOCKERDIR}/archmap.txt" ]; then
|
||||
echo "no archmap found" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue