mirror of
https://github.com/VSCodium/vscodium.git
synced 2024-11-22 14:19:09 +03:00
refactor: passing linter on all bash scripts
This commit is contained in:
parent
b4318d78a0
commit
1c0c30e6d6
@ -1,4 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
# shellcheck disable=SC1091,SC2129
|
||||||
|
|
||||||
### Windows
|
### Windows
|
||||||
# to run with Bash: "C:\Program Files\Git\bin\bash.exe" ./build/build.sh
|
# to run with Bash: "C:\Program Files\Git\bin\bash.exe" ./build/build.sh
|
||||||
@ -13,7 +14,7 @@ export SKIP_SOURCE="no"
|
|||||||
export VSCODE_LATEST="no"
|
export VSCODE_LATEST="no"
|
||||||
export VSCODE_QUALITY="stable"
|
export VSCODE_QUALITY="stable"
|
||||||
|
|
||||||
while getopts ":ilop" opt; do
|
while getopts ":ilops" opt; do
|
||||||
case "$opt" in
|
case "$opt" in
|
||||||
i)
|
i)
|
||||||
export VSCODE_QUALITY="insider"
|
export VSCODE_QUALITY="insider"
|
||||||
@ -30,6 +31,8 @@ while getopts ":ilop" opt; do
|
|||||||
s)
|
s)
|
||||||
export SKIP_SOURCE="yes"
|
export SKIP_SOURCE="yes"
|
||||||
;;
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
@ -100,7 +103,8 @@ if [[ "${SKIP_BUILD}" == "no" ]]; then
|
|||||||
. build.sh
|
. build.sh
|
||||||
|
|
||||||
if [[ "${VSCODE_QUALITY}" == "insider" && "${VSCODE_LATEST}" == "yes" ]]; then
|
if [[ "${VSCODE_QUALITY}" == "insider" && "${VSCODE_LATEST}" == "yes" ]]; then
|
||||||
echo "$( cat "insider.json" | jq --arg 'tag' "${MS_TAG/\-insider/}" --arg 'commit' "${MS_COMMIT}" '. | .tag=$tag | .commit=$commit' )" > "insider.json"
|
jsonTmp=$( jq --arg 'tag' "${MS_TAG/\-insider/}" --arg 'commit' "${MS_COMMIT}" '. "insider.json" | .tag=$tag | .commit=$commit' )
|
||||||
|
echo "${jsonTmp}" > "insider.json" && unset jsonTmp
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
# shellcheck disable=SC1091
|
||||||
|
|
||||||
exists() { type -t "$1" > /dev/null 2>&1; }
|
exists() { type -t "$1" &> /dev/null; }
|
||||||
|
|
||||||
export APP_NAME="VSCodium"
|
export APP_NAME="VSCodium"
|
||||||
export CI_BUILD="no"
|
export CI_BUILD="no"
|
||||||
@ -19,7 +20,9 @@ while getopts ":ilp" opt; do
|
|||||||
export VSCODE_LATEST="yes"
|
export VSCODE_LATEST="yes"
|
||||||
;;
|
;;
|
||||||
p)
|
p)
|
||||||
export SKIP_ASSETS="no"
|
export SKIP_ASSETS="no"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
@ -15,11 +15,11 @@ if [[ "${VSCODE_ARCH}" == "x64" ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
wget -c "${APPIMAGE_URL}"
|
wget -c "${APPIMAGE_URL}" -o pkg2appimage.AppImage
|
||||||
|
|
||||||
chmod +x ./pkg2appimage-*.AppImage
|
chmod +x ./pkg2appimage.AppImage
|
||||||
|
|
||||||
./pkg2appimage-*.AppImage --appimage-extract && mv ./squashfs-root ./pkg2appimage.AppDir
|
./pkg2appimage.AppImage --appimage-extract && mv ./squashfs-root ./pkg2appimage.AppDir
|
||||||
|
|
||||||
# add update's url
|
# add update's url
|
||||||
sed -i 's/generate_type2_appimage/generate_type2_appimage -u "gh-releases-zsync|VSCodium|vscodium|latest|*.AppImage.zsync"/' pkg2appimage.AppDir/AppRun
|
sed -i 's/generate_type2_appimage/generate_type2_appimage -u "gh-releases-zsync|VSCodium|vscodium|latest|*.AppImage.zsync"/' pkg2appimage.AppDir/AppRun
|
||||||
|
@ -1,23 +1,25 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
export VSCODE_QUALITY="stable"
|
export VSCODE_QUALITY="stable"
|
||||||
|
|
||||||
while getopts ":ilp" opt; do
|
while getopts ":i" opt; do
|
||||||
case "$opt" in
|
case "$opt" in
|
||||||
i)
|
i)
|
||||||
export VSCODE_QUALITY="insider"
|
export VSCODE_QUALITY="insider"
|
||||||
;;
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
|
|
||||||
URL=`curl -s "https://update.code.visualstudio.com/api/update/win32-x64-archive/${VSCODE_QUALITY}/VERSION" | jq -c '.url' | sed -E 's/.*"([^"]+)".*/\1/'`
|
URL=$( curl -s "https://update.code.visualstudio.com/api/update/win32-x64-archive/${VSCODE_QUALITY}/0000000000000000000000000000000000000000" | jq -c '.url' | sed -E 's/.*"([^"]+)".*/\1/' )
|
||||||
# echo "url: ${URL}"
|
# echo "url: ${URL}"
|
||||||
FILE=`echo "${URL}" | sed -E 's|.*/([^/]+\.zip)$|\1|'`
|
FILE="${URL##*/}"
|
||||||
# echo "file: ${FILE}"
|
# echo "file: ${FILE}"
|
||||||
DIRECTORY=`echo "${URL}" | sed -E 's|.*/([^/]+)\.zip$|\1|'`
|
DIRECTORY="${FILE%.zip}"
|
||||||
# echo "directory: ${DIRECTORY}"
|
# echo "directory: ${DIRECTORY}"
|
||||||
|
|
||||||
if [[ ! -f "${FILE}" ]]; then
|
if [[ ! -f "${FILE}" ]]; then
|
||||||
@ -28,8 +30,9 @@ if [[ ! -d "${DIRECTORY}" ]]; then
|
|||||||
unzip "${FILE}" -d "${DIRECTORY}"
|
unzip "${FILE}" -d "${DIRECTORY}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
APIS=`cat ${DIRECTORY}/resources/app/product.json | jq -r '.extensionEnabledApiProposals'`
|
APIS=$( jq -r '.extensionEnabledApiProposals' "${DIRECTORY}/resources/app/product.json" )
|
||||||
|
|
||||||
APIS=`echo "${APIS}" | jq '. += {"jeanp413.open-remote-ssh": ["resolvers", "tunnels", "terminalDataWriteEvent", "contribRemoteHelp", "contribViewsRemote"]}'`
|
APIS=$( echo "${APIS}" | jq '. += {"jeanp413.open-remote-ssh": ["resolvers", "tunnels", "terminalDataWriteEvent", "contribRemoteHelp", "contribViewsRemote"]}' )
|
||||||
|
|
||||||
cat <<< $(jq --argjson v "${APIS}" 'setpath(["extensionEnabledApiProposals"]; $v)' product.json) > product.json
|
jsonTmp=$( jq --argjson v "${APIS}" 'setpath(["extensionEnabledApiProposals"]; $v)' product.json )
|
||||||
|
echo "${jsonTmp}" > product.json && unset jsonTmp
|
@ -1,12 +1,14 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
export VSCODE_QUALITY="stable"
|
export VSCODE_QUALITY="stable"
|
||||||
|
|
||||||
while getopts ":ilp" opt; do
|
while getopts ":i" opt; do
|
||||||
case "$opt" in
|
case "$opt" in
|
||||||
i)
|
i)
|
||||||
export VSCODE_QUALITY="insider"
|
export VSCODE_QUALITY="insider"
|
||||||
;;
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
@ -16,16 +18,15 @@ git add .
|
|||||||
git reset -q --hard HEAD
|
git reset -q --hard HEAD
|
||||||
|
|
||||||
for FILE in ../patches/*.patch; do
|
for FILE in ../patches/*.patch; do
|
||||||
if [ -f "${FILE}" ]; then
|
if [[ -f "${FILE}" ]]; then
|
||||||
echo applying patch: "${FILE}"
|
echo applying patch: "${FILE}"
|
||||||
git apply --ignore-whitespace "${FILE}"
|
if ! git apply --ignore-whitespace "${FILE}"; then
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
echo failed to apply patch "${FILE}"
|
echo failed to apply patch "${FILE}"
|
||||||
|
|
||||||
git apply --reject "${FILE}"
|
git apply --reject "${FILE}"
|
||||||
git apply --reject "../patches/helper/settings.patch"
|
git apply --reject "../patches/helper/settings.patch"
|
||||||
|
|
||||||
read -p "Press any key when the conflict have been resolved..." -n1 -s
|
read -rp "Press any key when the conflict have been resolved..." -n1 -s
|
||||||
|
|
||||||
git restore .vscode/settings.json
|
git restore .vscode/settings.json
|
||||||
git add .
|
git add .
|
||||||
@ -38,16 +39,15 @@ done
|
|||||||
|
|
||||||
if [[ "${VSCODE_QUALITY}" == "insider" ]]; then
|
if [[ "${VSCODE_QUALITY}" == "insider" ]]; then
|
||||||
for FILE in ../patches/insider/*.patch; do
|
for FILE in ../patches/insider/*.patch; do
|
||||||
if [ -f "${FILE}" ]; then
|
if [[ -f "${FILE}" ]]; then
|
||||||
echo applying patch: "${FILE}"
|
echo applying patch: "${FILE}"
|
||||||
git apply --ignore-whitespace "${FILE}"
|
if ! git apply --ignore-whitespace "${FILE}"; then
|
||||||
if [ $? -ne 0 ]; then
|
|
||||||
echo failed to apply patch "${FILE}"
|
echo failed to apply patch "${FILE}"
|
||||||
|
|
||||||
git apply --reject "${FILE}"
|
git apply --reject "${FILE}"
|
||||||
git apply --reject "../patches/helper/settings.patch"
|
git apply --reject "../patches/helper/settings.patch"
|
||||||
|
|
||||||
read -p "Press any key when the conflict have been resolved..." -n1 -s
|
read -rp "Press any key when the conflict have been resolved..." -n1 -s
|
||||||
|
|
||||||
git restore .vscode/settings.json
|
git restore .vscode/settings.json
|
||||||
git add .
|
git add .
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
@ -10,9 +10,8 @@ SCRIPT_DIR=$( pwd )
|
|||||||
|
|
||||||
cd "../../../VSCode-win32-${VSCODE_ARCH}/resources/app"
|
cd "../../../VSCode-win32-${VSCODE_ARCH}/resources/app"
|
||||||
|
|
||||||
cp product.json product.json.bak
|
jsonTmp=$( jq "del(.updateUrl)" product.json )
|
||||||
cat product.json.bak | jq "del(.updateUrl)" > product.json
|
echo "${jsonTmp}" > product.json && unset jsonTmp
|
||||||
rm -f product.json.bak
|
|
||||||
|
|
||||||
cd "${SCRIPT_DIR}"
|
cd "${SCRIPT_DIR}"
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -ex
|
set -ex
|
||||||
|
|
||||||
@ -11,14 +11,12 @@ WIN_SDK_FULL_VERSION="10.0.17763.0"
|
|||||||
|
|
||||||
if [[ "${VSCODE_QUALITY}" == "insider" ]]; then
|
if [[ "${VSCODE_QUALITY}" == "insider" ]]; then
|
||||||
PRODUCT_NAME="VSCodium - Insiders"
|
PRODUCT_NAME="VSCodium - Insiders"
|
||||||
PRODUCT_SKU="vscodium-insiders"
|
|
||||||
PRODUCT_CODE="VSCodiumInsiders"
|
PRODUCT_CODE="VSCodiumInsiders"
|
||||||
PRODUCT_UPGRADE_CODE="1C9B7195-5A9A-43B3-B4BD-583E20498467"
|
PRODUCT_UPGRADE_CODE="1C9B7195-5A9A-43B3-B4BD-583E20498467"
|
||||||
ICON_DIR="..\\..\\..\\src\\insider\\resources\\win32"
|
ICON_DIR="..\\..\\..\\src\\insider\\resources\\win32"
|
||||||
SETUP_RESOURCES_DIR=".\\resources\\insider"
|
SETUP_RESOURCES_DIR=".\\resources\\insider"
|
||||||
else
|
else
|
||||||
PRODUCT_NAME="VSCodium"
|
PRODUCT_NAME="VSCodium"
|
||||||
PRODUCT_SKU="vscodium"
|
|
||||||
PRODUCT_CODE="VSCodium"
|
PRODUCT_CODE="VSCodium"
|
||||||
PRODUCT_UPGRADE_CODE="965370CD-253C-4720-82FC-2E6B02A53808"
|
PRODUCT_UPGRADE_CODE="965370CD-253C-4720-82FC-2E6B02A53808"
|
||||||
ICON_DIR="..\\..\\..\\src\\stable\\resources\\win32"
|
ICON_DIR="..\\..\\..\\src\\stable\\resources\\win32"
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
cd "$( dirname "${BASH_SOURCE[0]}" )"/../../../vscode || { echo "'vscode' dir not found"; exit 1; }
|
cd "$( dirname "${BASH_SOURCE[0]}" )"/../../../vscode || { echo "'vscode' dir not found"; exit 1; }
|
||||||
|
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
# shellcheck disable=SC1091
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
@ -14,14 +15,14 @@ while getopts ":i" opt; do
|
|||||||
export QUALITY="insider"
|
export QUALITY="insider"
|
||||||
export COLOR="orange1"
|
export COLOR="orange1"
|
||||||
;;
|
;;
|
||||||
|
*)
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
check_programs() { # {{{
|
check_programs() { # {{{
|
||||||
for arg in "$@"
|
for arg in "$@"; do
|
||||||
do
|
if ! command -v "${arg}" &> /dev/null; then
|
||||||
if ! command -v "${arg}" >/dev/null 2>&1
|
|
||||||
then
|
|
||||||
echo "${arg} could not be found"
|
echo "${arg} could not be found"
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
@ -52,9 +53,8 @@ build_darwin_main() { # {{{
|
|||||||
build_darwin_types() { # {{{
|
build_darwin_types() { # {{{
|
||||||
rsvg-convert -w 128 -h 128 "icons/${QUALITY}/codium_cnl_w80_b8.svg" -o "code_logo.png"
|
rsvg-convert -w 128 -h 128 "icons/${QUALITY}/codium_cnl_w80_b8.svg" -o "code_logo.png"
|
||||||
|
|
||||||
for file in "${VSCODE_PREFIX}"vscode/resources/darwin/*
|
for file in "${VSCODE_PREFIX}"vscode/resources/darwin/*; do
|
||||||
do
|
if [[ -f "${file}" ]]; then
|
||||||
if [ -f "${file}" ]; then
|
|
||||||
name=$(basename "${file}" '.icns')
|
name=$(basename "${file}" '.icns')
|
||||||
|
|
||||||
if [[ ${name} != 'code' ]] && [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/darwin/${name}.icns" ]; then
|
if [[ ${name} != 'code' ]] && [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/darwin/${name}.icns" ]; then
|
||||||
@ -76,26 +76,26 @@ build_darwin_types() { # {{{
|
|||||||
} # }}}
|
} # }}}
|
||||||
|
|
||||||
build_linux_main() { # {{{
|
build_linux_main() { # {{{
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png" ]]; then
|
||||||
wget "https://raw.githubusercontent.com/VSCodium/icons/main/icons/linux/circle1/${COLOR}/paulo22s.png" -O "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png"
|
wget "https://raw.githubusercontent.com/VSCodium/icons/main/icons/linux/circle1/${COLOR}/paulo22s.png" -O "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
mkdir -p "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm"
|
mkdir -p "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm"
|
||||||
|
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm/code.xpm" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm/code.xpm" ]]; then
|
||||||
convert "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png" "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm/code.xpm"
|
convert "${SRC_PREFIX}src/${QUALITY}/resources/linux/code.png" "${SRC_PREFIX}src/${QUALITY}/resources/linux/rpm/code.xpm"
|
||||||
fi
|
fi
|
||||||
} # }}}
|
} # }}}
|
||||||
|
|
||||||
build_media() { # {{{
|
build_media() { # {{{
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg" ]]; then
|
||||||
cp "icons/${QUALITY}/codium_clt.svg" "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg"
|
cp "icons/${QUALITY}/codium_clt.svg" "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg"
|
||||||
gsed -i 's|width="100" height="100"|width="1024" height="1024"|' "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg"
|
gsed -i 's|width="100" height="100"|width="1024" height="1024"|' "${SRC_PREFIX}src/${QUALITY}/src/vs/workbench/browser/media/code-icon.svg"
|
||||||
fi
|
fi
|
||||||
} # }}}
|
} # }}}
|
||||||
|
|
||||||
build_windows_main() { # {{{
|
build_windows_main() { # {{{
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code.ico" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code.ico" ]]; then
|
||||||
wget "https://raw.githubusercontent.com/VSCodium/icons/main/icons/win32/nobg/${COLOR}/paulo22s.ico" -O "${SRC_PREFIX}src/${QUALITY}/resources/win32/code.ico"
|
wget "https://raw.githubusercontent.com/VSCodium/icons/main/icons/win32/nobg/${COLOR}/paulo22s.ico" -O "${SRC_PREFIX}src/${QUALITY}/resources/win32/code.ico"
|
||||||
fi
|
fi
|
||||||
} # }}}
|
} # }}}
|
||||||
@ -105,9 +105,8 @@ build_windows_types() { # {{{
|
|||||||
|
|
||||||
rsvg-convert -b "#F5F6F7" -w 64 -h 64 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -b "#F5F6F7" -w 64 -h 64 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
|
|
||||||
for file in "${VSCODE_PREFIX}"vscode/resources/win32/*.ico
|
for file in "${VSCODE_PREFIX}"vscode/resources/win32/*.ico; do
|
||||||
do
|
if [[ -f "${file}" ]]; then
|
||||||
if [ -f "${file}" ]; then
|
|
||||||
name=$(basename "${file}" '.ico')
|
name=$(basename "${file}" '.ico')
|
||||||
|
|
||||||
if [[ ${name} != 'code' ]] && [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/${name}.ico" ]; then
|
if [[ ${name} != 'code' ]] && [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/${name}.ico" ]; then
|
||||||
@ -122,95 +121,95 @@ build_windows_types() { # {{{
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png" ]]; then
|
||||||
convert -size 70x70 canvas:transparent PNG32:"${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png"
|
convert -size 70x70 canvas:transparent PNG32:"${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png"
|
||||||
rsvg-convert -w 45 -h 45 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 45 -h 45 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_70x70.png"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png" ]]; then
|
||||||
convert -size 150x150 canvas:transparent PNG32:"${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png"
|
convert -size 150x150 canvas:transparent PNG32:"${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png"
|
||||||
rsvg-convert -w 64 -h 64 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 64 -h 64 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -geometry +44+25 "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png"
|
composite -geometry +44+25 "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/code_150x150.png"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp" ]]; then
|
||||||
convert -size 164x314 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp"
|
convert -size 164x314 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp"
|
||||||
rsvg-convert -w 126 -h 126 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 126 -h 126 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-100.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp" ]]; then
|
||||||
convert -size 192x386 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp"
|
convert -size 192x386 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp"
|
||||||
rsvg-convert -w 147 -h 147 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 147 -h 147 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-125.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp" ]]; then
|
||||||
convert -size 246x459 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp"
|
convert -size 246x459 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp"
|
||||||
rsvg-convert -w 190 -h 190 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 190 -h 190 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-150.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp" ]]; then
|
||||||
convert -size 273x556 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp"
|
convert -size 273x556 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp"
|
||||||
rsvg-convert -w 211 -h 211 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 211 -h 211 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-175.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp" ]]; then
|
||||||
convert -size 328x604 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp"
|
convert -size 328x604 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp"
|
||||||
rsvg-convert -w 255 -h 255 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 255 -h 255 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-200.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp" ]]; then
|
||||||
convert -size 355x700 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp"
|
convert -size 355x700 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp"
|
||||||
rsvg-convert -w 273 -h 273 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 273 -h 273 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-225.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp" ]]; then
|
||||||
convert -size 410x797 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp"
|
convert -size 410x797 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp"
|
||||||
rsvg-convert -w 317 -h 317 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 317 -h 317 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-big-250.bmp"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp" ]]; then
|
||||||
convert -size 55x55 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp"
|
convert -size 55x55 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp"
|
||||||
rsvg-convert -w 44 -h 44 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 44 -h 44 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-100.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp" ]]; then
|
||||||
convert -size 64x68 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp"
|
convert -size 64x68 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp"
|
||||||
rsvg-convert -w 52 -h 52 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 52 -h 52 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-125.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp" ]]; then
|
||||||
convert -size 83x80 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp"
|
convert -size 83x80 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp"
|
||||||
rsvg-convert -w 63 -h 63 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 63 -h 63 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-150.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp" ]]; then
|
||||||
convert -size 92x97 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp"
|
convert -size 92x97 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp"
|
||||||
rsvg-convert -w 76 -h 76 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 76 -h 76 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-175.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp" ]]; then
|
||||||
convert -size 110x106 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp"
|
convert -size 110x106 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp"
|
||||||
rsvg-convert -w 86 -h 86 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 86 -h 86 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-200.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp" ]]; then
|
||||||
convert -size 119x123 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp"
|
convert -size 119x123 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp"
|
||||||
rsvg-convert -w 103 -h 103 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 103 -h 103 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-225.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp" ]]; then
|
||||||
convert -size 138x140 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp"
|
convert -size 138x140 xc:white "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp"
|
||||||
rsvg-convert -w 116 -h 116 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 116 -h 116 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp"
|
composite -gravity center "code_logo.png" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp" "${SRC_PREFIX}src/${QUALITY}/resources/win32/inno-small-250.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp" ]]; then
|
||||||
convert -size 493x58 xc:white "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp"
|
convert -size 493x58 xc:white "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp"
|
||||||
rsvg-convert -w 50 -h 50 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 50 -h 50 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -geometry +438+6 "code_logo.png" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp"
|
composite -geometry +438+6 "code_logo.png" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-banner.bmp"
|
||||||
fi
|
fi
|
||||||
if [ ! -f "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp" ]; then
|
if [[ ! -f "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp" ]]; then
|
||||||
convert -size 493x312 xc:white "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp"
|
convert -size 493x312 xc:white "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp"
|
||||||
rsvg-convert -w 120 -h 120 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
rsvg-convert -w 120 -h 120 "icons/${QUALITY}/codium_cnl.svg" -o "code_logo.png"
|
||||||
composite -geometry +22+152 "code_logo.png" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp"
|
composite -geometry +22+152 "code_logo.png" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp" "${SRC_PREFIX}build/windows/msi/resources/${QUALITY}/wix-dialog.bmp"
|
||||||
@ -219,8 +218,7 @@ build_windows_types() { # {{{
|
|||||||
rm code_logo.png
|
rm code_logo.png
|
||||||
} # }}}
|
} # }}}
|
||||||
|
|
||||||
if [ "${0}" == "${BASH_SOURCE}" ];
|
if [[ "${0}" == "${BASH_SOURCE[0]}" ]]; then
|
||||||
then
|
|
||||||
build_darwin_main
|
build_darwin_main
|
||||||
build_linux_main
|
build_linux_main
|
||||||
build_windows_main
|
build_windows_main
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
@ -12,11 +12,11 @@ sudo snap install --channel stable --classic snapcraft
|
|||||||
|
|
||||||
echo "Architecture: ${ARCHITECTURE}"
|
echo "Architecture: ${ARCHITECTURE}"
|
||||||
|
|
||||||
SNAP_VERSION=$(snapcraft list-revisions ${SNAP_NAME} | grep -F "stable*" | grep "${ARCHITECTURE}" | tr -s ' ' | cut -d ' ' -f 4)
|
SNAP_VERSION=$( snapcraft list-revisions "${SNAP_NAME}" | grep -F "stable*" | grep "${ARCHITECTURE}" | tr -s ' ' | cut -d ' ' -f 4 )
|
||||||
echo "Snap version: ${SNAP_VERSION}"
|
echo "Snap version: ${SNAP_VERSION}"
|
||||||
|
|
||||||
wget --quiet "https://api.github.com/repos/${ASSETS_REPOSITORY}/releases" -O gh_latest.json
|
wget --quiet "https://api.github.com/repos/${ASSETS_REPOSITORY}/releases" -O gh_latest.json
|
||||||
GH_VERSION=$(jq -r 'sort_by(.tag_name)|last.tag_name' gh_latest.json)
|
GH_VERSION=$( jq -r 'sort_by(.tag_name)|last.tag_name' gh_latest.json )
|
||||||
echo "GH version: ${GH_VERSION}"
|
echo "GH version: ${GH_VERSION}"
|
||||||
|
|
||||||
rm -f gh_latest.json
|
rm -f gh_latest.json
|
||||||
@ -27,7 +27,7 @@ else
|
|||||||
export SHOULD_DEPLOY="yes"
|
export SHOULD_DEPLOY="yes"
|
||||||
|
|
||||||
snap version
|
snap version
|
||||||
snap info "${SNAP_NAME}" | true
|
snap info "${SNAP_NAME}" || true
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [[ "${GITHUB_ENV}" ]]; then
|
if [[ "${GITHUB_ENV}" ]]; then
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
#!/bin/bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
@ -120,7 +120,7 @@ cd "${REPOSITORY_NAME}" || { echo "'${REPOSITORY_NAME}' dir not found"; exit 1;
|
|||||||
git config user.email "$( echo "${GITHUB_USERNAME}" | awk '{print tolower($0)}' )-ci@not-real.com"
|
git config user.email "$( echo "${GITHUB_USERNAME}" | awk '{print tolower($0)}' )-ci@not-real.com"
|
||||||
git config user.name "${GITHUB_USERNAME} CI"
|
git config user.name "${GITHUB_USERNAME} CI"
|
||||||
git remote rm origin
|
git remote rm origin
|
||||||
git remote add origin "https://${GITHUB_USERNAME}:${GITHUB_TOKEN}@github.com/${VERSIONS_REPOSITORY}.git" > /dev/null 2>&1
|
git remote add origin "https://${GITHUB_USERNAME}:${GITHUB_TOKEN}@github.com/${VERSIONS_REPOSITORY}.git" &> /dev/null
|
||||||
cd ..
|
cd ..
|
||||||
|
|
||||||
if [[ "${OS_NAME}" == "osx" ]]; then
|
if [[ "${OS_NAME}" == "osx" ]]; then
|
||||||
|
4
utils.sh
4
utils.sh
@ -2,10 +2,10 @@
|
|||||||
|
|
||||||
# All common functions can be added to this file
|
# All common functions can be added to this file
|
||||||
|
|
||||||
exists() { type -t "$1" > /dev/null 2>&1; }
|
exists() { type -t "$1" &> /dev/null; }
|
||||||
|
|
||||||
is_gnu_sed () {
|
is_gnu_sed () {
|
||||||
sed --version >/dev/null 2>&1
|
sed --version &> /dev/null
|
||||||
}
|
}
|
||||||
|
|
||||||
replace () {
|
replace () {
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
if [[ -z "${BUILD_SOURCEVERSION}" ]]; then
|
if [[ -z "${BUILD_SOURCEVERSION}" ]]; then
|
||||||
|
|
||||||
if type -t "sha1sum" > /dev/null 2>&1; then
|
if type -t "sha1sum" &> /dev/null; then
|
||||||
BUILD_SOURCEVERSION=$( echo "${RELEASE_VERSION/-*/}" | sha1sum | cut -d' ' -f1 )
|
BUILD_SOURCEVERSION=$( echo "${RELEASE_VERSION/-*/}" | sha1sum | cut -d' ' -f1 )
|
||||||
else
|
else
|
||||||
npm install -g checksum
|
npm install -g checksum
|
||||||
|
Loading…
Reference in New Issue
Block a user