motion-swifty 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/motion/swifty/swifty.rb +5 -13
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e821e34adc1c71ff3836239bf74fa2a4618a04d0
|
4
|
+
data.tar.gz: fb3b488b4875f87831d231c262bbea3d8e7f3d87
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 69cd9deb09df051f06726534e75d1a6f7ec680971607284f0bb584d01c7086a84670ab702fc82a8d435f3c864d67d9535740ed01d40d91b7ba79e2a5b30d2bdc
|
7
|
+
data.tar.gz: 7af111dd7c5b80ddeaf0df38eabec981c22ac6972d4ce9e1132eabd82fd01a9bb4f96c05ff2aeb91e42ba4b2968339b0a762eb8a3e0c69baf437a12d0e203ec0
|
data/lib/motion/swifty/swifty.rb
CHANGED
@@ -26,7 +26,7 @@ module MotionSwifty
|
|
26
26
|
frameworks = File.join(self.config.app_bundle(platform), "Frameworks")
|
27
27
|
update_swift_dlybs("./Cartfile", frameworks) do
|
28
28
|
clean_swift_dlybs(frameworks)
|
29
|
-
copy_swift_dlybs(platform)
|
29
|
+
copy_swift_dlybs(platform, frameworks)
|
30
30
|
end
|
31
31
|
|
32
32
|
self.config.embedded_frameworks += self.carts.map(&:path)
|
@@ -81,20 +81,12 @@ module MotionSwifty
|
|
81
81
|
target.close
|
82
82
|
end
|
83
83
|
|
84
|
-
def copy_swift_dlybs(platform)
|
85
|
-
dlybs = list_swift_dlybs(platform)
|
86
|
-
frameworks_path = File.join(File.dirname(self.config.app_bundle_executable(platform)), "Frameworks")
|
87
|
-
FileUtils.mkdir_p(frameworks_path)
|
88
|
-
dlybs.each do |dlyb|
|
89
|
-
FileUtils.cp(dlyb, frameworks_path)
|
90
|
-
end
|
91
|
-
end
|
92
|
-
|
93
|
-
def list_swift_dlybs(platform)
|
84
|
+
def copy_swift_dlybs(platform, frameworks_path)
|
94
85
|
swift_stdlib_tool = "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/swift-stdlib-tool"
|
95
86
|
archs = self.config.archs[platform].join(' ')
|
96
|
-
|
97
|
-
|
87
|
+
folder = Shellwords.escape("./vendor/Carts/#{archs}")
|
88
|
+
frameworks_path = Shellwords.escape(frameworks_path)
|
89
|
+
`#{swift_stdlib_tool} --copy --scan-folder #{folder} --platform #{platform.downcase} --destination #{frameworks_path}`
|
98
90
|
end
|
99
91
|
end
|
100
92
|
end
|