From 557c657b3471794b6597ef09d5acb12fc3e704cd Mon Sep 17 00:00:00 2001 From: "Ralf S. Engelschall" Date: Sun, 26 Feb 2017 12:06:59 +0100 Subject: [PATCH] switch from Monotone to Git as the VCS for OpenPKG package repository --- .openpkg/openpkg-dev-release | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.openpkg/openpkg-dev-release b/.openpkg/openpkg-dev-release index 85b623bad5..3845f58c75 100755 --- a/.openpkg/openpkg-dev-release +++ b/.openpkg/openpkg-dev-release @@ -41,11 +41,11 @@ if ($info->{"package-name"} eq "") { } # commit changeset to Monotone repository -my $stat = `mtn stat . 2>/dev/null`; -if ($stat !~ m/\s+no\s+changes/s) { +my $stat = `git stat . 2>/dev/null`; +if ($stat !~ m/nothing\s+to\s+commit,\s+working\s+tree\s+clean/s) { print STDOUT "\033[31m++ committing changeset to OpenPKG VCS repository\033[0m\n"; - if ($info->{"vcs"} ne "mtn") { - print STDERR "openpkg-dev-release: ERROR: Ops, not Montone VCS?!\n"; + if ($info->{"vcs"} ne "git") { + print STDERR "openpkg-dev-release: ERROR: Ops, not Git VCS?!\n"; exit(1); } if (! -f $info->{"spec-dir"} . "/" . $info->{"package-name"} . ".spec") { @@ -55,7 +55,7 @@ if ($stat !~ m/\s+no\s+changes/s) { print STDOUT "-- local: " . $info->{"spec-dir"} . "\n"; my $cmd = "cd " . $info->{"spec-dir"} . " && "; $info->{"commit-message"} =~ s/'/\\'/sg; - $cmd .= "mtn commit -m '" . $info->{"commit-message"} . "' ."; + $cmd .= "git commit -m '" . $info->{"commit-message"} . "' ."; print STDOUT "\$ $cmd\n"; my $rc; for (my $i = 0; $i < 10; $i++) { @@ -97,7 +97,7 @@ if (`uname -s` =~ m/^FreeBSD\n?$/s) { foreach my $job ($jobs =~ m/\s+(\d+)[^ \t]*$/mg) { system("at -r $job >/dev/null 2>&1 || true"); } - system("echo 'mtn --quiet sync >/dev/null 2>&1' | at -qZ '+ 15 minutes'"); + system("echo 'git push --quiet >/dev/null 2>&1' | at -qZ '+ 15 minutes'"); } # final hint