refactored sed calls to not use -i
This commit is contained in:
parent
4d06f57758
commit
f0038dd7c7
@ -120,5 +120,6 @@ if [ -f "$LOG_FILE" ]; then
|
||||
-e 's/\[[0-9]m//g' \
|
||||
-e 's/ H //g' \
|
||||
-e 's/\[3gH //g' \
|
||||
-i "$LOG_FILE"
|
||||
"$LOG_FILE" > "$LOG_FILE.clean"
|
||||
mv "$LOG_FILE.clean" "$LOG_FILE"
|
||||
fi
|
||||
|
||||
@ -91,10 +91,11 @@ do
|
||||
fi
|
||||
if ask_yn "create default cbuild project config?"; then
|
||||
project_config_path="$new_project_dir/project.config"
|
||||
cp "$CBUILD_INSTALL_DIR/default.config" "$project_config_path"
|
||||
cp "$CBUILD_INSTALL_DIR/default.config" "$project_config_path.temp"
|
||||
myprint "Enter project name: "
|
||||
read -r project_name
|
||||
sed -i "s,\%PROJECT_NAME\%,$project_name,g" "$project_config_path"
|
||||
sed "s,\%PROJECT_NAME\%,$project_name,g" "$project_config_path.temp" > "$project_config_path"
|
||||
rm "$project_config_path.temp"
|
||||
myprint "${GREEN}created config at '$project_config_path'"
|
||||
fi
|
||||
if ask_yn "Copy default .gitignore?"; then
|
||||
|
||||
Loading…
Reference in New Issue
Block a user