import Foundation let env = ProcessInfo.processInfo.environment let manager = FileManager.default let fileNakami = "...." if let pathValue = env["XcodeProjectPath"] as? String{ var fileURL = URL(fileURLWithPath: pathValue) fileURL.appendPathComponent(".xcodesamplecode.plist") try! fileNakami.write(to: fileURL, atomically: true, encoding: String.Encoding.utf8) } https://gist.github.com/TachibanaKaoru/ 4ffa5dda9b86b4f0ef1a02e064ba34e9