Skip to content

Commit 7f549d5

Browse files
chore(release): 0.0.16 bug fixes
1 parent 0d536eb commit 7f549d5

File tree

4 files changed

+36
-36
lines changed

4 files changed

+36
-36
lines changed

dist/codecov.sh

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/usr/bin/env bash
2-
CC_WRAPPER_VERSION="0.0.15"
2+
CC_WRAPPER_VERSION="0.0.16"
33
say() {
44
echo -e "$1"
55
}
@@ -12,18 +12,18 @@ exit_if_error() {
1212
fi
1313
}
1414
lower() {
15-
echo $(echo $1 | sed 's/CC//' | sed 's/_/-//' | tr '[:upper:]' '[:lower:]')
15+
echo $(echo $1 | sed 's/CC//' | sed 's/_/-/g' | tr '[:upper:]' '[:lower:]')
1616
}
1717
write_existing_args() {
18-
if [ -n "$1" ];
18+
if [ -n "$(eval echo \$$1)" ];
1919
then
20-
echo " --$(lower $1) $(eval echo \$$1)"
20+
echo " -$(lower "$1") $(eval echo \$$1)"
2121
fi
2222
}
2323
write_truthy_args() {
24-
if [ "$1" = "true" ];
24+
if [ "$(eval echo \$$1)" = "true" ];
2525
then
26-
echo " --$(lower $1)"
26+
echo " -$(lower $1)"
2727
fi
2828
}
2929
b="\033[0;36m" # variables/constants
@@ -189,34 +189,34 @@ then
189189
token_arg+=( " -t " "$token")
190190
fi
191191
say "$g==>$x Running create-commit"
192-
say " $b./$cc_filename$cc_cli_args create-commit$token_str$cc_cc_args$x"
192+
say " $b./$cc_filename $(echo "${cc_cli_args[@]}") create-commit$token_str $(echo "${cc_cc_args[@]}")$x"
193193
if ! ./$cc_filename \
194-
${cc_cli_args[@]} \
194+
${cc_cli_args[*]} \
195195
create-commit \
196-
${token_arg[@]} \
197-
${cc_cc_args[@]};
196+
${token_arg[*]} \
197+
${cc_cc_args[*]};
198198
then
199199
exit_if_error "Failed to create-commit"
200200
fi
201201
say " "
202202
say "$g==>$x Running create-report"
203-
say " $b./$cc_filename$cc_cli_args create-commit$token_str$cc_cr_args$x"
203+
say " $b./$cc_filename $(echo "${cc_cli_args[@]}") create-report$token_str $(echo "${cc_cr_args[@]}")$x"
204204
if ! ./$cc_filename \
205-
${cc_cli_args[@]} \
205+
${cc_cli_args[*]} \
206206
create-report \
207-
${token_arg[@]} \
208-
${cc_cr_args[@]};
207+
${token_arg[*]} \
208+
${cc_cr_args[*]};
209209
then
210210
exit_if_error "Failed to create-report"
211211
fi
212212
say " "
213213
say "$g==>$x Running do-upload"
214-
say " $b./$cc_filename$cc_cli_args do-upload$token_str$cc_du_args$x"
214+
say " $b./$cc_filename $(echo "${cc_cli_args[@]}") do-upload$token_str $(echo "${cc_du_args[@]}")$x"
215215
if ! ./$cc_filename \
216-
${cc_cli_args[@]} \
216+
${cc_cli_args[*]} \
217217
do-upload \
218-
${token_arg[@]} \
219-
${cc_du_args[@]};
218+
${token_arg[*]} \
219+
${cc_du_args[*]};
220220
then
221221
exit_if_error "Failed to upload"
222222
fi

scripts/set_defaults.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,20 +14,20 @@ exit_if_error() {
1414
}
1515

1616
lower() {
17-
echo $(echo $1 | sed 's/CODECOV//' | sed 's/_/-//' | tr '[:upper:]' '[:lower:]')
17+
echo $(echo $1 | sed 's/CODECOV//' | sed 's/_/-/g' | tr '[:upper:]' '[:lower:]')
1818
}
1919

2020
write_existing_args() {
21-
if [ -n "$1" ];
21+
if [ -n "$(eval echo \$$1)" ];
2222
then
23-
echo " --$(lower $1) $(eval echo \$$1)"
23+
echo " -$(lower "$1") $(eval echo \$$1)"
2424
fi
2525
}
2626

2727
write_truthy_args() {
28-
if [ "$1" = "true" ];
28+
if [ "$(eval echo \$$1)" = "true" ];
2929
then
30-
echo " --$(lower $1)"
30+
echo " -$(lower $1)"
3131
fi
3232
}
3333

scripts/upload.sh

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -22,36 +22,36 @@ then
2222
fi
2323

2424
say "$g==>$x Running create-commit"
25-
say " $b./$codecov_filename$codecov_cli_args create-commit$token_str$codecov_cc_args$x"
25+
say " $b./$codecov_filename $(echo "${codecov_cli_args[@]}") create-commit$token_str $(echo "${codecov_cc_args[@]}")$x"
2626
if ! ./$codecov_filename \
27-
${codecov_cli_args[@]} \
27+
${codecov_cli_args[*]} \
2828
create-commit \
29-
${token_arg[@]} \
30-
${codecov_cc_args[@]};
29+
${token_arg[*]} \
30+
${codecov_cc_args[*]};
3131
then
3232
exit_if_error "Failed to create-commit"
3333
fi
3434
say " "
3535

3636
say "$g==>$x Running create-report"
37-
say " $b./$codecov_filename$codecov_cli_args create-commit$token_str$codecov_cr_args$x"
37+
say " $b./$codecov_filename $(echo "${codecov_cli_args[@]}") create-report$token_str $(echo "${codecov_cr_args[@]}")$x"
3838
if ! ./$codecov_filename \
39-
${codecov_cli_args[@]} \
39+
${codecov_cli_args[*]} \
4040
create-report \
41-
${token_arg[@]} \
42-
${codecov_cr_args[@]};
41+
${token_arg[*]} \
42+
${codecov_cr_args[*]};
4343
then
4444
exit_if_error "Failed to create-report"
4545
fi
4646
say " "
4747

4848
say "$g==>$x Running do-upload"
49-
say " $b./$codecov_filename$codecov_cli_args do-upload$token_str$codecov_du_args$x"
49+
say " $b./$codecov_filename $(echo "${codecov_cli_args[@]}") do-upload$token_str $(echo "${codecov_du_args[@]}")$x"
5050
if ! ./$codecov_filename \
51-
${codecov_cli_args[@]} \
51+
${codecov_cli_args[*]} \
5252
do-upload \
53-
${token_arg[@]} \
54-
${codecov_du_args[@]};
53+
${token_arg[*]} \
54+
${codecov_du_args[*]};
5555
then
5656
exit_if_error "Failed to upload"
5757
fi

scripts/version.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/usr/bin/env bash
2-
CODECOV_WRAPPER_VERSION="0.0.15"
2+
CODECOV_WRAPPER_VERSION="0.0.16"

0 commit comments

Comments
 (0)