1
0
mirror of https://github.com/nicoverbruggen/phpmon.git synced 2025-11-09 13:10:24 +01:00

👌 Path based on architecture (#134)

This commit is contained in:
2022-02-11 18:58:07 +01:00
parent 6187eb3e4e
commit dc91d0e00c
6 changed files with 61 additions and 29 deletions

View File

@@ -15,15 +15,15 @@ public class Paths {
public static let shared = Paths()
private var baseDir : Paths.HomebrewDir
internal var baseDir : Paths.HomebrewDir
private var userName : String
init() {
baseDir = FileManager.default.fileExists(atPath: "\(HomebrewDir.opt.rawValue)/bin/brew") ? .opt : .usr
baseDir = App.architecture != "x86_64" ? .opt : .usr
userName = String(Shell.pipe("whoami").split(separator: "\n")[0])
}
// - MARK: Binaries
public static var valet: String {