dbt 1.0.7 → 1.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/dbt.rb +13 -5
  3. data/lib/dbt/version.rb +1 -1
  4. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 90c054c1b0261090c98ea7391db813a6cc6bab25
4
- data.tar.gz: 4d82290b822b199920e0c17581261a6919adad6e
3
+ metadata.gz: 1c40e53c7c91ff160d4e91fc4ba663a6f62d9b21
4
+ data.tar.gz: 07ce73b98514dfcf8017a65db1528bffb5557d4d
5
5
  SHA512:
6
- metadata.gz: 27d51152e33295c0d1d0872c79af35baf7c4646803a35971efed302147ad2c0359d3041565fd0573883a4383e29346c116f87861924b14bbc84bef018d5fb8cf
7
- data.tar.gz: 4235ce0b494bd539e18d41c2ec189836990af283be5f35da8c48c296a88e14c6c580df4109d70b7382523402a94d6aa29520030af863735569ac8023ccf8162d
6
+ metadata.gz: fb335d7a65872bdae9f406c4aa54b4d97e3f7fa6f885412d1a09bcfab069c0bf2197779fe8bb526c4ca80b7f2e314e4cf66f3f473dfd07353b54cf7a863beb81
7
+ data.tar.gz: 7c4505eb97f1bf8b54e1abe9fc1be8073c45a1eb456f771f8611645ec98399be71590799d941872d368661bc563c8ac1d8935c50287a0b13f55a94a7887a4e72
data/lib/dbt.rb CHANGED
@@ -1,13 +1,13 @@
1
1
  # coding: utf-8
2
2
 
3
- Motion::Project::App.setup do |app|
4
- def app.analyze
3
+ module DBT
4
+ def analyze(app)
5
5
  debugger_cmds_output = "#------> Creado por el DBT <------#\n"
6
6
  dependers = Hash.new { |hash,key| hash[key] = [] }
7
7
  providers = {}
8
8
 
9
- files.uniq!
10
- files.each do |filename|
9
+ files = app.files.flatten.uniq
10
+ files.flatten.each do |filename|
11
11
  File.open(filename, 'r') do |file|
12
12
  file.each_line do |line|
13
13
  command = false
@@ -50,7 +50,7 @@ Motion::Project::App.setup do |app|
50
50
  puts "\033[1m!NO HAY!\033[0m \033[1;31m#{dep}\033[0m"
51
51
  raise "#{filename} could not find a provider for #{dep}"
52
52
  else
53
- self.files_dependencies filename => dependencies.map{|dep| providers[dep] }
53
+ app.files_dependencies filename => dependencies.map { |dep| providers[dep] }
54
54
  end
55
55
  end
56
56
 
@@ -61,3 +61,11 @@ Motion::Project::App.setup do |app|
61
61
  end
62
62
  end
63
63
  end
64
+
65
+
66
+ Motion::Project::App.setup do |app|
67
+ def app.analyze
68
+ puts("\033[1mcalling `app.analyze` is deprecated. Use DBT.analyze(app) instead (non-polluting)\033[0m")
69
+ DBT.analyze(self)
70
+ end
71
+ end
@@ -1,3 +1,3 @@
1
1
  module DBT
2
- VERSION = '1.0.7'
2
+ VERSION = '1.1.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dbt
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.7
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Colin Thomas-Arnold <colinta@gmail.com>
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-03-29 00:00:00.000000000 Z
11
+ date: 2014-04-18 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: |
14
14
  == DBT (Dependencies and deBugging Tool)