Skip to content

Commit

Permalink
remove output conversions
Browse files Browse the repository at this point in the history
  • Loading branch information
mongolyy committed Sep 8, 2024
1 parent c6b8715 commit 190d0aa
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions lib/biome.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,11 @@ biome_check() {
biome_version=$(biome --version)
if awk -v ver="$biome_version" 'BEGIN { if (ver >= 1.8) exit 1; }'; then
# The following processes will be removed when biome 2.0.0 is released
# shellcheck disable=SC2086
biome check --apply $1 2>&1 1>/dev/null |
sed 's/ *$//' |
awk 'BEGIN { RS=""; ORS="\n\n" } { if (index($0, "│") > 0) { print " ```\n" $0 "\n ```" } else { print $0 } }'
# shellcheck disable=SC2069,SC2086
biome check --apply $1 2>&1 1>/dev/null
else
# shellcheck disable=SC2086
biome check --write $1 2>&1 1>/dev/null |
sed 's/ *$//' |
awk 'BEGIN { RS=""; ORS="\n\n" } { if (index($0, "│") > 0) { print " ```\n" $0 "\n ```" } else { print $0 } }'
# shellcheck disable=SC2069,SC2086
biome check --write $1 2>&1 1>/dev/null
fi
}

Expand Down

0 comments on commit 190d0aa

Please sign in to comment.