Skip to content

Commit a300f72

Browse files
authored
Merge pull request #148 from DannyBen/add/set-u-support
Make generated scripts compatible with bash strict mode
2 parents aecc68e + 783bcfd commit a300f72

File tree

31 files changed

+139
-131
lines changed

31 files changed

+139
-131
lines changed
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.

examples/catch-all/src/initialize.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.

examples/commands/src/initialize.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.

examples/config-ini/src/lib/config.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ config_init() {
2222
config_get() {
2323
key=$1
2424
regex="^$key\s*=\s*(.+)$"
25+
value=''
2526

2627
config_init
2728

@@ -122,5 +123,5 @@ config_keys() {
122123
# fi
123124
#
124125
config_has_key() {
125-
[[ $(config_get "$1") ]]
126+
[[ $(config_get "${1:-}") ]]
126127
}
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.
Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
# Code here runs inside the initialize() function
2-
# Use it for anything that you need to run before any other function, like
3-
# setting environment vairables:
4-
# CONFIG_FILE=settings.ini
5-
#
6-
# Feel free to empty (but not delete) this file.
1+
## Code here runs inside the initialize() function
2+
## Use it for anything that you need to run before any other function, like
3+
## setting environment vairables:
4+
## CONFIG_FILE=settings.ini
5+
##
6+
## Feel free to empty (but not delete) this file.

0 commit comments

Comments
 (0)