mattermost-desktop/scripts/cp_artifacts.sh
aaron 057377207a
Some checks failed
release / begin-notification (push) Has been cancelled
release / build-linux (push) Has been cancelled
release / build-msi-installer (push) Has been cancelled
release / build-mac-installer (push) Has been cancelled
release / upload-to-s3 (push) Has been cancelled
release / github-release (push) Has been cancelled
release / end-notification (push) Has been cancelled
first commit bois
2024-10-03 06:35:14 -07:00

21 lines
424 B
Bash
Executable file

#!/usr/bin/env bash
set -eu
VERSION="$(jq -r '.version' <package.json)"
SRC="${1}"
DEST="${2}"
if [[ ! -d "${DEST}/${VERSION}" ]]; then
echo "Can't find destination. Creating \"${DEST}/${VERSION}\""
mkdir -p "${DEST}/${VERSION}"
fi
if [[ ! -d "${SRC}/${VERSION}" ]]; then
echo "Can't find source directory, exiting."
exit 1
fi
cp -rv "${SRC}/${VERSION}" "${DEST}/"
cp -v "${SRC}"/*.yml "${DEST}/"
exit 0