diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6c7eb1d..d2702cc 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,4 +16,4 @@ jobs: with: name: dconf2nix signingKey: "${{ secrets.CACHIX_SIGNING_KEY }}" - - run: nix-shell --run "nix-build-uncached default.nix" ci.nix + - run: nix-shell --run "nix-build-uncached default.nix" nix/ci.nix diff --git a/.gitignore b/.gitignore index 6f4d23e..20ccdd8 100644 --- a/.gitignore +++ b/.gitignore @@ -5,4 +5,4 @@ dist-newstyle/ dist/ .ghc.* .direnv -result +result* diff --git a/README.md b/README.md index 6c00bff..4bcae6e 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,18 @@ A convenient converter of [DConf](https://wiki.gnome.org/Projects/dconf) files to Nix, as expected by [Home Manager's dconf settings](https://rycee.gitlab.io/home-manager/options.html#opt-dconf.settings). So you can Nixify your [Gnome Shell](https://wiki.gnome.org/Projects/GnomeShell) configuration :wink: + +* [Benchmarks](#benchmarks) +* [Introduction](#introduction) +* [Run](#run) + * [Custom root](#custom-root) +* [Supported types](#supported-types) +* [Gnome Shell configuration](#gnome-shell-configuration) +* [Installation](#installation) +* [Troubleshooting](#troubleshooting) +* [Development](#development) + + --- ### Benchmarks diff --git a/dconf2nix.cabal b/dconf2nix.cabal index d276a29..3456a25 100644 --- a/dconf2nix.cabal +++ b/dconf2nix.cabal @@ -1,7 +1,7 @@ cabal-version: 2.4 name: dconf2nix -version: 0.0.6 +version: 0.0.7 synopsis: Convert dconf files to Nix, as expected by Home Manager. description: A convenient converter of DConf files to Nix, as expected by Home Manager's dconf settings. So you can Nixify your Gnome Shell configuration ;) bug-reports: https://github.com/gvolpe/dconf2nix/issues diff --git a/default.nix b/default.nix index 28a0ccd..7aaabd1 100644 --- a/default.nix +++ b/default.nix @@ -1,4 +1,4 @@ -{ packages ? import ./pkgs.nix { inherit compiler; }, compiler ? "ghc884" }: +{ packages ? import nix/pkgs.nix { inherit compiler; }, compiler ? "ghc884" }: let inherit (packages) hp; diff --git a/ci.nix b/nix/ci.nix similarity index 100% rename from ci.nix rename to nix/ci.nix diff --git a/pkgs.nix b/nix/pkgs.nix similarity index 100% rename from pkgs.nix rename to nix/pkgs.nix diff --git a/nix/toc.nix b/nix/toc.nix new file mode 100644 index 0000000..87eaa48 --- /dev/null +++ b/nix/toc.nix @@ -0,0 +1,24 @@ +{ compiler ? "ghc884" }: + +let + pkgs = (import ./pkgs.nix { inherit compiler; }).pkgs; + toc = pkgs.stdenv.mkDerivation { + name = "gh-md-toc-24-05-2020"; + + src = builtins.fetchurl { + url = "https://raw.githubusercontent.com/ekalinin/github-markdown-toc/488f310064b16c1eb9c17862cc5844189ee65955/gh-md-toc"; + sha256 = "1253n0qw3xgikl7gcdicg3vmc3wzz6122bmhmffj1irrachq89fi"; + }; + + phases = ["installPhase" "patchPhase"]; + + installPhase = '' + mkdir -p $out/bin + cp $src $out/bin/gh-md-toc + chmod +x $out/bin/gh-md-toc + ''; + }; +in + pkgs.writeShellScriptBin "update-toc" '' + ${toc}/bin/gh-md-toc --insert README.md + '' diff --git a/shell.nix b/shell.nix index f0f7cf4..640b033 100644 --- a/shell.nix +++ b/shell.nix @@ -1,5 +1,5 @@ let - packages = import ./pkgs.nix {}; + packages = import nix/pkgs.nix {}; inherit (packages) pkgs hp; drv = hp.callCabal2nix "dconf2nix" ./. {};