Pier Angelo Vendrame pushed to branch main at The Tor Project / Applications / tor-browser-build Commits: 0faf0e24 by Pier Angelo Vendrame at 2026-02-04T11:57:11+01:00 Bug 40338: Use cp -al instead of mv in projects/release. Currently, we use mv in projects/release/build. However, since we also use hard links, re-running the release project might fail (because we end up trying to mv the same inode). Rather than checking stat, we can just use `cp -al`, which simplifies also the current mechanism we have to handle subdirectories. RBM will take care of deleting the temporary directory where the script runs, so we do not even need to remove the files after the copy. - - - - - 1 changed file: - projects/release/build Changes: ===================================== projects/release/build ===================================== @@ -5,59 +5,47 @@ destdir="[% dest_dir _ '/' _ c("var/publish_dir") %]" mkdir -p "$destdir" -function mv_files { - inputfile="$1" - if test -d "$inputfile"/artifacts - then - mkdir -p "$destdir"/artifacts - mv "$inputfile"/artifacts/* "$destdir"/artifacts - rmdir "$inputfile"/artifacts - fi - mv "$inputfile"/* "$destdir"/ -} - [% IF c("var/browser_platforms/android-armv7") -%] - mv_files "[% c('input_files_by_name/android-armv7') %]" + cp -alf "[% c('input_files_by_name/android-armv7') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/android-x86_64") -%] - mv_files "[% c('input_files_by_name/android-x86_64') %]" + cp -alf "[% c('input_files_by_name/android-x86_64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/android-aarch64") -%] - mv_files "[% c('input_files_by_name/android-aarch64') %]" + cp -alf "[% c('input_files_by_name/android-aarch64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/windows-i686") -%] - mv_files "[% c('input_files_by_name/windows-i686') %]" + cp -alf "[% c('input_files_by_name/windows-i686') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/windows-x86_64") -%] - mv_files "[% c('input_files_by_name/windows-x86_64') %]" + cp -alf "[% c('input_files_by_name/windows-x86_64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/macos") -%] - mv_files "[% c('input_files_by_name/macos') %]" + cp -alf "[% c('input_files_by_name/macos') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/macos-x86_64") -%] - mv_files "[% c('input_files_by_name/macos-x86_64') %]" + cp -alf "[% c('input_files_by_name/macos-x86_64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/macos-aarch64") -%] - mv_files "[% c('input_files_by_name/macos-aarch64') %]" + cp -alf "[% c('input_files_by_name/macos-aarch64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/linux-x86_64") -%] - mv_files "[% c('input_files_by_name/linux-x86_64') %]" + cp -alf "[% c('input_files_by_name/linux-x86_64') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser_platforms/linux-aarch64") -%] - mv_files "[% c('input_files_by_name/linux-aarch64') %]" + cp -alf "[% c('input_files_by_name/linux-aarch64') %]"/* "$destdir"/ [% END -%] [% IF c("var/linux-packages") || c("var/linux-packages-aarch64") -%] [% IF c("var/linux-packages") -%] - mv_files "[% c('input_files_by_name/deb-packages') %]" + cp -alf "[% c('input_files_by_name/deb-packages') %]"/* "$destdir"/ [% END -%] [% IF c("var/linux-packages-aarch64") -%] - mv_files "[% c('input_files_by_name/deb-packages-aarch64') %]" + cp -alf "[% c('input_files_by_name/deb-packages-aarch64') %]"/* "$destdir"/ [% END -%] - mv_files "[% c('input_files_by_name/rpm-packages') %]" + cp -alf "[% c('input_files_by_name/rpm-packages') %]"/* "$destdir"/ [% END -%] [% IF c("var/browser-src") -%] - mv [% c('input_files_by_name/src-firefox') %] \ - "$destdir"/ + cp -alf "[% c('input_files_by_name/src-firefox') %]" "$destdir"/ [% END -%] cd "$destdir" cat > .htaccess <<'EOF' View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/0f... -- View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/0f... You're receiving this email because of your account on gitlab.torproject.org.
participants (1)
-
Pier Angelo Vendrame (@pierov)