File tree Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Expand file tree Collapse file tree 3 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ set -euo pipefail
8
8
source ./bin/generator-utils/utils.sh
9
9
10
10
digest_template () {
11
+ local template
11
12
template=$( cat bin/test_template)
12
13
# Turn every token into a jq command
13
14
echo " $template " | sed ' s/${\([^}]*\)\}\$/$(echo $case | jq -r ' \' ' .\1' \' ' )/g'
Original file line number Diff line number Diff line change 78
78
79
79
}
80
80
81
- function create_lib_rs_template() {
81
+ create_lib_rs_template () {
82
82
local exercise_dir=$1
83
83
local slug=$2
84
84
local has_canonical_data=$3
92
92
message " success" " Stub file for lib.rs has been created!"
93
93
}
94
94
95
- function overwrite_gitignore() {
95
+ overwrite_gitignore () {
96
96
local exercise_dir=$1
97
97
cat << EOT >"$exercise_dir "/.gitignore
98
98
# Generated by Cargo
107
107
message " success" " .gitignore has been overwritten!"
108
108
}
109
109
110
- function create_example_rs_template() {
110
+ create_example_rs_template () {
111
111
local exercise_dir=$1
112
112
local slug=$2
113
113
local has_canonical_data=$3
126
126
message " success" " Stub file for example.rs has been created!"
127
127
}
128
128
129
- function create_rust_files() {
129
+ create_rust_files () {
130
130
local exercise_dir=$1
131
131
local slug=$2
132
132
local has_canonical_data=$3
Original file line number Diff line number Diff line change 3
3
# shellcheck source=./colors.sh
4
4
source ./bin/generator-utils/colors.sh
5
5
6
- function message() {
6
+ message () {
7
7
local flag=$1
8
8
local message=$2
9
9
You can’t perform that action at this time.
0 commit comments