File tree 1 file changed +19
-0
lines changed
Plugins/PackageToJS/Tests
1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -73,6 +73,25 @@ extension Trait where Self == ConditionTrait {
73
73
enumerator. skipDescendants ( )
74
74
continue
75
75
}
76
+
77
+ // Copy symbolic links
78
+ if let resourceValues = try ? sourcePath. resourceValues ( forKeys: [ . isSymbolicLinkKey] ) ,
79
+ resourceValues. isSymbolicLink == true
80
+ {
81
+ try FileManager . default. createDirectory (
82
+ at: destinationPath. deletingLastPathComponent ( ) ,
83
+ withIntermediateDirectories: true ,
84
+ attributes: nil
85
+ )
86
+ let linkDestination = try ! FileManager . default. destinationOfSymbolicLink ( atPath: sourcePath. path)
87
+ try FileManager . default. createSymbolicLink (
88
+ atPath: destinationPath. path,
89
+ withDestinationPath: linkDestination
90
+ )
91
+ enumerator. skipDescendants ( )
92
+ continue
93
+ }
94
+
76
95
// Skip directories
77
96
var isDirectory : ObjCBool = false
78
97
if FileManager . default. fileExists ( atPath: sourcePath. path, isDirectory: & isDirectory) {
You can’t perform that action at this time.
0 commit comments