pry-note 0.2.6 → 0.2.7

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/lib/pry-note.rb CHANGED
@@ -22,7 +22,10 @@ module PryNote
22
22
  return if !file_name && !Pry.config.notes_file
23
23
  file_name ||= Pry.config.notes_file
24
24
  expanded_path = File.expand_path(file_name)
25
- File.open(expanded_path, "w") { |f| f.puts YAML.dump(PryNote.notes) }
25
+
26
+ if PryNote.notes && PryNote.notes.any?
27
+ File.open(expanded_path, "w") { |f| f.puts YAML.dump(PryNote.notes) }
28
+ end
26
29
  end
27
30
 
28
31
  # @return [Pry::Method, Pry::WrappedModule, Pry::Command] The code_object
@@ -1,3 +1,3 @@
1
1
  module PryNote
2
- VERSION = "0.2.6"
2
+ VERSION = "0.2.7"
3
3
  end
data/pry-note.gemspec CHANGED
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "pry-note"
5
- s.version = "0.2.6"
5
+ s.version = "0.2.7"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["John Mair (banisterfiend)"]
9
- s.date = "2012-12-02"
9
+ s.date = "2012-12-06"
10
10
  s.description = "Ease refactoring and exploration by attaching notes to methods and classes in Pry"
11
11
  s.email = "jrmair@gmail.com"
12
12
  s.files = ["README.md", "Rakefile", "lib/pry-note.rb", "lib/pry-note/commands.rb", "lib/pry-note/hooks.rb", "lib/pry-note/version.rb", "pry-note.gemspec", "test/helper.rb", "test/test_pry_note.rb"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pry-note
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.6
4
+ version: 0.2.7
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-02 00:00:00.000000000 Z
12
+ date: 2012-12-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake