diff options
Diffstat (limited to 'Assistant/Ssh.hs')
-rw-r--r-- | Assistant/Ssh.hs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/Assistant/Ssh.hs b/Assistant/Ssh.hs index fa481a186..7b82f4624 100644 --- a/Assistant/Ssh.hs +++ b/Assistant/Ssh.hs @@ -233,8 +233,7 @@ genSshKeyPair = withTmpDir "git-annex-keygen" $ \dir -> do setupSshKeyPair :: SshKeyPair -> SshData -> IO SshData setupSshKeyPair sshkeypair sshdata = do sshdir <- sshDir - createDirectoryIfMissing True $ - takeDirectory $ sshdir </> sshprivkeyfile + createDirectoryIfMissing True $ parentDir $ sshdir </> sshprivkeyfile unlessM (doesFileExist $ sshdir </> sshprivkeyfile) $ writeFileProtected (sshdir </> sshprivkeyfile) (sshPrivKey sshkeypair) |