one_inch_punch 0.6.0 → 0.6.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 3eb60aa6b2384759a118ed88ece70238f64c98ca
4
+ data.tar.gz: e6791a8972f450174259af5f4d7a57a778bbd8cc
5
+ SHA512:
6
+ metadata.gz: c710f6622ba2c98343d157c82224fdb2a9b54246ea24447098cef1c3d47082ef89fbd489d9fb5f9ce12da670c6d9b843f4597d2526ce4858517c143ba740cf94
7
+ data.tar.gz: 8cdd78674570de88ae45622485fe621541c5b0ed07e4ba8e53e60a1c40ffab6eb2f12d8bbd6975ba5dbec6402b76d052462158e34bacbd78a3d12ab7a361fdac
data/History.txt CHANGED
@@ -1,3 +1,8 @@
1
+ == 0.6.1 2017-07-10
2
+
3
+ * 1 tiny bugfix:
4
+ * removing timely requirement, since it depends on activesupport and turning a date to a time is pretty easy
5
+
1
6
  == 0.6.0 2012-04-10
2
7
 
3
8
  * 1 minor enhancement:
data/README.md ADDED
@@ -0,0 +1,70 @@
1
+ # one_inch_punch
2
+
3
+ ## Description
4
+
5
+ `one_inch_punch` is meant as a generally data- and interface-compatible alternative
6
+ to Ara T. Howard's `punch` gem. The main benefits will be greater understandability,
7
+ test coverage, and usage outside of merely command-line situations.
8
+
9
+ * Punch: Good enough
10
+ * One-inch punch: Smaller, more effective
11
+
12
+ ## Features/Problems
13
+
14
+ * Can load and write `.punch.yml` data compatibly with Ara's `punch` gem
15
+ * Things you may expect from a time-tracking program, like punching in and out and getting time data
16
+ * The ability to be punched in to multiple projects at once, because double-billing is awesome
17
+ * More, since this is unfinished
18
+
19
+ ## SYNOPSIS:
20
+
21
+ ``` ruby
22
+ require 'punch'
23
+
24
+ Punch.load
25
+ Punch.status('my project') # => 'out'
26
+ Punch.in('my project')
27
+ Punch.status('my project') # => 'in'
28
+ # do some work
29
+ Punch.out('my project')
30
+ Punch.out?('my project') # => true
31
+ Punch.write
32
+ ```
33
+
34
+ or!
35
+
36
+ $ punch in proj
37
+ $ echo 'working, really'
38
+ $ punch out proj
39
+ $ punch status
40
+
41
+ or!
42
+
43
+ ``` ruby
44
+ require 'punch'
45
+
46
+ proj = Punch.new('my project')
47
+ proj.status # => 'out'
48
+ proj.in
49
+ proj.status # => 'in'
50
+ # do some work
51
+ proj.out
52
+ proj.out? # => true
53
+ Punch.write
54
+ ```
55
+
56
+ ## Requirements
57
+
58
+ * A reason to track time
59
+ * Ruby
60
+
61
+ ## Install
62
+
63
+ gem install one_inch_punch
64
+
65
+ ## Thanks
66
+
67
+ * Ara T. Howard, for making `punch` in the first place
68
+ * Kevin Barnes, for the name suggestion
69
+ * Bruce Lee, for having been a bad-ass
70
+ * The Kool-Aid Man, for busting through my wall. Oh yeah!
data/lib/punch/version.rb CHANGED
@@ -2,7 +2,7 @@ class Punch
2
2
  module VERSION #:nodoc:
3
3
  MAJOR = 0
4
4
  MINOR = 6
5
- TINY = 0
5
+ TINY = 1
6
6
 
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
data/lib/punch.rb CHANGED
@@ -4,7 +4,6 @@ $:.unshift(File.dirname(__FILE__)) unless
4
4
  require 'yaml'
5
5
  require 'time'
6
6
  require 'date'
7
- require 'timely'
8
7
  require 'enumerator'
9
8
  require 'punch/core_ext'
10
9
  require 'punch/instance'
@@ -250,7 +249,7 @@ class Punch
250
249
  options[:after] = date
251
250
  options[:before] = date + 1
252
251
  end
253
- [:after, :before].each { |k| options[k] = options[k].at_time(0) if options[k].respond_to?(:at_time) }
252
+ [:after, :before].each { |k| options[k] = options[k].to_time if options[k].respond_to?(:to_time) }
254
253
 
255
254
  options
256
255
  end
data/spec/punch_spec.rb CHANGED
@@ -30,6 +30,7 @@ describe Punch do
30
30
  total: "00:55:17"
31
31
  in: 2008-05-19T11:23:35.00-05:00
32
32
  EOD
33
+ @data.gsub!(/^ /, '')
33
34
  File.stub!(:read).and_return(@data)
34
35
 
35
36
  Punch.instance_eval do
metadata CHANGED
@@ -1,126 +1,86 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: one_inch_punch
3
- version: !ruby/object:Gem::Version
4
- hash: 7
5
- prerelease:
6
- segments:
7
- - 0
8
- - 6
9
- - 0
10
- version: 0.6.0
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.6.1
11
5
  platform: ruby
12
- authors:
6
+ authors:
13
7
  - Yossef Mendelssohn
14
8
  autorequire:
15
9
  bindir: bin
16
10
  cert_chain: []
17
-
18
- date: 2012-04-10 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
11
+ date: 2017-07-10 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
21
14
  name: bacon
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
24
- none: false
25
- requirements:
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
26
17
  - - ">="
27
- - !ruby/object:Gem::Version
28
- hash: 19
29
- segments:
30
- - 1
31
- - 1
32
- - 0
18
+ - !ruby/object:Gem::Version
33
19
  version: 1.1.0
