* Move NARs from the NixChannel controller to the Root controller and

[?]
Jun 22, 2010, 12:00 PM
MVB7RRLTOLZALMUVUNSCMXDB76QLICJAV2GYQQZO7E6S327LHMSQC

Dependencies

  • [2] BHZXGT2H * Channels: provide an index page that lists all the packages in the
  • [3] 57I2WW3P * Argh.
  • [4] IGZ3IFSG * Escape `+', `=' and `?' in NAR URIS in manifests. Otherwise you get
  • [5] 2JQ7WEFM
  • [6] Y35C6GHH * One-click installs.
  • [7] XHVZXX6N
  • [8] LVJKRTIK * Generate a Nix expression for the channel.
  • [9] UXVDOUBJ
  • [10] OD5FSS5A * Quick hack to allow viewing of dependency graphs (via nix-store -q
  • [11] BDSD2JLV * Speed up manifest generation.
  • [12] UZENK33P * Generate a .tar.bz2 file for the channel Nix expression, since
  • [13] BDY5KCG7 * When a store path has disappeared for some reason,
  • [14] WJ35RSKA
  • [15] 5NO7NCKT * Refactoring.
  • [16] ZRBXLKFO
  • [17] IWVA2P2Y * Generate manifests on demand. Next step: generate NAR archives on
  • [18] FPK5LF53 * Put the project-related actions in a separate controller. Put the
  • [*] LBNVQXUB * Build the /build stuff in a separate controller.
  • [*] J5UVLXOK * Start of a basic Catalyst web interface.
  • [*] SMM4HQTP * Put actions related to builds under /build (e.g. /log/<buildid>

Change contents

  • replacement in src/lib/Hydra/Base/Controller/NixChannel.pm at line 12
    [5.269][5.269:328]()
    $c->stash->{current_view} = 'Hydra::View::NixClosure';
    [5.269]
    [5.328]
    $c->stash->{current_view} = 'NixClosure';
  • replacement in src/lib/Hydra/Base/Controller/NixChannel.pm at line 23
    [5.677][5.677:737](),[5.737][5.0:85]()
    $c->stash->{current_view} = 'Hydra::View::NixManifest';
    $c->stash->{narBase} = $c->uri_for($self->action_for("nar"), $c->req->captures);
    [5.677]
    [5.737]
    $c->stash->{current_view} = 'NixManifest';
    $c->stash->{narBase} = $c->uri_for($c->controller('Root')->action_for("nar"));
  • edit in src/lib/Hydra/Base/Controller/NixChannel.pm at line 26
    [5.739][5.86:156]()
    sub nar : Chained('nix') PathPart {
    my ($self, $c, @rest) = @_;
  • edit in src/lib/Hydra/Base/Controller/NixChannel.pm at line 27
    [5.157][5.157:197]()
    my $path .= "/" . join("/", @rest);
  • edit in src/lib/Hydra/Base/Controller/NixChannel.pm at line 28
    [5.740][5.62:93](),[5.93][3.0:44](),[3.44][5.135:206](),[5.135][5.135:206](),[5.206][5.740:741](),[5.285][5.740:741](),[5.740][5.740:741](),[5.741][5.286:451](),[5.451][5.0:4]()
    if (!isValidPath($path)) {
    $c->response->status(410); # "Gone"
    error($c, "Path " . $path . " is no longer available.");
    }
    # !!! check that $path is in the closure of $c->stash->{storePaths}.
    $c->stash->{current_view} = 'Hydra::View::NixNAR';
    $c->stash->{storePath} = $path;
    }
  • replacement in src/lib/Hydra/Base/Controller/NixChannel.pm at line 40
    [5.247][5.247:302]()
    $c->stash->{current_view} = 'Hydra::View::NixPkg';
    [5.247]
    [5.302]
    $c->stash->{current_view} = 'NixPkg';
  • replacement in src/lib/Hydra/Base/Controller/NixChannel.pm at line 48
    [5.78][5.78:135]()
    $c->stash->{current_view} = 'Hydra::View::NixExprs';
    [5.78]
    [2.41]
    $c->stash->{current_view} = 'NixExprs';
  • replacement in src/lib/Hydra/Controller/Build.pm at line 269
    [5.413][5.413:473]()
    $c->stash->{current_view} = 'Hydra::View::NixDepGraph';
    [5.413]
    [5.473]
    $c->stash->{current_view} = 'NixDepGraph';
  • replacement in src/lib/Hydra/Controller/Build.pm at line 284
    [5.842][5.842:902]()
    $c->stash->{current_view} = 'Hydra::View::NixDepGraph';
    [5.842]
    [5.902]
    $c->stash->{current_view} = 'NixDepGraph';
  • edit in src/lib/Hydra/Controller/Root.pm at line 159
    [22.1744]
    [21.2636]
    sub nar :Local :Args(1) {
    my ($self, $c, $path) = @_;
  • edit in src/lib/Hydra/Controller/Root.pm at line 164
    [21.2637]
    [21.2637]
    $path = "/nix/store/$path";
  • edit in src/lib/Hydra/Controller/Root.pm at line 166
    [21.2638]
    [21.2638]
    if (!isValidPath($path)) {
    $c->response->status(410); # "Gone"
    error($c, "Path " . $path . " is no longer available.");
    }
    $c->stash->{current_view} = 'NixNAR';
    $c->stash->{storePath} = $path;
    }
  • edit in src/lib/Hydra/View/NixManifest.pm at line 29
    [4.153]
    [4.153]
    $escaped =~ s/^.*\///; # remove /nix/store/
  • replacement in src/lib/Hydra/View/NixManifest.pm at line 34
    [5.1222][4.250:301]()
    my $url = $c->stash->{narBase} . $escaped;
    [5.1222]
    [5.590]
    my $url = $c->stash->{narBase} . "/" . $escaped;