From aa122cbae78ce97d60c0c98ba14df753d97e40b1 Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Sun, 30 Jan 2022 19:06:58 +0300 Subject: style: format entire depot with nixpkgs-fmt This CL can be used to compare the style of nixpkgs-fmt against other formatters (nixpkgs, alejandra). Change-Id: I87c6abff6bcb546b02ead15ad0405f81e01b6d9e Reviewed-on: https://cl.tvl.fyi/c/depot/+/4397 Tested-by: BuildkiteCI Reviewed-by: sterni Reviewed-by: lukegb Reviewed-by: wpcarro Reviewed-by: Profpatsch Reviewed-by: kanepyork Reviewed-by: tazjin Reviewed-by: cynthia Reviewed-by: edef Reviewed-by: eta Reviewed-by: grfn --- users/tazjin/blog/default.nix | 17 ++++++++++------- users/tazjin/blog/posts.nix | 2 +- 2 files changed, 11 insertions(+), 8 deletions(-) (limited to 'users/tazjin/blog') diff --git a/users/tazjin/blog/default.nix b/users/tazjin/blog/default.nix index 6ac89e46656a..c8b3c318995b 100644 --- a/users/tazjin/blog/default.nix +++ b/users/tazjin/blog/default.nix @@ -23,7 +23,7 @@ let posts = filter includePost (list post (import ./posts.nix)); - rendered = pkgs.runCommandNoCC "tazjins-blog" {} '' + rendered = pkgs.runCommandNoCC "tazjins-blog" { } '' mkdir -p $out ${lib.concatStringsSep "\n" (map (post: @@ -31,13 +31,16 @@ let ) posts)} ''; -in { +in +{ inherit posts rendered config; # Generate embeddable nginx configuration for redirects from old post URLs - oldRedirects = lib.concatStringsSep "\n" (map (post: '' - location ~* ^(/en)?/${post.oldKey} { - return 301 https://tazj.in/blog/${post.key}; - } - '') (filter (hasAttr "oldKey") posts)); + oldRedirects = lib.concatStringsSep "\n" (map + (post: '' + location ~* ^(/en)?/${post.oldKey} { + return 301 https://tazj.in/blog/${post.key}; + } + '') + (filter (hasAttr "oldKey") posts)); } diff --git a/users/tazjin/blog/posts.nix b/users/tazjin/blog/posts.nix index b43598d01358..eeba600286db 100644 --- a/users/tazjin/blog/posts.nix +++ b/users/tazjin/blog/posts.nix @@ -37,7 +37,7 @@ key = "the-smu-problem"; title = "The SMU-problem of messaging apps"; date = 1450354078; - content =./posts/the-smu-problem.md; + content = ./posts/the-smu-problem.md; oldKey = "1450354078"; } { -- cgit 1.4.1