From 1570336325b7dcac981ad6964148fc7692f4eea9 Mon Sep 17 00:00:00 2001 From: Moritz Ulrich Date: Sun, 16 Jun 2013 23:38:33 +0200 Subject: [PATCH 1/2] Fix dropbox-cli. Dropbox doesn't version the CLI. This broke the download. This patch also fixes the `dropbox-cli start' command. Signed-off-by: Moritz Ulrich --- .../networking/dropbox-cli/default.nix | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/networking/dropbox-cli/default.nix b/pkgs/applications/networking/dropbox-cli/default.nix index b298b3c9df99..936856448694 100644 --- a/pkgs/applications/networking/dropbox-cli/default.nix +++ b/pkgs/applications/networking/dropbox-cli/default.nix @@ -1,17 +1,18 @@ -{ stdenv, coreutils, fetchurl, python }: +{ stdenv, coreutils, fetchurl, python, dropbox }: stdenv.mkDerivation { name = "dropbox-cli"; src = fetchurl { + # Note: dropbox doesn't version this file. Annoying. url = "https://linux.dropbox.com/packages/dropbox.py"; - sha256 = "1x46i0aplah4a2nqglb8byl3c60w7h1cjja62myxj2dpxyv7fydy"; + sha256 = "0p1pg8bw6mlhqi5k8y3pgs7byg0kfvq57s53sh188lb5sxvlg7yz"; }; buildInputs = [ coreutils python ]; phases = "installPhase fixupPhase"; - + installPhase = '' mkdir -pv $out/bin/ cp $src $out/bin/dropbox-cli @@ -20,11 +21,12 @@ stdenv.mkDerivation { fixupPhase = '' substituteInPlace $out/bin/dropbox-cli \ --replace "/usr/bin/python" ${python}/bin/python \ - --replace "use dropbox help" "use dropbox-cli help" - + --replace "use dropbox help" "use dropbox-cli help" \ + --replace "~/.dropbox-dist/dropboxd" ${dropbox}/bin/dropbox + chmod +x $out/bin/dropbox-cli ''; - + meta = { homepage = http://dropbox.com; description = "Command line client for the dropbox daemon."; @@ -33,4 +35,3 @@ stdenv.mkDerivation { platforms = stdenv.lib.platforms.linux; }; } - From edaca7bdf00f905f1cb703d8e3335a315d4d1a0f Mon Sep 17 00:00:00 2001 From: Moritz Ulrich Date: Sun, 16 Jun 2013 23:40:43 +0200 Subject: [PATCH 2/2] Add myself as a maintainer of dropbox-cli. Signed-off-by: Moritz Ulrich --- pkgs/applications/networking/dropbox-cli/default.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/pkgs/applications/networking/dropbox-cli/default.nix b/pkgs/applications/networking/dropbox-cli/default.nix index 936856448694..34fe6db8932b 100644 --- a/pkgs/applications/networking/dropbox-cli/default.nix +++ b/pkgs/applications/networking/dropbox-cli/default.nix @@ -31,6 +31,7 @@ stdenv.mkDerivation { homepage = http://dropbox.com; description = "Command line client for the dropbox daemon."; license = stdenv.lib.licenses.gpl3; + maintainers = with stdenv.lib.maintainers; [ the-kenny ]; # NOTE: Dropbox itself only works on linux, so this is ok. platforms = stdenv.lib.platforms.linux; };