From 899f84a217681833146fadd8f30cd25ed1a9f653 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Tue, 10 Jun 2014 19:20:14 -0400 Subject: export CreateProcess fields from Utility.Process update code to avoid cwd and env redefinition warnings --- Command/Status.hs | 4 ++-- Command/Uninit.hs | 4 ++-- Command/WebApp.hs | 1 - 3 files changed, 4 insertions(+), 5 deletions(-) (limited to 'Command') diff --git a/Command/Status.hs b/Command/Status.hs index cd6c25983..9d184c33b 100644 --- a/Command/Status.hs +++ b/Command/Status.hs @@ -28,9 +28,9 @@ start :: [FilePath] -> CommandStart start [] = do -- Like git status, when run without a directory, behave as if -- given the path to the top of the repository. - cwd <- liftIO getCurrentDirectory + currdir <- liftIO getCurrentDirectory top <- fromRepo Git.repoPath - start' [relPathDirToFile cwd top] + start' [relPathDirToFile currdir top] start locs = start' locs start' :: [FilePath] -> CommandStart diff --git a/Command/Uninit.hs b/Command/Uninit.hs index 0f0628156..76022df26 100644 --- a/Command/Uninit.hs +++ b/Command/Uninit.hs @@ -27,8 +27,8 @@ check = do when (b == Annex.Branch.name) $ error $ "cannot uninit when the " ++ Git.fromRef b ++ " branch is checked out" top <- fromRepo Git.repoPath - cwd <- liftIO getCurrentDirectory - whenM ((/=) <$> liftIO (absPath top) <*> liftIO (absPath cwd)) $ + currdir <- liftIO getCurrentDirectory + whenM ((/=) <$> liftIO (absPath top) <*> liftIO (absPath currdir)) $ error "can only run uninit from the top of the git repository" where current_branch = Git.Ref . Prelude.head . lines <$> revhead diff --git a/Command/WebApp.hs b/Command/WebApp.hs index e8d657052..e329582e3 100644 --- a/Command/WebApp.hs +++ b/Command/WebApp.hs @@ -34,7 +34,6 @@ import Annex.Version import Control.Concurrent import Control.Concurrent.STM -import System.Process (env, std_out, std_err, cwd) import Network.Socket (HostName) import System.Environment (getArgs) -- cgit v1.2.3