aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/app/Utils/PromptMessage.hs
diff options
context:
space:
mode:
authorEgor Tensin <Egor.Tensin@gmail.com>2017-06-11 05:56:10 +0300
committerEgor Tensin <Egor.Tensin@gmail.com>2017-06-11 05:56:10 +0300
commit837e60b9d8826168896ad4155ff7046f00665f52 (patch)
tree18c40efee9f38954079119587d3b60ababf5e555 /app/Utils/PromptMessage.hs
parentdelenv: ignore missing variables (diff)
downloadwindows-env-837e60b9d8826168896ad4155ff7046f00665f52.tar.gz
windows-env-837e60b9d8826168896ad4155ff7046f00665f52.zip
WindowsEnv: {VarName,VarValue} -> {Name,Value}
Also, fix compiler warnings (I've got too used to building with `--ghc-options -w`).
Diffstat (limited to 'app/Utils/PromptMessage.hs')
-rw-r--r--app/Utils/PromptMessage.hs12
1 files changed, 6 insertions, 6 deletions
diff --git a/app/Utils/PromptMessage.hs b/app/Utils/PromptMessage.hs
index 1315b85..609cb8f 100644
--- a/app/Utils/PromptMessage.hs
+++ b/app/Utils/PromptMessage.hs
@@ -15,24 +15,24 @@ import Text.Printf (printf)
import qualified WindowsEnv
-oldNewMessage :: WindowsEnv.Profile -> WindowsEnv.VarName -> WindowsEnv.VarValue -> WindowsEnv.VarValue -> String
+oldNewMessage :: WindowsEnv.Profile -> WindowsEnv.Name -> WindowsEnv.Value -> WindowsEnv.Value -> String
oldNewMessage profile name oldValue newValue =
descrMsg ++ oldValueMsg ++ newValueMsg
where
profileKey = WindowsEnv.profileKeyPath profile
descrMsg = printf "Saving variable '%s' to '%s'...\n" name $ show profileKey
- oldValueMsg = printf "\tOld value: %s\n" $ WindowsEnv.varValueString oldValue
- newValueMsg = printf "\tNew value: %s\n" $ WindowsEnv.varValueString newValue
+ oldValueMsg = printf "\tOld value: %s\n" $ WindowsEnv.valueString oldValue
+ newValueMsg = printf "\tNew value: %s\n" $ WindowsEnv.valueString newValue
-newMessage :: WindowsEnv.Profile -> WindowsEnv.VarName -> WindowsEnv.VarValue -> String
+newMessage :: WindowsEnv.Profile -> WindowsEnv.Name -> WindowsEnv.Value -> String
newMessage profile name newValue =
descrMsg ++ newValueMsg
where
profileKey = WindowsEnv.profileKeyPath profile
descrMsg = printf "Saving variable '%s' to '%s'...\n" name $ show profileKey
- newValueMsg = printf "\tNew value: %s\n" $ WindowsEnv.varValueString newValue
+ newValueMsg = printf "\tNew value: %s\n" $ WindowsEnv.valueString newValue
-wipeMessage :: WindowsEnv.Profile -> WindowsEnv.VarName -> String
+wipeMessage :: WindowsEnv.Profile -> WindowsEnv.Name -> String
wipeMessage profile name =
printf "Deleting variable '%s' from '%s'...\n" name $ show profileKey
where