Skip to content

Commit

Permalink
nixpkgs-fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
zimbatm committed Mar 8, 2021
1 parent 70854a5 commit e850799
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 15 deletions.
2 changes: 1 addition & 1 deletion images/cachix/default.nix
Expand Up @@ -6,7 +6,7 @@
nix = nix;
extraContents = [ cachix ];
}).overrideAttrs (prev: {
meta = (prev.meta or {}) // {
meta = (prev.meta or { }) // {
description = "Nix and Cachix image";
};
})
2 changes: 1 addition & 1 deletion images/devcontainer/default.nix
Expand Up @@ -25,7 +25,7 @@
, mkUserEnvironment
}:
let
channel = builtins.getEnv("NIXPKGS_CHANNEL");
channel = builtins.getEnv ("NIXPKGS_CHANNEL");

# generate a user profile for the image
profile = mkUserEnvironment {
Expand Down
2 changes: 1 addition & 1 deletion images/nix/default.nix
Expand Up @@ -10,7 +10,7 @@
, nix
, openssh
, xz
, extraContents ? []
, extraContents ? [ ]
}:
let
image = dockerTools.buildImageWithNixDb {
Expand Down
10 changes: 5 additions & 5 deletions images/nix/fake_nixpkgs/default.nix
@@ -1,10 +1,10 @@
_:
throw ''
This container doesn't include nixpkgs.
This container doesn't include nixpkgs.
The best way to work around that is to pin your dependencies. See
https://nix.dev/tutorials/towards-reproducibility-pinning-nixpkgs.html
The best way to work around that is to pin your dependencies. See
https://nix.dev/tutorials/towards-reproducibility-pinning-nixpkgs.html
Or if you must, override the NIX_PATH environment variable with eg:
"NIX_PATH=nixpkgs=channel:nixos-unstable"
Or if you must, override the NIX_PATH environment variable with eg:
"NIX_PATH=nixpkgs=channel:nixos-unstable"
''
2 changes: 1 addition & 1 deletion lib/buildCLIImage.nix
Expand Up @@ -5,7 +5,7 @@
{ drv # derivation to build the image for
# Name of the binary to run by default
, binName ? (builtins.parseDrvName drv.name).name
, extraContents ? []
, extraContents ? [ ]
, meta ? drv.meta
}:
let
Expand Down
9 changes: 5 additions & 4 deletions overlay.nix
@@ -1,17 +1,18 @@
_: pkgs: let
_: pkgs:
let
importDir = import ./lib/importDir.nix {
inherit (pkgs) lib;
};
in
{
# builder stuff can be in the top-level
buildCLIImage = pkgs.callPackage ./lib/buildCLIImage.nix {};
buildCLIImage = pkgs.callPackage ./lib/buildCLIImage.nix { };

# docker images must be lower-cased
docker-nixpkgs = importDir (path: pkgs.callPackage path {}) ./images;
docker-nixpkgs = importDir (path: pkgs.callPackage path { }) ./images;

# used to build nix-env compatible user environments
mkUserEnvironment = pkgs.callPackage ./lib/mkUserEnvironment.nix {};
mkUserEnvironment = pkgs.callPackage ./lib/mkUserEnvironment.nix { };

# gitMinimal still ships with perl and python
gitReallyMinimal = (
Expand Down
2 changes: 1 addition & 1 deletion pkgs.nix
@@ -1,7 +1,7 @@
import <nixpkgs> {
# docker images run on Linux
system = "x86_64-linux";
config = {};
config = { };
overlays = [
(import ./overlay.nix)
];
Expand Down
2 changes: 1 addition & 1 deletion shell.nix
@@ -1,6 +1,6 @@
let
nixpkgs = builtins.fetchTarball "channel:nixos-20.09";
pkgs = import nixpkgs { config = {}; overlays = []; };
pkgs = import nixpkgs { config = { }; overlays = [ ]; };
in
with pkgs;
mkShell {
Expand Down

0 comments on commit e850799

Please sign in to comment.