alfi 0.2.1 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/alfi.gemspec +1 -1
- data/lib/alfi.rb +33 -14
- data/lib/alfi/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 0bc82c723112ac0a4ae1814ef9aa80d224e333ac
|
4
|
+
data.tar.gz: eae368210dba65d6fcc118a9c52aa357f9dd317f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 292089d2e44f4911c196c342eebd411832055a5f09ee59ec2f5cf5779f26152d7390e093733ad8a944b259ceaec15d1b6c0e566a10e686b2939002047b5f719b
|
7
|
+
data.tar.gz: f5421b9330b0743bbf26272397df0eac9208dd1c911633102bb637b5b4965b6c1a2b57955c7d45227ae7000fe679a98bb1df25fac96103710c5f329c08490cef
|
data/alfi.gemspec
CHANGED
@@ -14,7 +14,7 @@ Gem::Specification.new do |spec|
|
|
14
14
|
end
|
15
15
|
|
16
16
|
spec.summary = 'Android Library Finder'
|
17
|
-
spec.description = '
|
17
|
+
spec.description = 'Android Library Finder to search through thousands of android libraries that can help you scale your projects elegantly.'
|
18
18
|
spec.homepage = "https://github.com/cesarferreira/alfi"
|
19
19
|
spec.license = 'MIT'
|
20
20
|
|
data/lib/alfi.rb
CHANGED
@@ -38,6 +38,9 @@ module Alfi
|
|
38
38
|
# Init the result list
|
39
39
|
result_list = Array.new
|
40
40
|
|
41
|
+
# query google reps
|
42
|
+
result_list = query_offline_reps(query)
|
43
|
+
|
41
44
|
# Iterate the libraries
|
42
45
|
result['response']['docs'].each do |doc|
|
43
46
|
output = " compile '#{doc['id']}:#{doc['latestVersion']}'"
|
@@ -50,23 +53,39 @@ module Alfi
|
|
50
53
|
end
|
51
54
|
end
|
52
55
|
|
56
|
+
# QUERY OFFLINE REPOSITORIES (google)
|
53
57
|
def self.query_offline_reps(query)
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
58
|
+
|
59
|
+
google_libs = Array.new
|
60
|
+
google_libs << 'com.android.support:appcompat-v7'
|
61
|
+
google_libs << 'com.android.support:cardview-v7'
|
62
|
+
google_libs << 'com.android.support:gridlayout-v7'
|
63
|
+
google_libs << 'com.android.support:leanback-v17'
|
64
|
+
google_libs << 'com.android.support:mediarouter-v7'
|
65
|
+
google_libs << 'com.android.support:palette-v7'
|
66
|
+
google_libs << 'com.android.support:recyclerview-v7'
|
67
|
+
google_libs << 'com.android.support:support-annotations'
|
68
|
+
google_libs << 'com.android.support:support-v4'
|
69
|
+
google_libs << 'com.android.support:support-v13'
|
70
|
+
google_libs << 'com.google.android.gms:play-services-wearable'
|
71
|
+
google_libs << 'com.google.android.gms:play-services'
|
72
|
+
|
73
|
+
|
74
|
+
found_libs = Array.new
|
75
|
+
|
76
|
+
# is there anything?
|
77
|
+
google_libs.each do |lib|
|
78
|
+
|
79
|
+
if lib.include?(query)
|
80
|
+
found_libs << " compile '#{lib}:+'"
|
81
|
+
end
|
82
|
+
end
|
83
|
+
|
84
|
+
return found_libs
|
85
|
+
|
68
86
|
end
|
69
87
|
|
88
|
+
# INIT
|
70
89
|
def self.initialize (param)
|
71
90
|
|
72
91
|
if param == nil
|
data/lib/alfi/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: alfi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- cesar ferreira
|
@@ -94,8 +94,8 @@ dependencies:
|
|
94
94
|
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0.7'
|
97
|
-
description:
|
98
|
-
your projects elegantly.
|
97
|
+
description: Android Library Finder to search through thousands of android libraries
|
98
|
+
that can help you scale your projects elegantly.
|
99
99
|
email:
|
100
100
|
- cesar.manuel.ferreira@gmail.com
|
101
101
|
executables:
|