mirror of
https://github.com/foo-dogsquared/website.git
synced 2025-01-31 04:58:26 +00:00
project: use ruby-nix
This commit is contained in:
parent
4650f41d1b
commit
100cb299cc
10
flake.nix
10
flake.nix
@ -4,12 +4,18 @@
|
|||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
|
||||||
flake-utils.url = "github:numtide/flake-utils";
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
|
ruby-nix.url = "github:sagittaros/ruby-nix";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = inputs@{ self, nixpkgs, ... }:
|
outputs = inputs@{ self, nixpkgs, ... }:
|
||||||
let systems = inputs.flake-utils.lib.defaultSystems;
|
let systems = inputs.flake-utils.lib.defaultSystems;
|
||||||
in inputs.flake-utils.lib.eachSystem systems (system: {
|
in inputs.flake-utils.lib.eachSystem systems (system: {
|
||||||
devShells.default =
|
devShells.default = let
|
||||||
import ./shell.nix { pkgs = import nixpkgs { inherit system; }; };
|
pkgs = import nixpkgs { inherit system; };
|
||||||
|
in
|
||||||
|
import ./shell.nix {
|
||||||
|
inherit pkgs;
|
||||||
|
ruby-nix = inputs.ruby-nix.lib pkgs;
|
||||||
|
};
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
14
shell.nix
14
shell.nix
@ -1,18 +1,20 @@
|
|||||||
{ pkgs ? import <nixpkgs> { } }:
|
{ pkgs ? import <nixpkgs> { }, ruby-nix }:
|
||||||
|
|
||||||
with pkgs;
|
with pkgs;
|
||||||
|
|
||||||
let
|
let
|
||||||
gems = bundlerEnv {
|
localGems = ruby-nix {
|
||||||
name = "hugo-website-gems";
|
name = "hugo-website-gems";
|
||||||
gemdir = ./.;
|
gemset = ./gemset.nix;
|
||||||
};
|
};
|
||||||
in
|
in
|
||||||
mkShell {
|
mkShell {
|
||||||
packages = [
|
buildInputs = [
|
||||||
gems
|
localGems.env
|
||||||
gems.wrappedRuby
|
localGems.ruby
|
||||||
|
];
|
||||||
|
|
||||||
|
packages = [
|
||||||
git
|
git
|
||||||
go
|
go
|
||||||
hugo
|
hugo
|
||||||
|
Loading…
Reference in New Issue
Block a user