Back (Current repo: scraps)

random scraps and notes that are useful to me
To clone this repository:
git clone https://git.viktor1993.net/scraps.git
Log | Download | Files | Refs

commit a419558b05c03d5611dfe18816100c2b411c9030
parent b9e8ca8578a0fe591b1ffaebd45216e99ad566e3
Author: root <none>
Date:   Thu, 17 Sep 2026 21:25:21 +0200

minor QoL check

Diffstat:
Mperl/git_consistency_check.pl | 9+++++++++
1 file changed, 9 insertions(+), 0 deletions(-)

diff --git a/perl/git_consistency_check.pl b/perl/git_consistency_check.pl @@ -46,10 +46,19 @@ my %processed; my $stem1 = $git_locations; my $stem2 = $script_locations; +$stem1 =~ s{/+$}{}; +$stem2 =~ s{/+$}{}; my ($git, $git_files) = tempfile('/tmp/gitrepo-git-consistency-check-XXXXXXXXXXXX', SUFFIX => '.tmp', UNLINK => 0); my ($scripts, $scripts_files) = tempfile('/tmp/scripts-git-consistency-check-XXXXXXXXXXXX', SUFFIX => '.tmp', UNLINK => 0); +for my $path ($file_diffs, $file_list, $changed_files) { + open(my $fh, '>', $path) + or die "Cannot truncate $path"; + close($fh) + or die "Cannot close $path"; +} + #recursively search through target directory for all files sub find_files { my $path = $_[0];