Skip to content

Commit

Permalink
modify comments to clarify meaning of "broken" and "updated"
Browse files Browse the repository at this point in the history
  • Loading branch information
xiota committed Nov 2, 2023
1 parent 579466f commit bf84d5d
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/lib/interfere.sh
Original file line number Diff line number Diff line change
Expand Up @@ -165,14 +165,14 @@ function interference-bump() {
| sort -u
)"

# collect packages that have not been rebuilt
# collect packages with mismatched pkgver, pkgrel, or bump
_BUMPS_TMP=$(
comm -13 \
<(sort -u <<<"${_PACKAGES}" || true) \
<(sort -u <<<"${_BUMPS}" || true)
)

# collect existing versions of packages
# combine with repo package listing
_BUMPS_TMP+=$(
echo
while read -r _LINE; do
Expand All @@ -187,14 +187,16 @@ function interference-bump() {
)

# remove broken packages; keep updated packages
# "broken" packages have same pkgver and pkgrel, but different bump
# "updated" packages have different pkgver or different pkgrel.
_BUMPS_UPD=$(
sed -Ez \
-e 's&\n(\S+ \S+) \S+\n\1 \S+\n&\n\n&g' \
-e 's&\n(\S+ \S+) \S+\n\1 \S+\n&\n\n&g' \
<<<"${_BUMPS_BRK}" | sort -u || true
)

# collect broken packages only
# broken packages only; for later review
_BUMPS_BRK=$(
comm -23 \
<(sort -u <<<"${_BUMPS_BRK}" || true) \
Expand Down Expand Up @@ -227,10 +229,10 @@ function interference-bump() {
fi
done

# show broken packages without version info
# display broken packages for review
echo "${_BUMPS_BRK}" | sed -E 's& .*$&&' | sort -u

# save bumps file
# update bump file
sort -u <<<"${_BUMPS}" >"${_BUMPSFILE}"

interfere-push-bumps || interfere-sync
Expand Down

0 comments on commit bf84d5d

Please sign in to comment.