This is an automated email from the ASF dual-hosted git repository.
kou pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow.git
The following commit(s) were added to refs/heads/main by this push:
new f6127a6d18 GH-41356: [Release][Docs] Update post release documentation
task to remove the warnings banner for stable version (#41377)
f6127a6d18 is described below
commit f6127a6d18af12ce18a0b8b1eac02346721cc399
Author: Alenka Frim <[email protected]>
AuthorDate: Thu May 9 04:58:59 2024 +0200
GH-41356: [Release][Docs] Update post release documentation task to remove
the warnings banner for stable version (#41377)
### Rationale for this change
With every release dev documentation is moved to `docs/` and becomes stable
version of the documentation but the version warnings banner is still present.
### What changes are included in this PR?
This PR removes the banner before the dev docs are copied to the `docs/`
folder.
### Are these changes tested?
Not yet.
### Are there any user-facing changes?
No.
* GitHub Issue: #41356
Lead-authored-by: AlenkaF <[email protected]>
Co-authored-by: Alenka Frim <[email protected]>
Co-authored-by: Raúl Cumplido <[email protected]>
Signed-off-by: Sutou Kouhei <[email protected]>
---
dev/release/post-08-docs.sh | 17 ++++++++++++++++-
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/dev/release/post-08-docs.sh b/dev/release/post-08-docs.sh
index c59f9b9685..58a462551f 100755
--- a/dev/release/post-08-docs.sh
+++ b/dev/release/post-08-docs.sh
@@ -72,13 +72,28 @@ fi
# delete current stable docs and restore all previous versioned docs
rm -rf docs/*
git checkout "${versioned_paths[@]}"
+# Download and untar released docs in a temp folder
+rm -rf docs_new
+mkdir docs_new
+pushd docs_new
curl \
--fail \
--location \
--remote-name \
https://apache.jfrog.io/artifactory/arrow/docs/${version}/docs.tar.gz
tar xvf docs.tar.gz
-rm -f docs.tar.gz
+# Update DOCUMENTATION_OPTIONS.show_version_warning_banner
+find docs \
+ -type f \
+ -exec \
+ sed -i.bak \
+ -e "s/DOCUMENTATION_OPTIONS.show_version_warning_banner =
true/DOCUMENTATION_OPTIONS.show_version_warning_banner = false/g" \
+ {} \;
+find ./ -name '*.bak' -delete
+popd
+mv docs_new/docs/* docs/
+rm -rf docs_new
+
if [ "$is_major_release" = "yes" ] ; then
previous_series=${previous_version%.*}
mv docs_temp docs/${previous_series}