From 1f14476a0ffa3dcf0576121edc914b15cfb971b9 Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 1 May 2017 22:52:59 +0200 Subject: netcup: tv -> krebs --- krebs/5pkgs/netcup/default.nix | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 krebs/5pkgs/netcup/default.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/netcup/default.nix b/krebs/5pkgs/netcup/default.nix new file mode 100644 index 000000000..d1f46299d --- /dev/null +++ b/krebs/5pkgs/netcup/default.nix @@ -0,0 +1,32 @@ +{ coreutils, curl, fetchgit, gawk, gnugrep, gnused, jq, stdenv, w3m, ... }: +with import ; +let + readJSON = path: fromJSON (readFile path); + sed.escape = replaceChars ["/"] ["\\/"]; # close enough + PATH = makeBinPath [ + coreutils + curl + gawk + gnugrep + gnused + jq + w3m + ]; +in +stdenv.mkDerivation { + name = "netcup-1.0.0"; + src = fetchgit { + url = "http://cgit.ni.krebsco.de/netcup"; + rev = "refs/tags/v1.0.0"; + sha256 = "1rn7bncfhjw0bqjbvj38m7lks4nyf5qcvkj9dg0zr99ba6dylzx5"; + }; + phases = [ "unpackPhase" "patchPhase" "installPhase" ]; + patchPhase = '' + path=${shell.escape (sed.escape PATH)} + sed -i "1s/.*/&\nPATH=$path/" vcp + ''; + installPhase = '' + mkdir -p $out/bin + cp vcp $out/bin + ''; +} -- cgit v1.2.3 From 1a7d62733ca6d49114d5a19eeb6052d51a7c19b2 Mon Sep 17 00:00:00 2001 From: lassulus Date: Tue, 2 May 2017 20:10:36 +0200 Subject: k 5 goify: fix extra space bug --- krebs/5pkgs/goify/default.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/goify/default.nix b/krebs/5pkgs/goify/default.nix index e2849b5c7..9c44aaeeb 100644 --- a/krebs/5pkgs/goify/default.nix +++ b/krebs/5pkgs/goify/default.nix @@ -1,17 +1,18 @@ { pkgs, ... }: -pkgs.writeDashBin "goify" '' +pkgs.writeBashBin "goify" '' set -euf GO_HOST=''${GO_HOST:-go} while read line; do - echo "$line" | sed -E 's|https?://\S*|\n&\n|g' | while read word; do - if echo "$word" | grep -Eq ^https?:; then - ${pkgs.curl}/bin/curl -Ss -F uri="$word" http://"$GO_HOST" | tr -d '\r' + echo "$line" | sed 's|https\?://\S*|\n&\n|g' | while read word; do + if echo "$word" | grep -q '^https\?:'; then + ${pkgs.curl}/bin/curl -Ss -F uri="$word" http://"$GO_HOST" \ + | tr -d '\r' else - echo "$word"; - fi; - done | sed '/^$/d' | tr '\n' ' '; echo; + echo "$word" + fi + done | grep . | tr '\n' ' '; echo done '' -- cgit v1.2.3 From 8006120256a2e126bfe768ed173ca1df8a99bf4f Mon Sep 17 00:00:00 2001 From: tv Date: Tue, 2 May 2017 22:07:50 +0200 Subject: haskellPackages.irc: init at 1.0.0 --- krebs/5pkgs/haskell-overrides/irc.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 krebs/5pkgs/haskell-overrides/irc.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/haskell-overrides/irc.nix b/krebs/5pkgs/haskell-overrides/irc.nix new file mode 100644 index 000000000..b20885572 --- /dev/null +++ b/krebs/5pkgs/haskell-overrides/irc.nix @@ -0,0 +1,18 @@ +{ mkDerivation, async, base, bytestring, fetchgit, network +, optparse-applicative, stdenv, text +}: +mkDerivation { + pname = "irc"; + version = "1.0.0"; + src = fetchgit { + url = "http://cgit.krebsco.de/irc"; + sha256 = "174ywhvidybg49m4b43q2304izwbx3s7bvipk9g399zjyb392r8f"; + rev = "7225d47e9c1f4c7032ad55fbe1d9f33ff205549c"; + }; + isLibrary = false; + isExecutable = true; + executableHaskellDepends = [ + async base bytestring network optparse-applicative text + ]; + license = stdenv.lib.licenses.mit; +} -- cgit v1.2.3 From 9457f3fe8e9a35ee19b5a60e3aef3cc1c51dd344 Mon Sep 17 00:00:00 2001 From: tv Date: Tue, 2 May 2017 22:14:17 +0200 Subject: haskellPackages: irc -> kirk --- krebs/5pkgs/haskell-overrides/irc.nix | 18 ------------------ krebs/5pkgs/haskell-overrides/kirk.nix | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 18 deletions(-) delete mode 100644 krebs/5pkgs/haskell-overrides/irc.nix create mode 100644 krebs/5pkgs/haskell-overrides/kirk.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/haskell-overrides/irc.nix b/krebs/5pkgs/haskell-overrides/irc.nix deleted file mode 100644 index b20885572..000000000 --- a/krebs/5pkgs/haskell-overrides/irc.nix +++ /dev/null @@ -1,18 +0,0 @@ -{ mkDerivation, async, base, bytestring, fetchgit, network -, optparse-applicative, stdenv, text -}: -mkDerivation { - pname = "irc"; - version = "1.0.0"; - src = fetchgit { - url = "http://cgit.krebsco.de/irc"; - sha256 = "174ywhvidybg49m4b43q2304izwbx3s7bvipk9g399zjyb392r8f"; - rev = "7225d47e9c1f4c7032ad55fbe1d9f33ff205549c"; - }; - isLibrary = false; - isExecutable = true; - executableHaskellDepends = [ - async base bytestring network optparse-applicative text - ]; - license = stdenv.lib.licenses.mit; -} diff --git a/krebs/5pkgs/haskell-overrides/kirk.nix b/krebs/5pkgs/haskell-overrides/kirk.nix new file mode 100644 index 000000000..2cd6bb134 --- /dev/null +++ b/krebs/5pkgs/haskell-overrides/kirk.nix @@ -0,0 +1,18 @@ +{ mkDerivation, async, base, bytestring, fetchgit, network +, optparse-applicative, stdenv, text +}: +mkDerivation { + pname = "kirk"; + version = "1.0.0"; + src = fetchgit { + url = "http://cgit.krebsco.de/kirk"; + sha256 = "0w4drg2lyyw45abfn3g55zd6m7pl7yqxql5rpyy6qqdbvnyak94w"; + rev = "c78f3c62c0ba76465e39d1570073f867aa2d4240"; + }; + isLibrary = false; + isExecutable = true; + executableHaskellDepends = [ + async base bytestring network optparse-applicative text + ]; + license = stdenv.lib.licenses.mit; +} -- cgit v1.2.3 From e48425770fe42617d244909497867ec800cc691e Mon Sep 17 00:00:00 2001 From: lassulus Date: Tue, 2 May 2017 22:52:19 +0200 Subject: youtube-dl: init at 2017.04.28 --- krebs/5pkgs/youtube-dl/default.nix | 58 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 krebs/5pkgs/youtube-dl/default.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/youtube-dl/default.nix b/krebs/5pkgs/youtube-dl/default.nix new file mode 100644 index 000000000..b0c449d49 --- /dev/null +++ b/krebs/5pkgs/youtube-dl/default.nix @@ -0,0 +1,58 @@ +{ stdenv, fetchurl, pkgs +, zip, ffmpeg, rtmpdump, atomicparsley, pandoc +# Pandoc is required to build the package's man page. Release tarballs contain a +# formatted man page already, though, it will still be installed. We keep the +# manpage argument in place in case someone wants to use this derivation to +# build a Git version of the tool that doesn't have the formatted man page +# included. +, generateManPage ? false +, ffmpegSupport ? true +, rtmpSupport ? true +, makeWrapper }: + +with stdenv.lib; +let + buildPythonApplication = args: pkgs.pythonPackages.buildPythonPackage ({namePrefix="";} // args ); +in buildPythonApplication rec { + + name = "youtube-dl-${version}"; + version = "2017.04.28"; + + src = fetchurl { + url = "https://yt-dl.org/downloads/${version}/${name}.tar.gz"; + sha256 = "0d3mgf8qxb07b7bjf79ppaxhcl4f47q0zjpshp6y2q0lalfskh3j"; + }; + + nativeBuildInputs = [ makeWrapper ]; + buildInputs = [ zip ] ++ optional generateManPage pandoc; + + # Ensure ffmpeg is available in $PATH for post-processing & transcoding support. + # rtmpdump is required to download files over RTMP + # atomicparsley for embedding thumbnails + postInstall = let + packagesToBinPath = + [ atomicparsley ] + ++ optional ffmpegSupport ffmpeg + ++ optional rtmpSupport rtmpdump; + in '' + wrapProgram $out/bin/youtube-dl --prefix PATH : "${makeBinPath packagesToBinPath}" + ''; + + # Requires network + doCheck = false; + + meta = { + homepage = http://rg3.github.io/youtube-dl/; + repositories.git = https://github.com/rg3/youtube-dl.git; + description = "Command-line tool to download videos from YouTube.com and other sites"; + longDescription = '' + youtube-dl is a small, Python-based command-line program + to download videos from YouTube.com and a few more sites. + youtube-dl is released to the public domain, which means + you can modify it, redistribute it or use it however you like. + ''; + license = licenses.publicDomain; + platforms = with platforms; linux ++ darwin; + maintainers = with maintainers; [ bluescreen303 phreedom AndersonTorres fuuzetsu fpletz ]; + }; +} -- cgit v1.2.3 From f8891425d6b918237656201a1256e81605983546 Mon Sep 17 00:00:00 2001 From: lassulus Date: Mon, 8 May 2017 21:08:13 +0200 Subject: youtube-dl: remove because upstream catched up --- krebs/5pkgs/youtube-dl/default.nix | 58 -------------------------------------- 1 file changed, 58 deletions(-) delete mode 100644 krebs/5pkgs/youtube-dl/default.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/youtube-dl/default.nix b/krebs/5pkgs/youtube-dl/default.nix deleted file mode 100644 index b0c449d49..000000000 --- a/krebs/5pkgs/youtube-dl/default.nix +++ /dev/null @@ -1,58 +0,0 @@ -{ stdenv, fetchurl, pkgs -, zip, ffmpeg, rtmpdump, atomicparsley, pandoc -# Pandoc is required to build the package's man page. Release tarballs contain a -# formatted man page already, though, it will still be installed. We keep the -# manpage argument in place in case someone wants to use this derivation to -# build a Git version of the tool that doesn't have the formatted man page -# included. -, generateManPage ? false -, ffmpegSupport ? true -, rtmpSupport ? true -, makeWrapper }: - -with stdenv.lib; -let - buildPythonApplication = args: pkgs.pythonPackages.buildPythonPackage ({namePrefix="";} // args ); -in buildPythonApplication rec { - - name = "youtube-dl-${version}"; - version = "2017.04.28"; - - src = fetchurl { - url = "https://yt-dl.org/downloads/${version}/${name}.tar.gz"; - sha256 = "0d3mgf8qxb07b7bjf79ppaxhcl4f47q0zjpshp6y2q0lalfskh3j"; - }; - - nativeBuildInputs = [ makeWrapper ]; - buildInputs = [ zip ] ++ optional generateManPage pandoc; - - # Ensure ffmpeg is available in $PATH for post-processing & transcoding support. - # rtmpdump is required to download files over RTMP - # atomicparsley for embedding thumbnails - postInstall = let - packagesToBinPath = - [ atomicparsley ] - ++ optional ffmpegSupport ffmpeg - ++ optional rtmpSupport rtmpdump; - in '' - wrapProgram $out/bin/youtube-dl --prefix PATH : "${makeBinPath packagesToBinPath}" - ''; - - # Requires network - doCheck = false; - - meta = { - homepage = http://rg3.github.io/youtube-dl/; - repositories.git = https://github.com/rg3/youtube-dl.git; - description = "Command-line tool to download videos from YouTube.com and other sites"; - longDescription = '' - youtube-dl is a small, Python-based command-line program - to download videos from YouTube.com and a few more sites. - youtube-dl is released to the public domain, which means - you can modify it, redistribute it or use it however you like. - ''; - license = licenses.publicDomain; - platforms = with platforms; linux ++ darwin; - maintainers = with maintainers; [ bluescreen303 phreedom AndersonTorres fuuzetsu fpletz ]; - }; -} -- cgit v1.2.3 From 41841469b36bf26cafaa6741fdcb9a0c36982dc3 Mon Sep 17 00:00:00 2001 From: lassulus Date: Tue, 9 May 2017 21:38:45 +0200 Subject: news: init at 1.0.0 --- krebs/5pkgs/haskell-overrides/news.nix | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 krebs/5pkgs/haskell-overrides/news.nix (limited to 'krebs/5pkgs') diff --git a/krebs/5pkgs/haskell-overrides/news.nix b/krebs/5pkgs/haskell-overrides/news.nix new file mode 100644 index 000000000..ba5e7a5e1 --- /dev/null +++ b/krebs/5pkgs/haskell-overrides/news.nix @@ -0,0 +1,18 @@ +{ mkDerivation, base, bloomfilter, bytestring, feed, fetchgit, lens +, stdenv, wreq +}: +mkDerivation { + pname = "news"; + version = "1.0.0"; + src = fetchgit { + url = "http://cgit.lassul.us/news"; + sha256 = "1n3ffr2a5irr5aly0y7qsafag3kxvyyh077ayk0vdwbd0s9hvnjs"; + rev = "c3eb2c0a1a34fc41e18d0bc99b1c4dc73aa6eb20"; + }; + isLibrary = false; + isExecutable = true; + executableHaskellDepends = [ + base bloomfilter bytestring feed lens wreq + ]; + license = stdenv.lib.licenses.mit; +} -- cgit v1.2.3