Skip to content

Commit

Permalink
use motion-gradle for dependency management
Browse files Browse the repository at this point in the history
  • Loading branch information
gregmolnar committed Dec 23, 2017
1 parent 575ac20 commit d753cc1
Show file tree
Hide file tree
Showing 1,009 changed files with 75 additions and 15,819 deletions.
2 changes: 2 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
source 'https://rubygems.org'
gemspec
21 changes: 21 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
PATH
remote: .
specs:
motion-flow (0.1.9)
motion-gradle

GEM
remote: https://rubygems.org/
specs:
motion-gradle (2.1.0)
rake (12.3.0)

PLATFORMS
ruby

DEPENDENCIES
motion-flow!
rake

BUNDLED WITH
1.16.0
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,12 @@ Flow is currently composed of the following libraries:
$ gem install motion-flow
```

If you are targeting Android, you need to install the dependencies with Gradle:

```
$ bundle && rake android:gradle:install
```

### Projects

#### Flow projects
Expand Down
13 changes: 8 additions & 5 deletions lib/android.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

$:.unshift("/Library/RubyMotion/lib")
require 'motion/project/template/android'
require 'motion-gradle'

Motion::Project::App.setup do |app|
app.api_version = '23' unless Motion::Project::Config.starter?
Expand Down Expand Up @@ -34,12 +35,14 @@
application['android:theme'] = '@style/Theme.AppCompat.Light'
end

vendor_dir = File.join(File.dirname(__FILE__), '../vendor/android')
v7_app_compat_dir = File.join(vendor_dir, 'support/v7/appcompat')
app.vendor_project(:jar => File.join(v7_app_compat_dir, "/libs/android-support-v4.jar"))
app.vendor_project(:jar => File.join(v7_app_compat_dir, "/libs/android-support-v7-appcompat.jar"), :resources => File.join(v7_app_compat_dir, "/res"), :manifest => File.join(v7_app_compat_dir, "/AndroidManifest.xml"))
app.gradle do
repository 'https://maven.google.com'
dependency 'com.android.support:appcompat-v7:24.2.1'
dependency 'com.android.support:support-v4:24.2.1'
dependency 'com.google.android.gms:play-services-vision:11.8.0'
dependency 'com.google.android.gms:play-services-vision-common:11.8.0'
end

app.vendor_project(:jar => File.join(vendor_dir, 'google-play-services_lib/libs/google-play-services.jar'), :filter => ['^.com.google.android.gms.vision'], :resources => File.join(vendor_dir, 'google-play-services_lib/res'), :manifest => File.join(vendor_dir, 'google-play-services_lib/AndroidManifest.xml'))
app.manifest_entry('application', 'meta-data', :name => 'com.google.android.gms.version', :value => '@integer/google_play_services_version')
app.manifest_entry('application', 'meta-data', :name => 'com.google.android.gms.vision.DEPENDENCIES', :value => 'barcode')
end
4 changes: 4 additions & 0 deletions lib/motion-flow.rb
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,10 @@ def invoke_rake(platform, task)
task "spec:emulator" do
invoke_rake 'android', 'spec:emulator'
end
desc "Download and build dependencies"
task "gradle:install" do
invoke_rake 'android', 'gradle:install'
end
end
namespace 'osx' do
desc "Build the project for development"
Expand Down
2 changes: 2 additions & 0 deletions motion-flow.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,6 @@ Gem::Specification.new do |spec|
Dir.glob('template/**/*') +
Dir.glob('vendor/**/*')
spec.metadata = { "rubymotion_template_dir" => "template" }
spec.add_development_dependency 'rake'
spec.add_dependency 'motion-gradle'
end
5 changes: 5 additions & 0 deletions samples/reddit/Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
source 'https://rubygems.org'

gem 'rake'
gem 'motion-flow', path: '../../'
# Add your dependencies here:
21 changes: 21 additions & 0 deletions samples/reddit/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
PATH
remote: ../..
specs:
motion-flow (0.1.9)
motion-gradle

GEM
remote: https://rubygems.org/
specs:
motion-gradle (2.1.0)
rake (12.3.0)

PLATFORMS
ruby

DEPENDENCIES
motion-flow!
rake

BUNDLED WITH
1.16.0
1 change: 1 addition & 0 deletions samples/ui_demo/Gemfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
source 'https://rubygems.org'

gem 'rake'
gem 'motion-flow', path: '../../'
# Add your dependencies here:
8 changes: 5 additions & 3 deletions samples/ui_demo/Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,11 +1,13 @@
PATH
remote: ..
remote: ../..
specs:
motion-flow (0.2)
motion-flow (0.1.9)
motion-gradle

GEM
remote: https://rubygems.org/
specs:
motion-gradle (2.1.0)
rake (10.5.0)

PLATFORMS
Expand All @@ -16,4 +18,4 @@ DEPENDENCIES
rake

BUNDLED WITH
1.11.2
1.16.0
8 changes: 0 additions & 8 deletions vendor/android/google-play-services_lib/.classpath

This file was deleted.

26 changes: 0 additions & 26 deletions vendor/android/google-play-services_lib/AndroidManifest.xml

This file was deleted.

17 changes: 0 additions & 17 deletions vendor/android/google-play-services_lib/README.txt

This file was deleted.

Binary file not shown.

This file was deleted.

35 changes: 0 additions & 35 deletions vendor/android/google-play-services_lib/proguard.txt

This file was deleted.

15 changes: 0 additions & 15 deletions vendor/android/google-play-services_lib/project.properties

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.
Diff not rendered.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading

0 comments on commit d753cc1

Please sign in to comment.