Skip to content

Conversation

@yadij
Copy link
Contributor

@yadij yadij commented Sep 25, 2025

... broken since release process moved to github releases.

... broken since release process moved to github releases.
@yadij yadij added the S-waiting-for-PR Closure of other PR(s), current or future, is expected (and usually required) label Sep 25, 2025
@yadij
Copy link
Contributor Author

yadij commented Sep 25, 2025

Requires squid-cache/squid#2257 to have been merged to both v7 and v8 for this to work.

Comment on lines +21 to +23
git checkout v$version &&
./bootstrap.sh && ./configure && make -C ./doc cfgman &&
mv -f -t $SQUID_WWW_PATH/content/Versions/$version/cfgman ./doc/cfgman/*
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAICT, this particular command sequence ignores failures and lets the current iteration proceed to the "update DYN documents" step that, AFAICT, depends on the failed command. If we do not want to abort the script on failures, should not we proceed to the next iteration instead?

gitCleanWorkspace ()
{
git clean --quiet -xdf --exclude="\.BASE"
git checkout --quiet -- .
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A checkout command does not belong to a "clean workspace" function. The command itself looks a bit odd.

If you want to erase changes to tracked files, then use something like git reset --hard. If tracked files may remain as is, then remove this command (from this function). Let the caller checkout what they need (one caller already does, resulting in two sequential checkouts).

# Update the website /Versions/v*/cfgman/ HTML documents
cd $SQUID_VCS_PATH/squid-$version || continue
gitCleanWorkspace
git checkout v$version &&
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this script relies on something else fetching changes from the remote repository, I recommend adding a comment about it. Otherwise, it needs to do something like "git fetch".

gitCleanWorkspace

# Update the website /Doc/config/ DYN documents
! test -d $SQUID_WWW_PATH/content/Versions/$version/cfgman && continue
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is strange to check whether this directory is present when the above commands rely on its presence to store their result. Should not this test be moved higher, where it used to reside before this PR?

mv -f -t $SQUID_WWW_PATH/content/Versions/$version/cfgman ./doc/cfgman/*
gitCleanWorkspace

# Update the website /Doc/config/ DYN documents
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this update use some make-generated files? If yes, we should not clean the working directory before this update (and we should not update if make fails). If not, I recommend rephrasing this comment to clarify where the new information is coming from, to remove the current implication that this information is the result of the above make.

Comment on lines -9 to -11
# Known Bug:
# Does not remove references to directives dropped. This is
# an issue for branch 'master' directive erasure.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is not this bug still present? AFAICT, the DYN part of the loop iterates previously published *.html directive files and does not erase any stale ones.

@rousskov rousskov added the S-waiting-for-author author action is expected (and usually required) label Sep 25, 2025
squid-anubis pushed a commit that referenced this pull request Oct 5, 2025
... broken since release process moved to github releases.
@squid-anubis squid-anubis added the M-waiting-staging-checks https://github.com/measurement-factory/anubis#pull-request-labels label Oct 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

M-waiting-staging-checks https://github.com/measurement-factory/anubis#pull-request-labels S-waiting-for-author author action is expected (and usually required) S-waiting-for-PR Closure of other PR(s), current or future, is expected (and usually required)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants