insulin 0.0.11 → 0.0.12

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.
data/.rvmrc ADDED
@@ -0,0 +1 @@
1
+ rvm 1.9.2
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- insulin (0.0.10)
4
+ insulin (0.0.11)
5
5
  bson_ext
6
6
  ffi
7
7
  mongo
@@ -28,6 +28,7 @@ GEM
28
28
  json (>= 1.4.6)
29
29
  diff-lcs (1.1.3)
30
30
  ffi (1.0.11)
31
+ gem-release (0.3.1)
31
32
  gherkin (2.11.1)
32
33
  json (>= 1.4.6)
33
34
  json (1.7.3)
@@ -49,5 +50,6 @@ PLATFORMS
49
50
  DEPENDENCIES
50
51
  aruba
51
52
  cucumber
53
+ gem-release
52
54
  insulin!
53
55
  rspec (~> 2.6)
data/Rakefile CHANGED
@@ -7,7 +7,7 @@ require "insulin/version"
7
7
 
8
8
  task :build do
9
9
  system "gem build insulin.gemspec"
10
- # system "mv insulin*gem pkg/"
10
+ system "mv insulin*gem pkg/"
11
11
  end
12
12
 
13
13
  task :release => :build do
data/TODO.md CHANGED
@@ -3,5 +3,6 @@
3
3
  * Map/reduce somewhere?
4
4
  * Jenkins?
5
5
  * Food - combine available carbs data with meds object? or other way around?
6
- * Estimated hba1c?
7
- * Oops, need to handle the case where there's no data for a given day
6
+ * Estimated HbA1c?
7
+ * Have week and month options which default to the last week, last 30 days
8
+ * https://github.com/svenfuchs/gem-release
data/bin/insulin CHANGED
@@ -28,6 +28,8 @@ module Insulin
28
28
  puts "No data for %s" % date
29
29
  end
30
30
  end
31
+
32
+ default_task :day
31
33
  end
32
34
  end
33
35
 
data/insulin.gemspec CHANGED
@@ -25,4 +25,5 @@ Gem::Specification.new do |gem|
25
25
  gem.add_development_dependency "rspec", "~> 2.6"
26
26
  gem.add_development_dependency "cucumber"
27
27
  gem.add_development_dependency "aruba"
28
+ gem.add_development_dependency "gem-release"
28
29
  end
@@ -11,8 +11,13 @@ module Insulin
11
11
  # Set up the connection as described by 'conf'
12
12
  def initialize conf
13
13
  @conf = conf
14
- @connection = Mongo::Connection.new
15
- @db = @connection.db @conf["database"]
14
+ begin
15
+ @connection = Mongo::Connection.new
16
+ @db = @connection.db @conf["database"]
17
+ rescue Mongo::ConnectionFailure
18
+ puts "MongoDB doesn't appear to be running. We can't go on without this"
19
+ exit 1
20
+ end
16
21
  end
17
22
 
18
23
  # Drop this database
@@ -1,5 +1,5 @@
1
1
  module Insulin
2
2
 
3
3
  # Current version
4
- VERSION = "0.0.11"
4
+ VERSION = "0.0.12"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: insulin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.11
4
+ version: 0.0.12
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -123,6 +123,22 @@ dependencies:
123
123
  - - ! '>='
124
124
  - !ruby/object:Gem::Version
125
125
  version: '0'
126
+ - !ruby/object:Gem::Dependency
127
+ name: gem-release
128
+ requirement: !ruby/object:Gem::Requirement
129
+ none: false
130
+ requirements:
131
+ - - ! '>='
132
+ - !ruby/object:Gem::Version
133
+ version: '0'
134
+ type: :development
135
+ prerelease: false
136
+ version_requirements: !ruby/object:Gem::Requirement
137
+ none: false
138
+ requirements:
139
+ - - ! '>='
140
+ - !ruby/object:Gem::Version
141
+ version: '0'
126
142
  description: Doing stuff with my diabetes data
127
143
  email:
128
144
  - sam@cruft.co
@@ -133,6 +149,7 @@ extra_rdoc_files: []
133
149
  files:
134
150
  - .gitignore
135
151
  - .rspec
152
+ - .rvmrc
136
153
  - Gemfile
137
154
  - Gemfile.lock
138
155
  - LICENSE