Move repository to a private directory
This commit is contained in:
parent
8e580e3dad
commit
c6db44ace7
2 changed files with 4 additions and 3 deletions
|
|
@ -11,13 +11,14 @@ import UIKit
|
||||||
|
|
||||||
class Globals {
|
class Globals {
|
||||||
static let documentPath = NSSearchPathForDirectoriesInDomains(.documentDirectory, .userDomainMask, true)[0];
|
static let documentPath = NSSearchPathForDirectoriesInDomains(.documentDirectory, .userDomainMask, true)[0];
|
||||||
|
static let libraryPath = NSSearchPathForDirectoriesInDomains(.libraryDirectory, .userDomainMask, true)[0];
|
||||||
static let pgpPublicKeyPath = "\(documentPath)/gpg_key.pub"
|
static let pgpPublicKeyPath = "\(documentPath)/gpg_key.pub"
|
||||||
static let pgpPrivateKeyPath = "\(documentPath)/gpg_key"
|
static let pgpPrivateKeyPath = "\(documentPath)/gpg_key"
|
||||||
|
|
||||||
static let sshPublicKeyURL = URL(fileURLWithPath: "\(documentPath)/ssh_key.pub")
|
static let sshPublicKeyURL = URL(fileURLWithPath: "\(documentPath)/ssh_key.pub")
|
||||||
static let sshPrivateKeyURL = URL(fileURLWithPath: "\(documentPath)/ssh_key")
|
static let sshPrivateKeyURL = URL(fileURLWithPath: "\(documentPath)/ssh_key")
|
||||||
|
|
||||||
static let repositoryPath = "\(documentPath)/password-store"
|
static let repositoryPath = "\(libraryPath)/password-store"
|
||||||
static var passcodeConfiguration = PasscodeLockConfiguration()
|
static var passcodeConfiguration = PasscodeLockConfiguration()
|
||||||
static let version = Bundle.main.infoDictionary?["CFBundleShortVersionString"] as! String
|
static let version = Bundle.main.infoDictionary?["CFBundleShortVersionString"] as! String
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -96,8 +96,8 @@ struct GitCredential {
|
||||||
class PasswordStore {
|
class PasswordStore {
|
||||||
static let shared = PasswordStore()
|
static let shared = PasswordStore()
|
||||||
|
|
||||||
let storeURL = URL(fileURLWithPath: "\(Globals.documentPath)/password-store")
|
let storeURL = URL(fileURLWithPath: "\(Globals.repositoryPath)")
|
||||||
let tempStoreURL = URL(fileURLWithPath: "\(Globals.documentPath)/password-store-temp")
|
let tempStoreURL = URL(fileURLWithPath: "\(Globals.repositoryPath)-temp")
|
||||||
var storeRepository: GTRepository?
|
var storeRepository: GTRepository?
|
||||||
var gitCredential: GitCredential?
|
var gitCredential: GitCredential?
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue