save_me 1.0.2 → 1.0.3

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 94b459381452701de5d6cdc73fe022dc311df872
4
- data.tar.gz: 08ef6b7db47d99214022b0c70eef5af97d31ff71
3
+ metadata.gz: d86492ef37c6329035c3aa08b7d418e6ec6ebca8
4
+ data.tar.gz: 60441e0345b8207289856fad2d8207564e0ddb24
5
5
  SHA512:
6
- metadata.gz: 73c5f35ff29686e9c632719dffe622eff58042e082ffcacc8f4d7acc01f3d28e3c32e948ff5804482eb49c9f0eaf499710e93445a804b16f127fb7ccf3bfa0a3
7
- data.tar.gz: f82610098ba1d05c2440cac14761d35feed4658923b070144d7cfc654ce2f23d45316839ed08be7251addfc767a6b2f0b0bccf88d12cb53eac8a9076f3cc42f9
6
+ metadata.gz: 387197c29ed05b277fa6da22f7520343e741b3c56546f3ad0ab8cf54fa303bba1a11959f50dc8eef3a6b37a79f8f111ab641bd3afe013287920609b2c55a5497
7
+ data.tar.gz: 00388664731a7181685ce90c92b52b51bf33e602cfa896b1116f4eeffa96565318dfcb3c5ac97e37b12174895e565b23d683821b3105b6cde95c14ed2a6f8ef5
@@ -15,18 +15,18 @@ class PathGenerator
15
15
  end
16
16
 
17
17
  def call
18
- produce_path + produce_dirname
18
+ File.join(produce_path, produce_dirname)
19
19
  end
20
20
 
21
21
  private
22
22
 
23
23
  def produce_path
24
- str = results_path
25
- str += "/" unless results_path[-1] == "/"
26
- str += "#{timestamp.year}/" if year
27
- str += "#{timestamp.month}/" if month
28
- str += "#{timestamp.day}/" if day
29
- str
24
+ parts = []
25
+ parts.push(results_path)
26
+ parts.push(timestamp.year.to_s) if year
27
+ parts.push(timestamp.month.to_s) if month
28
+ parts.push(timestamp.day.to_s) if day
29
+ File.join(*parts)
30
30
  end
31
31
 
32
32
  def produce_dirname
@@ -34,7 +34,7 @@ class PathGenerator
34
34
  str += "%Y_" unless year
35
35
  str += "%m_" unless month
36
36
  str += "%d_" unless day
37
- str += "%H:%M:%S"
37
+ str += "%H-%M-%S"
38
38
  timestamp.strftime(str)
39
39
  end
40
40
  end
@@ -1,3 +1,3 @@
1
1
  class SaveMe
2
- VERSION = "1.0.2"
2
+ VERSION = "1.0.3"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: save_me
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michał Januszkiewicz
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-04-03 00:00:00.000000000 Z
11
+ date: 2017-04-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler