From 6588b1d220e9d7c32c5a07eefa3f0d93da0bd79f Mon Sep 17 00:00:00 2001 From: Greg Shuflin Date: Sat, 17 Jun 2023 01:11:27 -0700 Subject: [PATCH] Convert to nix flake --- flake.lock | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ flake.nix | 46 ++++++++++++++++++++++++++++++++++++++++++ index.html | 4 ++-- 3 files changed, 107 insertions(+), 2 deletions(-) create mode 100644 flake.lock create mode 100644 flake.nix diff --git a/flake.lock b/flake.lock new file mode 100644 index 0000000..c8bb180 --- /dev/null +++ b/flake.lock @@ -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 +} diff --git a/flake.nix b/flake.nix new file mode 100644 index 0000000..1247645 --- /dev/null +++ b/flake.nix @@ -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 + + ''; + }; + } + + + ); + + +} diff --git a/index.html b/index.html index 80d8682..9e7a584 100644 --- a/index.html +++ b/index.html @@ -104,8 +104,8 @@ I used at Meraki for making the actual errors more obvious in lengthy C++ compiler output. It is published on crates.io. -
  • I recently started porting the SSHFS UNIX utility - from C to Rust. + +