Sha256: c0e4471ef614ca0298ce7558029423dc89d5b09d00d8b9e282d3803bc7746d87
Contents?: true
Size: 915 Bytes
Versions: 2
Compression:
Stored size: 915 Bytes
Contents
let pkgs = import <nixpkgs> {}; lib = pkgs.lib; stdenv = pkgs.stdenv; in stdenv.mkDerivation rec { name = "confctl-shell"; buildInputs = with pkgs; [ git ncurses nix-prefetch-git openssl ruby ]; shellHook = '' CONFCTL="${toString ./.}" BASEDIR="$(realpath `pwd`)" export GEM_HOME="$(pwd)/.gems" BINDIR="$(ruby -e 'puts Gem.bindir')" mkdir -p "$BINDIR" export PATH="$BINDIR:$PATH" export RUBYLIB="$GEM_HOME:$CONFCTL/lib" export MANPATH="$CONFCTL/man:$(man --path)" gem install --no-document bundler overcommit rubocop pushd "$CONFCTL" bundle install bundle exec rake md2man:man popd cat <<EOF > "$BINDIR/confctl" #!${pkgs.ruby}/bin/ruby ENV['BUNDLE_GEMFILE'] = "$CONFCTL/Gemfile" require 'bundler' Bundler.setup load File.join('$CONFCTL', 'bin/confctl') EOF chmod +x "$BINDIR/confctl" ''; }
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
confctl-2.0.0 | shell.nix |
confctl-1.0.0 | shell.nix |