Diff
Not logged in

Differences From Artifact [05683011d8]:

To Artifact [da9e424f20]:


25
26
27
28
29










30
31
32
33
34
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44





+
+
+
+
+
+
+
+
+
+





  #       parameters used by the package downloader client.  If the force 
  #       argument is non-zero, any existing values will be overwritten and 
  #       set back to their default values. 
  # 
  proc setupDownloadUrnVars { force } { 
    # 
    # NOTE: The URN, relative to the base URI, where the Package Signing Key 
    #       may be downloaded. 
    # 
    variable openPgpKeyUrn; # DEFAULT: pkg_key 
 
    if {$force || ![info exists openPgpKeyUrn]} then { 
      set openPgpKeyUrn pkg_key 
    } 
 
    # 
    # NOTE: The URN, relative to the base URI, where a login request may 
    #       be sent. 
    # 
    variable loginUrn; # DEFAULT: pkgd_login 
81
82
83
84
85










86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110





+
+
+
+
+
+
+
+
+
+





    variable baseUri; # DEFAULT: https://urn.to/r 
 
    if {$force || ![info exists baseUri]} then { 
      set baseUri https://urn.to/r 
    } 
 
    # 
    # NOTE: The URI where the Package Signing Key may be downloaded.  This 
    #       should return a payload containing the OpenPGP key data. 
    # 
    variable openPgpKeyUri; # DEFAULT: ${baseUri}/${openPgpKeyUrn} 
 
    if {$force || ![info exists openPgpKeyUri]} then { 
      set openPgpKeyUri {${baseUri}/${openPgpKeyUrn}} 
    } 
 
    # 
    # NOTE: The URI where a login request may be sent.  This should return a 
    #       payload containing the necessary HTTP(S) cookie information. 
    # 
399
400
401
402
403



























404
405
406
407
408
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455





+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+





set dir $pkgd(savedDir); unset -nocomplain pkgd 
    }]] 
 
    return "" 
  } 
 
  # 
  # NOTE: This procedure attempts to download the Package Signing Key from 
  #       the remote server and save it to a local file.  This procedure may 
  #       raise script errors.  The fileName argument is the name of the file 
  #       where the downloaded data should be written.  This procedure is only 
  #       intended to be used from the "pkgr_setup.eagle" tool script and may 
  #       go away in later versions of this package. 
  # 
  # <internal> 
  proc downloadAndSaveOpenPgpKeyFile { fileName } { 
    variable baseUri 
    variable openPgpKeyUri 
    variable openPgpKeyUrn 
 
    # 
    # NOTE: First, build the final URI to download from the remote package 
    #       repository. 
    # 
    set uri [subst $openPgpKeyUri] 
 
    # 
    # NOTE: Then, in one step, download the file from the package file 
    #       server and write it to the specified local file. 
    # 
    downloadOneUriToFile $fileName $uri false 
  } 
 
  # 
  # NOTE: This procedure returns non-zero if the specified file seems to be 
  #       an OpenPGP signature file.  The fileName argument is the name of 
  #       the file to check, which may or may not exist.  The nameOnly 
1476
1477
1478
1479
1480





1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540





1541
1542
1543
1544
1545





+
+
+
+
+








-
-
-
-
-





    #       to the auto-path, if any. 
    # 
    return $downloadDirectories 
  } 
 
  # 
  # NOTE: This package requires the package repository client package. 
  # 
  package require Eagle.Package.Repository 
 
  # 
  # NOTE: This package requires that support for namespaces, which is an 
  #       optional feature of Eagle, must be enabled. 
  # 
  if {[isEagle] && ![namespace enable]} then { 
    error "namespaces must be enabled for this package" 
  } 
 
  # 
  # NOTE: This package requires the package repository client package. 
  # 
  package require Eagle.Package.Repository 
 
  # 
  # NOTE: Attempt to read optional settings file now.  This may override 
  #       one or more of the variable setup in the next step. 
  # 
  ::PackageRepository::maybeReadSettingsFile [info script]