kszucs commented on a change in pull request #12320:
URL: https://github.com/apache/arrow/pull/12320#discussion_r808154824



##########
File path: dev/release/verify-release-candidate.bat
##########
@@ -20,30 +20,49 @@
 
 @echo on
 
+setlocal ENABLEDELAYEDEXPANSION
+
 if not exist "C:\tmp\" mkdir C:\tmp
 if exist "C:\tmp\arrow-verify-release" rd C:\tmp\arrow-verify-release /s /q
 if not exist "C:\tmp\arrow-verify-release" mkdir C:\tmp\arrow-verify-release
 
 set _VERIFICATION_DIR=C:\tmp\arrow-verify-release
 set _VERIFICATION_DIR_UNIX=C:/tmp/arrow-verify-release
 set _VERIFICATION_CONDA_ENV=%_VERIFICATION_DIR%\conda-env
-set _DIST_URL=https://dist.apache.org/repos/dist/dev/arrow
-set _TARBALL=apache-arrow-%1.tar.gz
-set ARROW_SOURCE=%_VERIFICATION_DIR%\apache-arrow-%1
 set INSTALL_DIR=%_VERIFICATION_DIR%\install
 
-@rem Requires GNU Wget for Windows
-wget --no-check-certificate -O %_TARBALL% 
%_DIST_URL%/apache-arrow-%1-rc%2/%_TARBALL% || exit /B 1
-
-tar xf %_TARBALL% -C %_VERIFICATION_DIR_UNIX%
-
+set VERSION=%1
+set RC_NUMBER=%2
+
+if "%VERSION%"=="" (
+    set ARROW_SOURCE=%~dp0..\..\
+) else (
+    set ARROW_SOURCE=%_VERIFICATION_DIR%\apache-arrow-%1
+    if "%RC_NUMBER%"=="" (
+        @rem verify a specific git revision
+        git clone --recurse-submodules https://github.com/apache/arrow.git 
!ARROW_SOURCE!
+        git -C !ARROW_SOURCE! checkout %VERSION%
+    ) else (
+        @rem verify a release candidate tarball
+        @rem Requires GNU Wget for Windows
+        set TARBALL_NAME=apache-arrow-%VERSION%.tar.gz
+        set 
TARBALL_URL=https://dist.apache.org/repos/dist/dev/arrow/apache-arrow-%VERSION%-rc%RC_NUMBER%/%TARBALL_NAME%
+        wget --no-check-certificate -O %TARBALL_NAME% %TARBALL_URL% || exit /B 
1
+        tar xf %TARBALL_NAME% -C %_VERIFICATION_DIR_UNIX%
+    )
+    git clone https://github.com/apache/arrow-testing.git 
!ARROW_SOURCE!\testing
+    git clone https://github.com/apache/parquet-testing.git 
!ARROW_SOURCE!\cpp\submodules\parquet-testing

Review comment:
       Removed the `--recurse-submodules` from the git case since the 
environment variables are explicitly set below. This way the script remains 
functional even if we choose to change the submodules' path.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to