lense 0.3.4 → 0.3.5
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.
- checksums.yaml +4 -4
- data/lib/lense.rb +18 -9
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 642ab2773ac88e2bdb4611728d7aacbb5d86d28f
|
4
|
+
data.tar.gz: 5f0dda0541b7e275e40cd0e92b5ae846f9e8096c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a9cd873d9a086d5ebe96bdf124eff6981f5fcc606032ecd79a0118f6942730bdd2cf60249061a725cbaf4de5346fc611633af821e12967689c15e104f1c244e0
|
7
|
+
data.tar.gz: 66514ee20f80fd94d403d09ad3d0bebaf34df6c4ad73231d528e343344146739e53918d1834ac795ea697781bf5058af94fc4b9029fde44c73f8471c3a74f4df
|
data/lib/lense.rb
CHANGED
@@ -8,7 +8,7 @@ require 'psych'
|
|
8
8
|
class LENSE
|
9
9
|
attr_reader :config, :current_course, :lense_file_hash
|
10
10
|
|
11
|
-
VERSION = '0.3.
|
11
|
+
VERSION = '0.3.5'
|
12
12
|
LENSE_DIR = File.join(ENV['HOME'],'.lense')
|
13
13
|
COURSES_DIR = File.join(LENSE_DIR,'courses')
|
14
14
|
CURRENT_COURSE_FILE = File.join(LENSE_DIR,'current_course')
|
@@ -149,16 +149,25 @@ class LENSE
|
|
149
149
|
end
|
150
150
|
|
151
151
|
rows = @DB.execute 'select path from dependencies where not deleted;'
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
path
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
152
|
+
rows.map! do |row|
|
153
|
+
path = row[0]
|
154
|
+
{
|
155
|
+
path: path,
|
156
|
+
hash: hash_file(path),
|
157
|
+
}
|
158
|
+
end
|
159
|
+
files = rows.select do |file|
|
160
|
+
dependency = get_dependency(file[:path])
|
161
|
+
hash = hash_file(file[:path])
|
162
|
+
hash != dependency[:file_hash]
|
160
163
|
end
|
161
164
|
|
165
|
+
if files.length > 0
|
166
|
+
say "\nUnstaged Modified Files:\n"
|
167
|
+
end
|
168
|
+
files.each do |file|
|
169
|
+
say "\t<%= color('Modified: #{file[:path]}',:red) %>"
|
170
|
+
end
|
162
171
|
end
|
163
172
|
|
164
173
|
def commit(msg)
|