lense 0.1.49 → 0.1.50

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/bin/lense +6 -0
  3. data/lib/lense.rb +2 -6
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 84e8c0e3a1bebc03b2640eb99a7a0a1e82af65d8
4
- data.tar.gz: 99ac8fd56e360cdeb2727e6d0b92c6e97a4b0787
3
+ metadata.gz: 6d9d715b6fd1d4872b5dfe5a5616351823acc539
4
+ data.tar.gz: 77f0f7a18717cdc4560e47cd5e2a9c21be7e22f1
5
5
  SHA512:
6
- metadata.gz: adb9c947f36f051a5f9ac82ee9915b06697865fa68f06ff41afeafc915687249092ee21b1b6d3edc4426716de6aa0ebd34372332df05981f035ac536ec20dae6
7
- data.tar.gz: 08d23874e642ac36511d5c8f4c091f0b9debd3cb98762ff0ad57abdf2170219d019b7280e58f8820dd09f6b51057f21b445a994d23b3583dad3532b321babf28
6
+ metadata.gz: 59f48076b9ea0933ebd55a8419b9a8f0578946e70f4aaca4fc7277b495fb63f9bfaa6ed3cfdea6ab007526007c6483b1fef7b87474dc97cfe3abe3403bab5d8f
7
+ data.tar.gz: 0ce003889baafea0885bdc0ad94b41d1a659d6d6d64c0d10cfa97795a037f3c0af67dc6859e64328826aa15016cc308431786afe73a551b57481bd15f39f0345
data/bin/lense CHANGED
@@ -123,4 +123,10 @@ command :unstage do |c|
123
123
  end
124
124
  end
125
125
 
126
+ command :log do |c|
127
+ c.action do
128
+ LENSE_APP.get_commit_log
129
+ end
130
+ end
131
+
126
132
  exit run(ARGV)
data/lib/lense.rb CHANGED
@@ -6,7 +6,7 @@ require 'sqlite3'
6
6
  class LENSE
7
7
  attr_reader :config, :current_course, :lense_file_hash
8
8
 
9
- VERSION = '0.1.49'
9
+ VERSION = '0.1.50'
10
10
  LENSE_DIR = File.join(ENV['HOME'],'.lense')
11
11
  COURSES_DIR = File.join(LENSE_DIR,'courses')
12
12
  CURRENT_COURSE_FILE = File.join(LENSE_DIR,'current_course')
@@ -195,18 +195,15 @@ class LENSE
195
195
  def stage(file)
196
196
  if File.file?(file)
197
197
  dependency = get_dependency(file)
198
- say "Dependency: #{dependency}"
199
198
  if dependency.nil?
200
- say "dependency is nil so we're staging"
201
199
  should_stage = true
202
200
  else
203
201
  current_hash = hash_file(file)
202
+
204
203
  # is it modified?
205
204
  if dependency[:file_hash] == current_hash
206
- say "Not Staging because we've seen this file"
207
205
  should_stage = false
208
206
  else
209
- say "Staging because we haven't seen this revision"
210
207
  should_stage = true
211
208
  end
212
209
  end
@@ -217,7 +214,6 @@ class LENSE
217
214
  @DB.execute "insert into staging (path) values (?);", file
218
215
  @DB.commit
219
216
  rescue
220
- say "File already staged!"
221
217
  end
222
218
  end
223
219
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lense
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.49
4
+ version: 0.1.50
5
5
  platform: ruby
6
6
  authors:
7
7
  - Manuel Zubieta