This repository has been archived by the owner on May 11, 2023. It is now read-only.
forked from bigluster/Dashboard-Link-Generator
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Cleaned and aligned to other extensions in EB
- Loading branch information
Albert Backenhof
authored and
Albert Backenhof
committed
Feb 21, 2019
1 parent
3d1d0e6
commit 6fbae14
Showing
22 changed files
with
1,579 additions
and
4,134 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#!/bin/bash | ||
set -o errexit | ||
|
||
echo "Creating release for version: $PACKAGE_VERSION" | ||
echo "Artifact name: ./dist/${3}_${PACKAGE_VERSION}.zip" | ||
|
||
echo "1: ${1}" | ||
echo "2: ${2}" | ||
echo "3: ${3}" | ||
echo "4: ${4}" | ||
|
||
LATEST_VERSION=$(curl --silent "https://api.github.com/repos/$1/$2/releases/latest" | | ||
grep '"tag_name":' | | ||
sed -E 's/.*"([^"]+)".*/\1/') | ||
|
||
echo "LATEST_VERSION: ${LATEST_VERSION}" | ||
|
||
if [ "${LATEST_VERSION}" != "${PACKAGE_VERSION}" ]; then | ||
|
||
$HOME/bin/ghr -t ${ghoauth} -u ${1} -r ${2} -c ${CIRCLE_SHA1} -delete ${PACKAGE_VERSION} "./dist/${3}_${4}.zip" | ||
|
||
else | ||
|
||
echo "VERSION: ${PACKAGE_VERSION} already released" | ||
|
||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
#!/bin/bash | ||
set -o errexit | ||
|
||
PACKAGE_VERSION=$(cat package.json \ | ||
| grep version \ | ||
| head -1 \ | ||
| awk -F: '{ print $2 }' \ | ||
| sed 's/[",]//g' \ | ||
| tr -d '[[:space:]]') | ||
|
||
echo $PACKAGE_VERSION |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
#!/bin/bash | ||
# The build script has a known race-condition that sometimes causes it to not include all files | ||
# in the built zip. This script verifies the that the zip contains the correct number of files. | ||
|
||
set -o errexit | ||
|
||
echo "Verifying built file count" | ||
|
||
while read line; do | ||
if [[ $line =~ ^\"name\": ]]; then | ||
name=${line#*: \"} | ||
name=${name%\"*} | ||
elif [[ $line =~ ^\"version\": ]]; then | ||
version=${line#*: \"} | ||
version=${version%\"*} | ||
fi | ||
done < package.json | ||
|
||
expected_file_count=$(($(find dist -type f | wc -l)-1)) | ||
zip_file_count=$(zipinfo dist/${name}_${version}.zip | grep ^- | wc -l) | ||
|
||
if [ "${expected_file_count}" -ne "${zip_file_count}" ]; then | ||
# File count is incorrect | ||
echo "Expected file count ${expected_file_count}, but was ${zip_file_count}" | ||
exit 1 | ||
fi | ||
echo "File count OK" | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.