mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 05:56:15 +02:00
rework the --target flag. If this flag is used, a URI should be given. Default
values are not changed.
This commit is contained in:
parent
a0607be7f4
commit
c0bfcbdd45
1 changed files with 4 additions and 4 deletions
|
@ -31,7 +31,7 @@ my $localCopy;
|
|||
my $localArchivesDir;
|
||||
my $localManifestFile;
|
||||
|
||||
my $targetArchivesDir;
|
||||
my $targetArchivesUrl;
|
||||
|
||||
my $archivesPutURL;
|
||||
my $archivesGetURL;
|
||||
|
@ -45,10 +45,10 @@ if ($ARGV[0] eq "--copy") {
|
|||
$localManifestFile = shift @ARGV;
|
||||
if ($ARGV[0] eq "--target") {
|
||||
shift @ARGV;
|
||||
$targetArchivesDir = shift @ARGV;
|
||||
$targetArchivesUrl = shift @ARGV;
|
||||
}
|
||||
else {
|
||||
$targetArchivesDir = $localArchivesDir;
|
||||
$targetArchivesUrl = "file:/$localArchivesDir";
|
||||
}
|
||||
}
|
||||
else {
|
||||
|
@ -199,7 +199,7 @@ for (my $n = 0; $n < scalar @storePaths; $n++) {
|
|||
|
||||
my $url;
|
||||
if ($localCopy) {
|
||||
$url = "file://$targetArchivesDir/$narName";
|
||||
$url = "$targetArchivesUrl/$narName";
|
||||
} else {
|
||||
$url = "$archivesGetURL/$narName";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue