motion-swifty 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/motion/swifty/swifty.rb +5 -13
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 813fa05d52f83aab5b418daa5d3a63ffbbfb895b
4
- data.tar.gz: c4e2d8c746d3c5862833e5a041efd78dad2abb51
3
+ metadata.gz: e821e34adc1c71ff3836239bf74fa2a4618a04d0
4
+ data.tar.gz: fb3b488b4875f87831d231c262bbea3d8e7f3d87
5
5
  SHA512:
6
- metadata.gz: b7fd61b1a1ae5fea2a1e25c48a8939d35f8d2ff0c99d63c0bf2f507c2b1653656c98a4062349c8db83b6185ec32914af3bf3ebb1bcb36dd87bd5edea05d9be57
7
- data.tar.gz: d2d9aeff083df3fcb769ab6d8a42ea9313a7d32af9938a8160e660802dc6dfe5d86797cfbe00e0ac469bcade8e2c9fb06cfff201b7ec532532558200b7377239
6
+ metadata.gz: 69cd9deb09df051f06726534e75d1a6f7ec680971607284f0bb584d01c7086a84670ab702fc82a8d435f3c864d67d9535740ed01d40d91b7ba79e2a5b30d2bdc
7
+ data.tar.gz: 7af111dd7c5b80ddeaf0df38eabec981c22ac6972d4ce9e1132eabd82fd01a9bb4f96c05ff2aeb91e42ba4b2968339b0a762eb8a3e0c69baf437a12d0e203ec0
@@ -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
- bundle = Shellwords.escape("./vendor/Carts/#{archs}")
97
- `#{swift_stdlib_tool} --print --scan-folder #{bundle} --platform #{platform.downcase}`.split
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
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: motion-swifty
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joffrey JAFFEUX