From 25a45fb222e42812132013b5ad8acc23ab04fb4c Mon Sep 17 00:00:00 2001 From: William Carroll Date: Sat, 27 Jun 2020 14:06:59 +0100 Subject: Add export script for groceries At this point, I may be taking this idea too far, but what the heck? --- scratch/groceries/export.hs | 11 ++++++++++ scratch/groceries/list.txt | 50 +++++++++++++++++++++++++++++++++++++++++++++ scratch/groceries/shell.nix | 8 ++++++++ 3 files changed, 69 insertions(+) create mode 100644 scratch/groceries/export.hs create mode 100644 scratch/groceries/list.txt create mode 100644 scratch/groceries/shell.nix (limited to 'scratch/groceries') diff --git a/scratch/groceries/export.hs b/scratch/groceries/export.hs new file mode 100644 index 000000000000..5e2cce2237ee --- /dev/null +++ b/scratch/groceries/export.hs @@ -0,0 +1,11 @@ +module Main where + +import Data.Function ((&)) +import qualified Data.List as L + +-- | Run this to export the grocery list. +main :: IO () +main = do + x <- readFile "./list.txt" + x & lines & filter (not . L.isPrefixOf "- 0x") & unlines & putStrLn + pure () diff --git a/scratch/groceries/list.txt b/scratch/groceries/list.txt new file mode 100644 index 000000000000..0db547d95423 --- /dev/null +++ b/scratch/groceries/list.txt @@ -0,0 +1,50 @@ +- 0x coconut milk +- 4x tortellini / ravioli +- 0x coconut oil +- 1x sour cream +- 0x jar Weiner Wurstel +- 0x Ketchup +- 0x red wine +- 2x white wine +- 1x bacon bits +- 1x brocoli +- 1x spagel (10x) +- 1x green asparagus +- 0x olive oil +- 1x egg cartons (10x each) +- 0x butter +- 0x flour +- 1x bratwurst (4x) +- 0x Tabasco +- 1x parmesan +- 2x almonds +- 0x walnuts +- 1x lettuce +- 1x fleischwurst +- 0x GF bread +- 2x gouda +- 1x mystery cheese +- 1x tomatoes +- 0x shallots (10x) +- 0x garlic +- 0x ham for asparagus +- 1x beer (6x) +- 0x basil plant +- 0x senf +- 0x zucchini +- 3x lemons (3x) +- 0x coffee +- 0x coffee filters +- 0x tomato sauce +- 0x avocado +- 0x pesto +- 0x linguini pasta +- 0x green beans +- 0x hollandaise sauce +- 1x bug spray +- 1x 30 SPF sun screen +- 1x tiki torch +- 1x dish soap +- 1x paper towels (6x) +- 1x Brita +- 1x Lindt chocolate diff --git a/scratch/groceries/shell.nix b/scratch/groceries/shell.nix new file mode 100644 index 000000000000..c62b86e12832 --- /dev/null +++ b/scratch/groceries/shell.nix @@ -0,0 +1,8 @@ +let + pkgs = import {}; +in pkgs.mkShell { + buildInputs = with pkgs; [ + (haskellPackages.ghcWithPackages (hpkgs: with hpkgs; [ + ])) + ]; +} -- cgit 1.4.1