Convert to nix flake

This commit is contained in:
Greg Shuflin 2023-06-17 01:11:27 -07:00
parent 95b48ed751
commit 6588b1d220
3 changed files with 107 additions and 2 deletions

59
flake.lock Normal file
View File

@ -0,0 +1,59 @@
{
"nodes": {
"flake-utils": {
"inputs": {
"systems": "systems"
},
"locked": {
"lastModified": 1685518550,
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"nixpkgs": {
"locked": {
"lastModified": 1686949509,
"narHash": "sha256-52OTWmIjf5t5VcoGhSjRsCWHlwSf/mPhY+0fpaiA1hs=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "992ccdd822ecff0712ed0004f89df9e96f6a4963",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
}
},
"root": {
"inputs": {
"flake-utils": "flake-utils",
"nixpkgs": "nixpkgs"
}
},
"systems": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
}
},
"root": "root",
"version": 7
}

46
flake.nix Normal file
View File

@ -0,0 +1,46 @@
{
description = "A very basic flake";
inputs = {
flake-utils.url = "github:numtide/flake-utils";
};
outputs = { self, nixpkgs, flake-utils }:
{
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixpkgs-fmt;
} //
flake-utils.lib.eachDefaultSystem (system:
let
pkgs = import nixpkgs { inherit system; };
in
{
packages.default =
let
resumePackage = pkgs.callPackage /home/greg/code/active/resume/default.nix { };
in
pkgs.stdenv.mkDerivation {
name = "greg.everydayimshuflin.com-website";
src = ./.;
buildInputs = [ resumePackage ];
installPhase = ''
mkdir $out
cp index.html $out
cp style.css $out
cp self.jpg $out
cp favicon.png $out
mkdir $out/resume/
cp ${resumePackage}/*.pdf $out/resume
'';
};
}
);
}

View File

@ -104,8 +104,8 @@
I used at Meraki for making the actual errors more obvious in lengthy C++ compiler output. It
is published on <a href="https://crates.io/crates/hilite">crates.io</a>.
<li>I recently started porting the <a href="https://github.com/neunenak/sshfs">SSHFS</a> UNIX utility
from C to Rust.
<!-- <li>I recently started porting the <a href="https://github.com/neunenak/sshfs">SSHFS</a> UNIX utility -->
<!-- from C to Rust. -->
</ul>