Skip to content

Commit

Permalink
fix: remove yaml comment at first
Browse files Browse the repository at this point in the history
Signed-off-by: Joseph Mory <[email protected]>
  • Loading branch information
morytyann committed Feb 26, 2025
1 parent 1dd1fac commit 5e48c11
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions nikki/files/nikki.init
Original file line number Diff line number Diff line change
Expand Up @@ -102,11 +102,10 @@ start_service() {
log "Mixin" "Mixin all config."
fi
if [ "$mixin_file_content" == 0 ]; then
ucode -S "$MIXIN_UC" | yq -M -p json -o yaml | yq -M -i ea '. as $item ireduce ({}; . * $item ) | .rules = .nikki-rules + .rules | del(.nikki-rules)' "$RUN_PROFILE_PATH" -
ucode -S "$MIXIN_UC" | yq -M -p json -o yaml | yq -M -i ea '... comments="" | . as $item ireduce ({}; . * $item ) | .rules = .nikki-rules + .rules | del(.nikki-rules)' "$RUN_PROFILE_PATH" -
elif [ "$mixin_file_content" == 1 ]; then
ucode -S "$MIXIN_UC" | yq -M -p json -o yaml | yq -M -i ea '. as $item ireduce ({}; . * $item ) | .rules = .nikki-rules + .rules | del(.nikki-rules)' "$RUN_PROFILE_PATH" "$MIXIN_FILE_PATH" -
ucode -S "$MIXIN_UC" | yq -M -p json -o yaml | yq -M -i ea '... comments="" | . as $item ireduce ({}; . * $item ) | .rules = .nikki-rules + .rules | del(.nikki-rules)' "$RUN_PROFILE_PATH" "$MIXIN_FILE_PATH" -
fi
yq -M -i '... comments=""' "$RUN_PROFILE_PATH"
# test profile
if [ "$test_profile" == 1 ]; then
log "Profile" "Testing..."
Expand Down

0 comments on commit 5e48c11

Please sign in to comment.