Skip to content

Commit ed59b2c

Browse files
authoredJul 2, 2017
Revert "i3: add configFile to enable cutom configuration locations"
1 parent b084b93 commit ed59b2c

File tree

2 files changed

+54
-69
lines changed

2 files changed

+54
-69
lines changed
 
Original file line numberDiff line numberDiff line change
@@ -1,85 +1,72 @@
11
{ fetchurl, stdenv, which, pkgconfig, makeWrapper, libxcb, xcbutilkeysyms
22
, xcbutil, xcbutilwm, xcbutilxrm, libstartup_notification, libX11, pcre, libev
33
, yajl, xcb-util-cursor, coreutils, perl, pango, perlPackages, libxkbcommon
4-
, xorgserver, xvfb_run, symlinkJoin, configFile ? null }:
4+
, xorgserver, xvfb_run }:
55

6-
let
6+
stdenv.mkDerivation rec {
7+
name = "i3-${version}";
78
version = "4.13";
89

9-
i3 = stdenv.mkDerivation rec {
10-
name = "i3-${version}";
11-
12-
src = fetchurl {
13-
url = "http://i3wm.org/downloads/${name}.tar.bz2";
14-
sha256 = "12ngz32swh9n85xy0cz1lq16aqi9ys5hq19v589q9a97wn1k3hcl";
15-
};
10+
src = fetchurl {
11+
url = "http://i3wm.org/downloads/${name}.tar.bz2";
12+
sha256 = "12ngz32swh9n85xy0cz1lq16aqi9ys5hq19v589q9a97wn1k3hcl";
13+
};
1614

17-
nativeBuildInputs = [ which pkgconfig makeWrapper ];
15+
nativeBuildInputs = [ which pkgconfig makeWrapper ];
1816

19-
buildInputs = [
20-
libxcb xcbutilkeysyms xcbutil xcbutilwm xcbutilxrm libxkbcommon
21-
libstartup_notification libX11 pcre libev yajl xcb-util-cursor perl pango
22-
perlPackages.AnyEventI3 perlPackages.X11XCB perlPackages.IPCRun
23-
perlPackages.ExtUtilsPkgConfig perlPackages.TestMore perlPackages.InlineC
24-
xorgserver xvfb_run
25-
];
17+
buildInputs = [
18+
libxcb xcbutilkeysyms xcbutil xcbutilwm xcbutilxrm libxkbcommon
19+
libstartup_notification libX11 pcre libev yajl xcb-util-cursor perl pango
20+
perlPackages.AnyEventI3 perlPackages.X11XCB perlPackages.IPCRun
21+
perlPackages.ExtUtilsPkgConfig perlPackages.TestMore perlPackages.InlineC
22+
xorgserver xvfb_run
23+
];
2624

27-
configureFlags = [ "--disable-builddir" ];
25+
configureFlags = [ "--disable-builddir" ];
2826

29-
enableParallelBuilding = true;
27+
enableParallelBuilding = true;
3028

31-
postPatch = ''
32-
patchShebangs .
33-
'';
29+
postPatch = ''
30+
patchShebangs .
31+
'';
3432

35-
# Tests have been failing (at least for some people in some cases)
36-
# and have been disabled until someone wants to fix them. Some
37-
# initial digging uncovers that the tests call out to `git`, which
38-
# they shouldn't, and then even once that's fixed have some
39-
# perl-related errors later on. For more, see
40-
# https://github.com/NixOS/nixpkgs/issues/7957
41-
doCheck = false; # stdenv.system == "x86_64-linux";
33+
# Tests have been failing (at least for some people in some cases)
34+
# and have been disabled until someone wants to fix them. Some
35+
# initial digging uncovers that the tests call out to `git`, which
36+
# they shouldn't, and then even once that's fixed have some
37+
# perl-related errors later on. For more, see
38+
# https://github.com/NixOS/nixpkgs/issues/7957
39+
doCheck = false; # stdenv.system == "x86_64-linux";
40+
41+
checkPhase = stdenv.lib.optionalString (stdenv.system == "x86_64-linux")
42+
''
43+
(cd testcases && xvfb-run ./complete-run.pl -p 1 --keep-xserver-output)
44+
! grep -q '^not ok' testcases/latest/complete-run.log
45+
'';
4246

43-
checkPhase = stdenv.lib.optionalString (stdenv.system == "x86_64-linux")
44-
''
45-
(cd testcases && xvfb-run ./complete-run.pl -p 1 --keep-xserver-output)
46-
! grep -q '^not ok' testcases/latest/complete-run.log
47-
'';
47+
postInstall = ''
48+
wrapProgram "$out/bin/i3-save-tree" --prefix PERL5LIB ":" "$PERL5LIB"
49+
for program in $out/bin/i3-sensible-*; do
50+
sed -i 's/which/command -v/' $program
51+
done
52+
'';
4853

49-
postInstall = ''
50-
wrapProgram "$out/bin/i3-save-tree" --prefix PERL5LIB ":" "$PERL5LIB"
51-
for program in $out/bin/i3-sensible-*; do
52-
sed -i 's/which/command -v/' $program
53-
done
54+
separateDebugInfo = true;
55+
56+
meta = with stdenv.lib; {
57+
description = "A tiling window manager";
58+
homepage = "http://i3wm.org";
59+
maintainers = with maintainers; [ garbas modulistic fpletz ];
60+
license = licenses.bsd3;
61+
platforms = platforms.all;
62+
63+
longDescription = ''
64+
A tiling window manager primarily targeted at advanced users and
65+
developers. Based on a tree as data structure, supports tiling,
66+
stacking, and tabbing layouts, handled dynamically, as well as
67+
floating windows. Configured via plain text file. Multi-monitor.
68+
UTF-8 clean.
5469
'';
55-
56-
separateDebugInfo = true;
57-
58-
meta = with stdenv.lib; {
59-
description = "A tiling window manager";
60-
homepage = "http://i3wm.org";
61-
maintainers = with maintainers; [ garbas modulistic fpletz ];
62-
license = licenses.bsd3;
63-
platforms = platforms.all;
64-
65-
longDescription = ''
66-
A tiling window manager primarily targeted at advanced users and
67-
developers. Based on a tree as data structure, supports tiling,
68-
stacking, and tabbing layouts, handled dynamically, as well as
69-
floating windows. Configured via plain text file. Multi-monitor.
70-
UTF-8 clean.
71-
'';
72-
};
73-
7470
};
75-
in if configFile == null then i3 else symlinkJoin {
76-
name = "i3-with-config-${version}";
77-
paths = [ i3 ];
78-
79-
buildInputs = [ makeWrapper ];
8071

81-
postBuild = ''
82-
wrapProgram $out/bin/i3 \
83-
--add-flags "-c ${configFile}"
84-
'';
8572
}

‎pkgs/top-level/all-packages.nix

-2
Original file line numberDiff line numberDiff line change
@@ -14492,8 +14492,6 @@ with pkgs;
1449214492

1449314493
i3 = callPackage ../applications/window-managers/i3 {
1449414494
xcb-util-cursor = if stdenv.isDarwin then xcb-util-cursor-HEAD else xcb-util-cursor;
14495-
14496-
configFile = config.i3.configFile or null;
1449714495
};
1449814496

1449914497
i3-gaps = callPackage ../applications/window-managers/i3/gaps.nix { };

1 commit comments

Comments
 (1)

bjornfor commented on Jul 9, 2017

@bjornfor
Contributor

Please explain why a commit is made in the commit message.

Please sign in to comment.