Speed up nightly build generation

New files in the repository are naively added using `svn add --force`
which adds all unversioned files according to the documentation.

However, this iterates through the entire repository and takes about 12
minutes. Using `svn status` and parsing through the results only takes a
couple seconds.
This commit is contained in:
Itms 2025-04-29 16:26:27 +02:00
parent b58ea2698e
commit 2659efdb38
No known key found for this signature in database
GPG key ID: C7E52BD14CE14E09

View file

@ -165,7 +165,7 @@ pipeline {
stage("Commit") {
steps {
ws("workspace/nightly-svn") {
bat "svn add --force ."
bat "(for /F \"tokens=* delims=? \" %%A in ('svn status ^| findstr /R \"^?\"') do (svn add "%%A")) || (echo No new files found) ^& exit 0"
bat "(for /F \"tokens=* delims=! \" %%A in ('svn status ^| findstr /R \"^!\"') do (svn delete "%%A")) || (echo No deleted files found) ^& exit 0"
bat "for /R %%F in (*.sh) do (svn propset svn:executable ON %%F)"
withCredentials([usernamePassword(credentialsId: 'nightly-autobuild', passwordVariable: 'SVNPASS', usernameVariable: 'SVNUSER')]) {