Skip to content

Commit

Permalink
Improved comment line check
Browse files Browse the repository at this point in the history
  • Loading branch information
colincasey committed Mar 28, 2024
1 parent 8ecc138 commit c725e16
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion bin/compile
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ while IFS= read -r PACKAGE; do
IFS=$' \t' read -ra PACKAGE_NAMES <<< "$PACKAGE"
apt-get "${APT_OPTIONS[@]}" -y "${APT_FORCE_YES[@]}" -d install --reinstall "${PACKAGE_NAMES[@]}" | indent
fi
done < <(grep --invert-match -e "^#" -e "^\s*$" -e "^:repo:" "${BUILD_DIR}/Aptfile")
done < <(grep --invert-match -e "^\s*#" -e "^\s*$" -e "^:repo:" "${BUILD_DIR}/Aptfile")

mkdir -p "$BUILD_DIR/.apt"

Expand Down
2 changes: 1 addition & 1 deletion bin/report
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ while IFS= read -r line; do
packages+=("${package_name}")
done
fi
done < <(grep --invert-match -e "^#" -e "^\s*$" "${BUILD_DIR}/Aptfile")
done < <(grep --invert-match -e "^\s*#" -e "^\s*$" "${BUILD_DIR}/Aptfile")

output_key_value() {
local key value
Expand Down
2 changes: 2 additions & 0 deletions test/fixtures/package-names/Aptfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,5 @@ mysql-client-*

# multiple packages on single line
s3cmd wget

# comment with bad indent

0 comments on commit c725e16

Please sign in to comment.