# Concept: use any package version

**URL:** https://discourse.nixos.org/t/concept-use-any-package-version/6515
**Category:** Development
**Created:** [April 1, 2020, 1:47am UTC](https://discourse.nixos.org/t/concept-use-any-package-version/6515 "2020-04-01T01:47:40Z")
**Posts on this page:** 1
**Showing post:** 3

<div class="post-metadata">

### Author: ![edolstra](https://discourse.nixos.org/user_avatar/discourse.nixos.org/edolstra/32/84_2.png) [@edolstra](https://discourse.nixos.org/u/edolstra)
#### Post date: [April 1, 2020, 7:56am UTC](https://discourse.nixos.org/t/concept-use-any-package-version/6515/3 "2020-04-01T07:56:59Z")

</div>

With flakes it’s already pretty easy to run/install something from an arbitrary version of Nixpkgs, e.g.

```auto
$ nix run nixpkgs/9077284a7ca32efd56e652286fdaa2ad851ce0c9#hello -c hello
Hello, world!

```

What is missing is a way to search historical versions of Nixpkgs for a particular version of a package. This cannot be done locally because it would be way too expensive and the database would be too large. However, @garbas is working on loading the `packages.json` files from each Nixpkgs release into ElasticSearch. The capability to search this database could be added to the `nix` CLI as a convenience.

However this would only be a CLI thing. This:

> `environment.systemPackages = with pkgs; [firefox@55];`

will never work because `firefox@55` is very under-specified: Nix would have no idea what `firefox@55` to use. Also, we’re moving away from a reliance on version numbers. The `nix` command, unlike `nix-env`, is based on attribute names rather than `<pname>-<version>`.

> This can be build by a standalone hydra job from master branch.

That’s basically [https://hydra.nixos.org/job/nixpkgs/trunk/tarball/latest/download-by-type/file/json-br](https://hydra.nixos.org/job/nixpkgs/trunk/tarball/latest/download-by-type/file/json-br).

---

_[View the full topic](https://discourse.nixos.org/t/concept-use-any-package-version/6515)._
