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