Skip to content

Commit a510548

Browse files
committed
Add script
1 parent 88de5e6 commit a510548

File tree

2 files changed

+20
-2
lines changed

2 files changed

+20
-2
lines changed

.github/renovate.json5

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
},
1919
],
2020
postUpgradeTasks: {
21-
commands: [ ],
22-
fileFilters: [ '**', ],
21+
commands: ['bash .github/renovate/create_ec2_install_checksum.sh'],
22+
fileFilters: [ 'AWS/EC2/ec2-install.sh', ],
2323
executionMode: 'branch',
2424
},
2525
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
#!/bin/bash
2+
# Create sha256 checksum for the installation script
3+
4+
set -Eeuo pipefail
5+
6+
setup_colors() {
7+
if [[ -t 2 ]] && [[ -z "${NO_COLOR-}" ]] && [[ "${TERM-}" != "dumb" ]]; then
8+
NOFORMAT='\033[0m' RED='\033[0;31m' GREEN='\033[0;32m' ORANGE='\033[0;33m' BLUE='\033[0;34m' PURPLE='\033[0;35m' CYAN='\033[0;36m' YELLOW='\033[1;33m'
9+
else
10+
NOFORMAT='' RED='' GREEN='' ORANGE='' BLUE='' PURPLE='' CYAN='' YELLOW=''
11+
fi
12+
}
13+
14+
setup_colors
15+
16+
# Script logic
17+
msg "${YELLOW}Creating checksum${NOFORMAT}"
18+
sha256sum ec2-install.sh > ec2-install.sh.sha256

0 commit comments

Comments
 (0)