tickle 0.1.7 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore CHANGED
@@ -1,21 +1,21 @@
1
- ## MAC OS
2
1
  .DS_Store
3
2
 
4
- ## TEXTMATE
5
3
  *.tmproj
6
4
  tmtags
7
5
 
8
- ## EMACS
9
6
  *~
10
7
  \#*
11
8
  .\#*
12
9
 
13
- ## VIM
14
10
  *.swp
15
-
16
- ## PROJECT::GENERAL
11
+ doc/
17
12
  coverage
18
13
  rdoc
19
14
  pkg
20
-
21
- ## PROJECT::SPECIFIC
15
+ bin/
16
+ vendor/
17
+ Gemfile.lock
18
+ spec/
19
+ .yardoc/
20
+ .bundle/
21
+ .rspec
@@ -0,0 +1,14 @@
1
+ # CH CH CH CH CHANGES! #
2
+
3
+ ## Monday the 11th of November, v1.0.1 ##
4
+
5
+ * Moved library to new maintainer [https://github.com/yb66/tickle](@yb66)
6
+ * Moved library to [http://semver.org/](semver).
7
+ * Merged in some changes from @dan335 and @JesseAldridge, thanks to them.
8
+ * Moved rdocs to markdown for niceness.
9
+ * Updated licences with dates and correct spelling ;)
10
+ * Fix incorporated for "NameError: uninitialized constant Module::Numerizer"
11
+ * Moved library to Bundler to make it easier to set up and develop against.
12
+ * Started using Yardoc for more niceness with documentation.
13
+
14
+ ----
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ source "https://rubygems.org"
2
+
3
+ gemspec
4
+
5
+ gem "wirble"
6
+ group :test do
7
+ gem "rspec"
8
+ end
@@ -1,4 +1,6 @@
1
1
  Copyright (c) 2010 Joshua Lippiner
2
+ Copyright (c) 2013 Iain Barnett
3
+
2
4
 
3
5
  Permission is hereby granted, free of charge, to any person obtaining
4
6
  a copy of this software and associated documentation files (the
@@ -1,82 +1,71 @@
1
- = tickle
2
- http://github.com/noctivityinc/tickle
3
- by Joshua Lippiner, Noctivity
1
+ ## Tickle ##
4
2
 
5
- == *LEGACY WARNING*
3
+ This is now the home of ***Tickle***, previously found at [github.com/noctivityinc/tickle](https://github.com/noctivityinc/tickle)
6
4
 
7
- If you starting using Tickle pre version 0.1.X, you will need to update your code to either include the :next_only => true option or read correctly from the options hash. Sorry.
5
+ If you wish to contribute then please take a look at the Contribution section further down the page, but I'd be really, *really* grateful if anyone wishes to contribute specs. Not unit tests, but specs. This library's internals will be changing a lot over the coming months, and it would be good to have integration tests - a black-box spec of the library - to work against. Even if you've never contributed to a library before, now is your chance! I'll help anyone through with what they may need, and I promise not to be the standard snarky Open Source dictator that a lot of projects have. We'll try and improve this library together.
8
6
 
9
- == DESCRIPTION
7
+ Take a look at the `develop` branch where all this stuff will be happening.
10
8
 
11
- Tickle is a natural language parser for recurring events.
12
-
13
- Tickle is designed to be a compliment of Chronic and can interpret things such as "every 2 days, every Sunday, Sundays, Weekly, etc."
14
-
15
- In a lot of ways Tickle is actually an enhancement of Chronic, handling a lot of things that Chronic can't, such as commas and US Holidays (yup - you can do Tickle.parse('Christmas Eve'))
16
9
 
17
- Tickle has one main method, "Tickle.parse," which returns the next time the event should occur, at which point you simply call Tickle.parse again.
10
+ ### DESCRIPTION ###
18
11
 
19
- == INSTALLATION
20
-
21
- Tickle can be installed via RubyGems:
22
-
23
- $ gem install tickle
24
-
25
- == TINKERING
12
+ Tickle is a natural language parser for recurring events.
13
+
14
+ Tickle is designed to be a complement to [Chronic](https://rubygems.org/gems/chronic) and can interpret things such as "every 2 days, every Sunday, Sundays, Weekly, etc."
26
15
 
27
- Everything's at Github - http://github.com/noctivityinc/tickle
16
+ Tickle has one main method, `Tickle.parse`, which returns the next time the event should occur, at which point you simply call `Tickle.parse` again.
28
17
 
29
- == DEPENDENCIES
18
+ ### *LEGACY WARNING* ###
30
19
 
31
- chronic gem (gem install chronic)
20
+ If you starting using Tickle pre version 0.1.X, you will need to update your code to either include the `:next_only => true` option or read correctly from the options hash. Sorry.
32
21
 
33
- thoughtbot's shoulda (gem install shoulda)
34
22
 
35
- == USAGE
23
+ ### USAGE ###
36
24
 
37
- You can parse strings containing a natural language interval using the Tickle.parse method.
25
+ You can parse strings containing a natural language interval using the `Tickle.parse` method.
38
26
 
39
- You can either pass a string prefixed with the word "every, each or 'on the'" or simply the time frame.
27
+ You can either pass a string prefixed with the word "every", "each" or "on the" or simply the timeframe.
40
28
 
41
29
  Tickle.parse returns a hash containing the following keys:
42
- * next = the next occurrence of the event. This is NEVER today as its always the next date in the future.
43
- * starting = the date all calculations as based on. If not passed as an option, the start date is right now.
44
- * until = the last date you want this event to run until.
45
- * expression = this is the natural language expression to store to run through tickle later to get the next occurrence.
30
+ * `next` the next occurrence of the event. This is NEVER today as its always the next date in the future.
31
+ * `starting` the date all calculations as based on. If not passed as an option, the start date is right now.
32
+ * `until` the last date you want this event to run until.
33
+ * `expression` this is the natural language expression to store to run through tickle later to get the next occurrence.
46
34
 
47
- Tickle returns nil if it cannot parse the string cannot be parsed.
35
+ Tickle returns `nil` if it cannot parse the string.
48
36
 
49
- Tickle HEAVILY uses chronic for parsing but mostly the start and until phrases.
37
+ Tickle ***heavily*** uses Chronic for parsing both the event and the start date.
50
38
 
51
- === OPTIONS
39
+ ### OPTIONS ###
52
40
 
53
41
  There are two ways to pass options: natural language or an options hash.
54
42
 
55
43
  NATURAL LANGUAGE:
56
- * Pass a start date with the word "starting, start, stars" (e.g. Tickle.parse('every 3 days starting next friday'))
57
- * Pass an end date with the word "until, end, ends, ending" (e.g. Tickle.parse('every 3 days until next friday'))
58
- * Pass both at the same time (e.g. "starting May 5th repeat every other week until December 1")
44
+ * Pass a start date with the word "starting", "start", or "stars" e.g. `Tickle.parse('every 3 days starting next friday')`
45
+ * Pass an end date with the word "until", "end", "ends", or "ending" e.g. `Tickle.parse('every 3 days until next friday')`
46
+ * Pass both at the same time e.g. `"starting May 5th repeat every other week until December 1"`
59
47
 
60
48
  OPTIONS HASH
61
49
  Valid options are:
62
- * start - must be a valid date or Chronic date expression. (e.g. Tickle.parse('every other day', {:start => Date.new(2010,8,1) }))
63
- * until - must be a valid date or Chronic date expression. (e.g. Tickle.parse('every other day', {:until => Date.new(2010,10,1) }))
64
- * next_only - legacy switch to ONLY return the next occurrence as a date and not return a hash
50
+ * `start` - must be a valid date or Chronic date expression. e.g. `Tickle.parse('every other day', {:start => Date.new(2010,8,1) })`
51
+ * `until` - must be a valid date or Chronic date expression. e.g. `Tickle.parse('every other day', {:until => Date.new(2010,10,1) })`
52
+ * `next_only` - legacy switch to *only* return the next occurrence as a date and not return a hash
65
53
 
66
- === SUPER IMPORTANT NOTE ABOUT NEXT OCCURRENCE & START DATE
54
+ ### SUPER IMPORTANT NOTE ABOUT NEXT OCCURRENCE & START DATE ###
67
55
 
68
- You may notice when parsing an expression with a start date that the next occurrence IS the start date passed. This is DESIGNED BEHAVIOR.
56
+ You may notice when parsing an expression with a start date that the next occurrence **is** the start date passed. This is **designed behaviour**.
69
57
 
70
58
  Here's why - assume your user says "remind me every 3 weeks starting Dec 1" and today is May 8th. Well the first reminder needs to be sent on Dec 1, not Dec 21 (three weeks later).
71
59
 
72
- If you don't like that, fork and have fun but don't say I didn't warn ya.
60
+ If you don't like that, fork and have fun but don't say you weren't warned.
73
61
 
74
- === EXAMPLES
75
62
 
76
- require 'rubygems'
77
- require 'tickle'
63
+ ### EXAMPLES ###
64
+
65
+ require 'tickle'
66
+
67
+ #### SIMPLE ####
78
68
 
79
- SIMPLE
80
69
  Tickle.parse('day')
81
70
  #=> {:next=>2010-05-10 20:57:36 -0400, :expression=>"day", :starting=>2010-05-09 20:57:36 -0400, :until=>nil}
82
71
 
@@ -230,7 +219,8 @@ SIMPLE
230
219
  Tickle.parse('the twenty first of the month', {:start=>#<Date: 2020-04-01 (4917881/2,0,2299161)>, :now=>#<Date: 2020-04-01 (4917881/2,0,2299161)>})
231
220
  #=> {:next=>2020-04-21 00:00:00 -0400, :expression=>"the twenty first of the month", :starting=>2020-04-01 00:00:00 -0400, :until=>nil}
232
221
 
233
- COMPLEX
222
+ #### COMPLEX ####
223
+
234
224
  Tickle.parse('starting today and ending one week from now')
235
225
  #=> {:next=>2010-05-10 22:30:00 -0400, :expression=>"day", :starting=>2010-05-09 22:30:00 -0400, :until=>2010-05-16 20:57:35 -0400}
236
226
 
@@ -283,7 +273,8 @@ COMPLEX
283
273
  #=> {:next=>2010-05-12 12:00:00 -0400, :expression=>"week", :starting=>2010-05-12 12:00:00 -0400, :until=>2010-05-13 12:00:00 -0400}
284
274
 
285
275
 
286
- OPTIONS HASH
276
+ #### OPTIONS HASH ####
277
+
287
278
  Tickle.parse('May 1st 2020', {:next_only=>true})
288
279
  #=> 2020-05-01 00:00:00 -0400
289
280
 
@@ -308,7 +299,7 @@ OPTIONS HASH
308
299
  Tickle.parse('3 months', {:until=>2010-10-09 00:00:00 -0400})
309
300
  #=> {:next=>2010-08-09 20:57:36 -0400, :expression=>"3 months", :starting=>2010-05-09 20:57:36 -0400, :until=>2010-10-09 00:00:00 -0400}
310
301
 
311
- US HOLIDAYS
302
+ #### US HOLIDAYS ####
312
303
 
313
304
  Tickle.parse('New Years Day', {:start=>#<Date: 2020-01-01 (4917699/2,0,2299161)>, :now=>#<Date: 2020-01-01 (4917699/2,0,2299161)>})
314
305
  #=> {:next=>2021-01-01 12:00:00 -0500, :expression=>"january 1, 2021", :starting=>2020-01-01 00:00:00 -0500, :until=>nil}
@@ -389,48 +380,73 @@ US HOLIDAYS
389
380
  #=> {:next=>2021-01-01 12:00:00 -0500, :expression=>"january 1, 2021", :starting=>2020-01-01 00:00:00 -0500, :until=>nil}
390
381
 
391
382
 
392
- == USING IN APP
383
+ ### USING IN APP ###
393
384
 
394
385
  To use in your app, we recommend adding two attributes to your database model:
395
- * next_occurrence
396
- * tickle_expression
397
386
 
398
- Then call Tickle.parse(date expression) when you need to and save the results accordingly. In your
399
- code, each day, simply check to see if today is >= next_occurrence and, if so, run your block.
387
+ * `next_occurrence`
388
+ * `tickle_expression`
400
389
 
401
- After it completes, call Tickle.parse(tickle_expression) again to update the next occurrence of the event.
390
+ Then call `Tickle.parse("date expression goes here")` when you need to and save the results accordingly. In your
391
+ code, each day, simply check to see if today is `>= next_occurrence` and, if so, run your block.
402
392
 
393
+ After it completes, call `next_occurrence = Tickle.parse(tickle_expression)` again to update the next occurrence of the event.
403
394
 
404
- == TESTING
405
395
 
406
- Tickle comes with a full testing suite for simple, complex, options hash and invalid arguments.
396
+ ### INSTALLATION ###
407
397
 
408
- You also have some command line options:
409
- --v verbose output like the examples above
410
- --d debug output showing the guts of a date expression
398
+ Tickle can be installed via RubyGems:
399
+
400
+ gem install tickle
411
401
 
412
- == LIMITATIONS
402
+ or if you're using Bundler, add this to the Gemfile:
403
+
404
+ gem "tickle"
405
+
406
+ ### DEPENDENCIES ###
407
+
408
+ Chronic gem:
409
+
410
+ `gem install chronic`
411
+
412
+ thoughtbot's [shoulda](https://rubygems.org/gems/shoulda):
413
+
414
+ `gem install shoulda`
415
+
416
+ or just run `bundle install`.
417
+
418
+
419
+ ### LIMITATIONS ###
413
420
 
414
421
  Currently, Tickle only works for day intervals but feel free to fork and add time-based interval support or send me a note if you really want me to add it.
415
422
 
416
- == CREDIT
417
423
 
418
- HUGE shout-out to both the creator of Chronic, Tom Preston-Werner (http://chronic.rubyforge.org/) as well as Brian Brownling who maintains a github version at http://github.com/mojombo/chronic.
424
+ ### CONTRIBUTING ###
425
+
426
+ Fork it, create a new branch for your changes, and send in a pull request.
427
+
428
+ * Only tested code gets in.
429
+ * Document it.
430
+ * If you want to work on something but aren't sure whether it'll get in, create a new branch and open a pull request before you've done any code. That will open an issue and we can discuss it.
431
+ * Do not mess with the Rakefile, version, or history (if you want to have your own version, that is fine but do it on a separate branch from the one I'm going to merge.)
432
+
433
+ ### TESTING ###
434
+
435
+ Tickle comes with a full testing suite for simple, complex, options hash and invalid arguments.
436
+
437
+ You also have some command line options:
438
+
439
+ * --v verbose output like the examples above
440
+ * --d debug output showing the guts of a date expression
419
441
 
420
- Without their work and code structure I'd be lost.
442
+ ### CREDIT ###
421
443
 
422
- As always, BIG shout-out to the RVM Master himself, Wayne Seguin, for putting up with me and Ruby from day one. Ask Wayne to make you some Ciabatta bread next time you see him
444
+ The original work on the library was done by *Joshua Lippiner* a.k.a. [Noctivity](https://github.com/noctivityinc).
423
445
 
446
+ ***HUGE*** shout-out to both the creator of Chronic, *Tom Preston-Werner* as well as *Brian Brownling* who maintains a Github version at [github.com/mojombo/chronic](https://github.com/mojombo/chronic).
424
447
 
425
- == Note on Patches/Pull Requests
426
- * Fork the project.
427
- * Make your feature addition or bug fix.
428
- * Add tests for it. This is important so I don't break it in a
429
- future version unintentionally.
430
- * Commit, do not mess with rakefile, version, or history.
431
- (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
432
- * Send me a pull request. Bonus points for time-based branches.
448
+ As always, ***BIG*** shout-out to the RVM Master himself, *Wayne Seguin*, for putting up with me and Ruby from day one. Ask Wayne to make you some ciabatta bread next time you see him.
433
449
 
434
- == Copyright
450
+ ### LICENCE ###
435
451
 
436
- Copyright (c) 2010 Joshua Lippiner. See LICENSE for details.
452
+ See the LICENCE file.
data/Rakefile CHANGED
@@ -1,25 +1,3 @@
1
- require 'rubygems'
2
- require 'rake'
3
-
4
- begin
5
- require 'jeweler'
6
- Jeweler::Tasks.new do |gem|
7
- gem.name = "tickle"
8
- gem.summary = 'natural language parser for recurring events'
9
- gem.description = 'Tickle is a date/time helper gem to help parse natural language into a recurring pattern. Tickle is designed to be a compliment of Chronic and can interpret things such as "every 2 days, every Sunday, Sundays, Weekly, etc.'
10
- gem.email = "jlippiner@noctivity.com"
11
- gem.homepage = "http://github.com/noctivityinc/tickle"
12
- gem.authors = ["Joshua Lippiner"]
13
- gem.add_dependency('chronic', '>= 0.2.3')
14
- gem.add_development_dependency "shoulda", ">= 2.10.3"
15
-
16
- # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
17
- end
18
- Jeweler::GemcutterTasks.new
19
- rescue LoadError
20
- puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
21
- end
22
-
23
1
  require 'rake/testtask'
24
2
  Rake::TestTask.new(:test) do |test|
25
3
  test.libs << 'lib' << 'test'
@@ -27,29 +5,24 @@ Rake::TestTask.new(:test) do |test|
27
5
  test.verbose = true
28
6
  end
29
7
 
30
- begin
31
- require 'rcov/rcovtask'
32
- Rcov::RcovTask.new do |test|
33
- test.libs << 'test'
34
- test.pattern = 'test/**/test_*.rb'
35
- test.verbose = true
36
- end
37
- rescue LoadError
38
- task :rcov do
39
- abort "RCov is not available. In order to run rcov, you must: sudo gem install spicycode-rcov"
40
- end
41
- end
42
-
43
8
  task :test => :check_dependencies
44
9
 
45
10
  task :default => :test
46
11
 
47
- require 'rake/rdoctask'
48
- Rake::RDocTask.new do |rdoc|
49
- version = File.exist?('VERSION') ? File.read('VERSION') : ""
50
12
 
51
- rdoc.rdoc_dir = 'rdoc'
52
- rdoc.title = "tickle #{version}"
53
- rdoc.rdoc_files.include('README*')
54
- rdoc.rdoc_files.include('lib/**/*.rb')
13
+ desc "(Re-) generate documentation and place it in the docs/ dir. Open the index.html file in there to read it."
14
+ task :docs => [:"docs:environment", :"docs:yard"]
15
+ namespace :docs do
16
+
17
+ task :environment do
18
+ ENV["RACK_ENV"] = "documentation"
19
+ end
20
+
21
+ require 'yard'
22
+
23
+ YARD::Rake::YardocTask.new :yard do |t|
24
+ t.files = ['lib/**/*.rb']
25
+ t.options = ['-odoc/'] # optional
26
+ end
27
+
55
28
  end
@@ -0,0 +1,29 @@
1
+
2
+ require File.join(File.dirname(__FILE__), 'lib', 'tickle')
3
+
4
+ =begin
5
+
6
+ Tickle creates standard Ruby Time objects.
7
+
8
+ Time is ignored if there's also a date, unless the date is 'tomorrow'(?)
9
+
10
+ Tickle creates times in the servers local time zone.
11
+ To go from server time to user's local time...
12
+ user_time = server_time + (user_time_offset - server_time_offset)
13
+ eg (5:00PM Central) = (6:00PM Eastern + (-6 - -5))
14
+
15
+ Tickle makes 'May 30th' at 0:00, but 'June 18, 2011' and 'Christmas' at 12:00.
16
+ =end
17
+
18
+
19
+ server_offset = Time.now.utc_offset / 60 / 60
20
+
21
+ ['May 30th', '6:30 PM',
22
+ 'tomorrow at 6:00', 'June 18, 2011', 'Christmas'].each {|s|
23
+ time = Tickle.parse(s)[:next]
24
+ if s == 'Christmas'
25
+ time -= 12 * 60 * 60
26
+ end
27
+ print s, " --> server date: ", time
28
+ puts
29
+ }
@@ -16,6 +16,7 @@ require 'chronic'
16
16
  require 'tickle/tickle'
17
17
  require 'tickle/handler'
18
18
  require 'tickle/repeater'
19
+ require 'numerizer/numerizer'
19
20
 
20
21
  module Tickle #:nodoc:
21
22
  VERSION = "0.1.7"
@@ -19,8 +19,10 @@
19
19
  # OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
20
20
  # WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
21
21
 
22
- module Tickle #:nodoc:
23
- class << self #:nodoc:
22
+ require_relative "../numerizer/numerizer.rb"
23
+
24
+ module Tickle
25
+ class << self
24
26
  # == Configuration options
25
27
  #
26
28
  # * +start+ - start date for future occurrences. Must be in valid date format.
@@ -254,8 +256,6 @@ module Tickle #:nodoc:
254
256
  @tokens.map(&:type)
255
257
  end
256
258
 
257
- protected
258
-
259
259
  # Returns the next available month based on the current day of the month.
260
260
  # For example, if get_next_month(15) is called and the start date is the 10th, then it will return the 15th of this month.
261
261
  # However, if get_next_month(15) is called and the start date is the 18th, it will return the 15th of next month.
@@ -0,0 +1,5 @@
1
+ module Tickle
2
+
3
+ # This library's current version.
4
+ VERSION = "1.0.0"
5
+ end
@@ -1,4 +1,9 @@
1
- require 'rubygems'
1
+ require 'simplecov'
2
+ SimpleCov.start do
3
+ add_filter "/vendor/"
4
+ add_filter "/bin/"
5
+ end
6
+
2
7
  require 'test/unit'
3
8
  require 'shoulda'
4
9
 
@@ -1,4 +1,4 @@
1
- require File.expand_path(File.dirname(__FILE__) + '/helper')
1
+ require_relative './helper.rb'
2
2
  require 'time'
3
3
  require 'test/unit'
4
4
 
@@ -1,65 +1,32 @@
1
- # Generated by jeweler
2
- # DO NOT EDIT THIS FILE DIRECTLY
3
- # Instead, edit Jeweler::Tasks in Rakefile, and run the gemspec command
4
- # -*- encoding: utf-8 -*-
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'tickle/version'
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{tickle}
8
- s.version = "0.1.7"
8
+ s.version = Tickle::VERSION
9
9
 
10
- s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
- s.authors = ["Joshua Lippiner"]
12
- s.date = %q{2010-05-10}
10
+ s.authors = ["Joshua Lippiner", "Iain Barnett"]
11
+ s.email = %q{iainspeed@gmail.com}
13
12
  s.description = %q{Tickle is a date/time helper gem to help parse natural language into a recurring pattern. Tickle is designed to be a compliment of Chronic and can interpret things such as "every 2 days, every Sunday, Sundays, Weekly, etc.}
14
- s.email = %q{jlippiner@noctivity.com}
15
- s.extra_rdoc_files = [
16
- "LICENSE",
17
- "README.rdoc"
18
- ]
19
- s.files = [
20
- ".document",
21
- ".gitignore",
22
- ".rvmrc",
23
- "LICENSE",
24
- "README.rdoc",
25
- "Rakefile",
26
- "SCENARIOS.rdoc",
27
- "VERSION",
28
- "git-flow-version",
29
- "lib/numerizer/numerizer.rb",
30
- "lib/tickle.rb",
31
- "lib/tickle/handler.rb",
32
- "lib/tickle/repeater.rb",
33
- "lib/tickle/tickle.rb",
34
- "test/git-flow-version",
35
- "test/helper.rb",
36
- "test/test_parsing.rb",
37
- "tickle.gemspec"
38
- ]
39
- s.homepage = %q{http://github.com/noctivityinc/tickle}
40
- s.rdoc_options = ["--charset=UTF-8"]
41
- s.require_paths = ["lib"]
42
- s.rubygems_version = %q{1.3.6}
43
13
  s.summary = %q{natural language parser for recurring events}
44
- s.test_files = [
45
- "test/helper.rb",
46
- "test/test_parsing.rb"
47
- ]
14
+ s.homepage = %q{http://github.com/yb66/tickle}
15
+ s.license = "MIT"
16
+
17
+ s.files = `git ls-files`.split($/)
18
+ s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
19
+ s.test_files = s.files.grep(%r{^(test|spec|features)/})
20
+
21
+ s.require_paths = ["lib"]
48
22
 
49
- if s.respond_to? :specification_version then
50
- current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
51
- s.specification_version = 3
23
+ s.add_dependency "chronic", "~> 0.2.3"
24
+ s.add_dependency "shoulda", "~> 2.10.3"
25
+ s.add_dependency "simplecov"
52
26
 
53
- if Gem::Version.new(Gem::RubyGemsVersion) >= Gem::Version.new('1.2.0') then
54
- s.add_runtime_dependency(%q<chronic>, [">= 0.2.3"])
55
- s.add_development_dependency(%q<shoulda>, [">= 2.10.3"])
56
- else
57
- s.add_dependency(%q<chronic>, [">= 0.2.3"])
58
- s.add_dependency(%q<shoulda>, [">= 2.10.3"])
59
- end
60
- else
61
- s.add_dependency(%q<chronic>, [">= 0.2.3"])
62
- s.add_dependency(%q<shoulda>, [">= 2.10.3"])
63
- end
27
+ s.add_development_dependency "bundler", "~> 1.2"
28
+ s.add_development_dependency "rake"
29
+ s.add_development_dependency "yard"
30
+ s.add_development_dependency "maruku"
64
31
  end
65
32
 
metadata CHANGED
@@ -1,108 +1,185 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: tickle
3
- version: !ruby/object:Gem::Version
4
- prerelease: false
5
- segments:
6
- - 0
7
- - 1
8
- - 7
9
- version: 0.1.7
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
5
+ prerelease:
10
6
  platform: ruby
11
- authors:
7
+ authors:
12
8
  - Joshua Lippiner
9
+ - Iain Barnett
13
10
  autorequire:
14
11
  bindir: bin
15
12
  cert_chain: []
16
-
17
- date: 2010-05-10 00:00:00 -04:00
18
- default_executable:
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
13
+ date: 2013-11-11 00:00:00.000000000 Z
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
21
16
  name: chronic
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
24
- requirements:
25
- - - ">="
26
- - !ruby/object:Gem::Version
27
- segments:
28
- - 0
29
- - 2
30
- - 3
17
+ requirement: !ruby/object:Gem::Requirement
18
+ none: false
19
+ requirements:
20
+ - - ~>
21
+ - !ruby/object:Gem::Version
31
22
  version: 0.2.3
32
23
  type: :runtime
33
- version_requirements: *id001
34
- - !ruby/object:Gem::Dependency
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ none: false
27
+ requirements:
28
+ - - ~>
29
+ - !ruby/object:Gem::Version
30
+ version: 0.2.3
31
+ - !ruby/object:Gem::Dependency
35
32
  name: shoulda
33
+ requirement: !ruby/object:Gem::Requirement
34
+ none: false
35
+ requirements:
36
+ - - ~>
37
+ - !ruby/object:Gem::Version
38
+ version: 2.10.3
39
+ type: :runtime
36
40
  prerelease: false
37
- requirement: &id002 !ruby/object:Gem::Requirement
38
- requirements:
39
- - - ">="
40
- - !ruby/object:Gem::Version
41
- segments:
42
- - 2
43
- - 10
44
- - 3
41
+ version_requirements: !ruby/object:Gem::Requirement
42
+ none: false
43
+ requirements:
44
+ - - ~>
45
+ - !ruby/object:Gem::Version
45
46
  version: 2.10.3
47
+ - !ruby/object:Gem::Dependency
48
+ name: simplecov
49
+ requirement: !ruby/object:Gem::Requirement
50
+ none: false
51
+ requirements:
52
+ - - ! '>='
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ type: :runtime
56
+ prerelease: false
57
+ version_requirements: !ruby/object:Gem::Requirement
58
+ none: false
59
+ requirements:
60
+ - - ! '>='
61
+ - !ruby/object:Gem::Version
62
+ version: '0'
63
+ - !ruby/object:Gem::Dependency
64
+ name: bundler
65
+ requirement: !ruby/object:Gem::Requirement
66
+ none: false
67
+ requirements:
68
+ - - ~>
69
+ - !ruby/object:Gem::Version
70
+ version: '1.2'
46
71
  type: :development
47
- version_requirements: *id002
48
- description: Tickle is a date/time helper gem to help parse natural language into a recurring pattern. Tickle is designed to be a compliment of Chronic and can interpret things such as "every 2 days, every Sunday, Sundays, Weekly, etc.
49
- email: jlippiner@noctivity.com
72
+ prerelease: false
73
+ version_requirements: !ruby/object:Gem::Requirement
74
+ none: false
75
+ requirements:
76
+ - - ~>
77
+ - !ruby/object:Gem::Version
78
+ version: '1.2'
79
+ - !ruby/object:Gem::Dependency
80
+ name: rake
81
+ requirement: !ruby/object:Gem::Requirement
82
+ none: false
83
+ requirements:
84
+ - - ! '>='
85
+ - !ruby/object:Gem::Version
86
+ version: '0'
87
+ type: :development
88
+ prerelease: false
89
+ version_requirements: !ruby/object:Gem::Requirement
90
+ none: false
91
+ requirements:
92
+ - - ! '>='
93
+ - !ruby/object:Gem::Version
94
+ version: '0'
95
+ - !ruby/object:Gem::Dependency
96
+ name: yard
97
+ requirement: !ruby/object:Gem::Requirement
98
+ none: false
99
+ requirements:
100
+ - - ! '>='
101
+ - !ruby/object:Gem::Version
102
+ version: '0'
103
+ type: :development
104
+ prerelease: false
105
+ version_requirements: !ruby/object:Gem::Requirement
106
+ none: false
107
+ requirements:
108
+ - - ! '>='
109
+ - !ruby/object:Gem::Version
110
+ version: '0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: maruku
113
+ requirement: !ruby/object:Gem::Requirement
114
+ none: false
115
+ requirements:
116
+ - - ! '>='
117
+ - !ruby/object:Gem::Version
118
+ version: '0'
119
+ type: :development
120
+ prerelease: false
121
+ version_requirements: !ruby/object:Gem::Requirement
122
+ none: false
123
+ requirements:
124
+ - - ! '>='
125
+ - !ruby/object:Gem::Version
126
+ version: '0'
127
+ description: Tickle is a date/time helper gem to help parse natural language into
128
+ a recurring pattern. Tickle is designed to be a compliment of Chronic and can interpret
129
+ things such as "every 2 days, every Sunday, Sundays, Weekly, etc.
130
+ email: iainspeed@gmail.com
50
131
  executables: []
51
-
52
132
  extensions: []
53
-
54
- extra_rdoc_files:
55
- - LICENSE
56
- - README.rdoc
57
- files:
133
+ extra_rdoc_files: []
134
+ files:
58
135
  - .document
59
136
  - .gitignore
60
- - .rvmrc
61
- - LICENSE
62
- - README.rdoc
137
+ - CHANGES.md
138
+ - Gemfile
139
+ - LICENCE
140
+ - README.md
63
141
  - Rakefile
64
142
  - SCENARIOS.rdoc
65
- - VERSION
143
+ - examples.rb
66
144
  - git-flow-version
67
145
  - lib/numerizer/numerizer.rb
68
146
  - lib/tickle.rb
69
147
  - lib/tickle/handler.rb
70
148
  - lib/tickle/repeater.rb
71
149
  - lib/tickle/tickle.rb
150
+ - lib/tickle/version.rb
151
+ - spec/spec_helper.rb
72
152
  - test/git-flow-version
73
153
  - test/helper.rb
74
154
  - test/test_parsing.rb
75
155
  - tickle.gemspec
76
- has_rdoc: true
77
- homepage: http://github.com/noctivityinc/tickle
78
- licenses: []
79
-
156
+ homepage: http://github.com/yb66/tickle
157
+ licenses:
158
+ - MIT
80
159
  post_install_message:
81
- rdoc_options:
82
- - --charset=UTF-8
83
- require_paths:
160
+ rdoc_options: []
161
+ require_paths:
84
162
  - lib
85
- required_ruby_version: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ">="
88
- - !ruby/object:Gem::Version
89
- segments:
90
- - 0
91
- version: "0"
92
- required_rubygems_version: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - ">="
95
- - !ruby/object:Gem::Version
96
- segments:
97
- - 0
98
- version: "0"
163
+ required_ruby_version: !ruby/object:Gem::Requirement
164
+ none: false
165
+ requirements:
166
+ - - ! '>='
167
+ - !ruby/object:Gem::Version
168
+ version: '0'
169
+ required_rubygems_version: !ruby/object:Gem::Requirement
170
+ none: false
171
+ requirements:
172
+ - - ! '>='
173
+ - !ruby/object:Gem::Version
174
+ version: '0'
99
175
  requirements: []
100
-
101
176
  rubyforge_project:
102
- rubygems_version: 1.3.6
177
+ rubygems_version: 1.8.25
103
178
  signing_key:
104
179
  specification_version: 3
105
180
  summary: natural language parser for recurring events
106
- test_files:
181
+ test_files:
182
+ - spec/spec_helper.rb
183
+ - test/git-flow-version
107
184
  - test/helper.rb
108
185
  - test/test_parsing.rb
data/.rvmrc DELETED
@@ -1,9 +0,0 @@
1
- #!/usr/bin/env bash
2
-
3
- # .rvmrc file for tdt application
4
-
5
- if [[ "Darwin" = "$(uname)" ]] ; then
6
- rvm ruby-1.9.1@tickle --symlink textmate
7
- else
8
- rvm ruby-1.9.1@tickle
9
- fi
data/VERSION DELETED
@@ -1 +0,0 @@
1
- 0.1.7