34
20
  type: :development
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: facon
38
21
  prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
40
- none: false
41
- requirements:
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
42
24
  - - ">="
43
- - !ruby/object:Gem::Version
44
- hash: 11
45
- segments:
46
- - 0
47
- - 5
48
- - 0
25
+ - !ruby/object:Gem::Version
26
+ version: 1.1.0
27
+ - !ruby/object:Gem::Dependency
28
+ name: facon
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
49
33
  version: 0.5.0
50
34
  type: :development
51
- version_requirements: *id002
52
- - !ruby/object:Gem::Dependency
53
- name: timely
54
35
  prerelease: false
55
- requirement: &id003 !ruby/object:Gem::Requirement
56
- none: false
57
- requirements:
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
58
38
  - - ">="
59
- - !ruby/object:Gem::Version
60
- hash: 29
61
- segments:
62
- - 0
63
- - 0
64
- - 1
65
- version: 0.0.1
66
- type: :runtime
67
- version_requirements: *id003
39
+ - !ruby/object:Gem::Version
40
+ version: 0.5.0
68
41
  description: A simple time-tracking tool, compatible with Ara T. Howard's punch gem.
69
- email:
42
+ email:
70
43
  - ymendel@pobox.com
71
- executables:
44
+ executables:
72
45
  - punch
73
46
  extensions: []
74
-
75
47
  extra_rdoc_files: []
76
-
77
- files:
78
- - License.txt
48
+ files:
79
49
  - History.txt
80
- - README.txt
81
- - lib/punch/core_ext/fixnum.rb
50
+ - License.txt
51
+ - README.md
52
+ - bin/punch
53
+ - lib/punch.rb
82
54
  - lib/punch/core_ext.rb
55
+ - lib/punch/core_ext/fixnum.rb
83
56
  - lib/punch/instance.rb
84
57
  - lib/punch/version.rb
85
- - lib/punch.rb
86
58
  - spec/fixnum_spec.rb
87
59
  - spec/punch_command_spec.rb
88
60
  - spec/punch_instance_spec.rb
89
61
  - spec/punch_spec.rb
90
62
  - spec/spec_helper.rb
91
- - bin/punch
92
63
  homepage: http://github.com/ymendel/one_inch_punch/
93
64
  licenses: []
94
-
65
+ metadata: {}
95
66
  post_install_message:
96
67
  rdoc_options: []
97
-
98
- require_paths:
68
+ require_paths:
99
69
  - lib
100
- required_ruby_version: !ruby/object:Gem::Requirement
101
- none: false
102
- requirements:
70
+ required_ruby_version: !ruby/object:Gem::Requirement
71
+ requirements:
103
72
  - - ">="
104
- - !ruby/object:Gem::Version
105
- hash: 3
106
- segments:
107
- - 0
108
- version: "0"
109
- required_rubygems_version: !ruby/object:Gem::Requirement
110
- none: false
111
- requirements:
73
+ - !ruby/object:Gem::Version
74
+ version: '0'
75
+ required_rubygems_version: !ruby/object:Gem::Requirement
76
+ requirements:
112
77
  - - ">="
113
- - !ruby/object:Gem::Version
114
- hash: 3
115
- segments:
116
- - 0
117
- version: "0"
78
+ - !ruby/object:Gem::Version
79
+ version: '0'
118
80
  requirements: []
119
-
120
81
  rubyforge_project:
121
- rubygems_version: 1.8.10
82
+ rubygems_version: 2.5.1
122
83
  signing_key:
123
- specification_version: 3
84
+ specification_version: 4
124
85
  summary: Track your time locally.
125
86
  test_files: []
126
-
data/README.txt DELETED
@@ -1,66 +0,0 @@
1
- = one_inch_punch
2
-
3
- == DESCRIPTION:
4
-
5
- one_inch_punch is meant as a generally data- and interface-compatible alternative
6
- to Ara T. Howard's punch gem. The main benefits will be greater understandability,
7
- test coverage, and usage outside of merely command-line situations.
8
-
9
- Punch: Good enough
10
- One-inch punch: Smaller, more effective
11
-
12
- == FEATURES/PROBLEMS:
13
-
14
- * Can load and write .punch.yml data compatibly with Ara's punch gem
15
- * Things you may expect from a time-tracking program, like punching in and out and getting time data
16
- * The ability to be punched in to multiple projects at once, because double-billing is awesome
17
- * More, since this is unfinished
18
-
19
- == SYNOPSIS:
20
-
21
- require 'punch'
22
-
23
- Punch.load
24
- Punch.status('my project') # => 'out'
25
- Punch.in('my project')
26
- Punch.status('my project') # => 'in'
27
- # do some work
28
- Punch.out('my project')
29
- Punch.out?('my project') # => true
30
- Punch.write
31
-
32
- or!
33
-
34
- $ punch in proj
35
- $ echo 'working, really'
36
- $ punch out proj
37
- $ punch status
38
-
39
- or!
40
-
41
- require 'punch'
42
-
43
- proj = Punch.new('my project')
44
- proj.status # => 'out'
45
- proj.in
46
- proj.status # => 'in'
47
- # do some work
48
- proj.out
49
- proj.out? # => true
50
- Punch.write
51
-
52
- == REQUIREMENTS:
53
-
54
- * A reason to track time
55
- * Ruby
56
-
57
- == INSTALL:
58
-
59
- * gem install one_inch_punch
60
-
61
- == THANKS:
62
-
63
- * Ara T. Howard, for making punch in the first place
64
- * Kevin Barnes, for the name suggestion
65
- * Bruce Lee, for having been a bad-ass
66
- * The Kool-Aid Man, for busting through my wall. Oh yeah!