done_log 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fa9087eac5309de9a13842028ba9d4414a31019914c288a4f6708b20a77fe12e
4
- data.tar.gz: c95a79c7b8a1ebc63f831829f387d509f3872004b78defc139e84f985cddacd0
3
+ metadata.gz: 27620eafb4727836ef49360f829764c17699b1f855fee52dcbcae678974a79c7
4
+ data.tar.gz: fbdf43c0515f6feb00e5c597ea4eb3f4f654a013546d1cf233023eca7b0a8c5d
5
5
  SHA512:
6
- metadata.gz: 50203c3aafcd8719de41afda937b5859bd6b27d730d9688b57dd291e03a411b351c975ec124fe6d415af707a4bf9702053b27a6d8218b282a99aa1a9afe0370a
7
- data.tar.gz: a4471793fc7b925e611957c8b81c28c77771c4ac42377e2b21202d2096c7d9fe51272be5029bbd409affa00a153d17a9bea0f4f081b10b33fc08d08d3fc1ab13
6
+ metadata.gz: 5db81a96f050e067ad75cca8427de6e3a0a9c557ff55538dbc142eae3e672076adac92713140b1a0a1a90c4c9cfdd8427aa66ebb28bec1fcdeaa1487c452e655
7
+ data.tar.gz: ab724bbe01e3a664a1120428da12f9dd6cd42a3ea05763edc731afaf1aa2d20f627691347c522ee856a7d10e2f1c9f1677b152475087abae20173e8ee39fa719
@@ -58,8 +58,9 @@ module Done
58
58
  end
59
59
 
60
60
  def ensure_directory
61
- FileUtils.mkdir_p(File.dirname(log_file))
61
+ FileUtils.mkdir_p(dir)
62
62
  git.init
63
+ FileUtils.mkdir_p(File.dirname(log_file))
63
64
  end
64
65
 
65
66
  def create_log
@@ -31,10 +31,12 @@ module Done
31
31
  end
32
32
 
33
33
  def init
34
- if git_url and not Dir.exist? log_dir
35
- run "git clone -q #{git_url} #{log_dir}"
36
- else
37
- run "git init -q #{log_dir}"
34
+ unless Dir.exist? File.join(log_dir, ".git")
35
+ if git_url
36
+ run "git clone -q #{git_url} #{log_dir}"
37
+ else
38
+ run "git init -q #{log_dir}"
39
+ end
38
40
  end
39
41
  end
40
42
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: done_log
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justin Collins
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-01 00:00:00.000000000 Z
11
+ date: 2020-04-06 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Manage very simple daily work logs in text files.
14
14
  email: