gmt 0.1.0 → 0.1.1

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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/gmt.rb +7 -5
  3. metadata +2 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 9e6a7a0a7dc937c57dc6c075f4c506b7c70ff314
4
- data.tar.gz: d3e77c6aee7b31a6dcd2d4a4e07b012eb99a86ee
3
+ metadata.gz: 9c457c3b27d88eb6ecebfe6b4099964280c56034
4
+ data.tar.gz: 46117cbd3d877e969dc3c5b0ac81fffbb119c3b6
5
5
  SHA512:
6
- metadata.gz: c7472840160e4d774aab02115d3c7a76781224db5b48001c35fc564e1d09073c7533a4f2b5b06cf25b4883bd7a93eb4930a9d11fb997fa75956908b52cf8d7af
7
- data.tar.gz: 96d94b7badc20cfc8ff20f4cfde1e3eab56071aaf6ecc5fbcd50a295bedbd29caf6a07ab0716a18016613eec63f36e8c4f48deae61abb9ca295f6c0953c24342
6
+ metadata.gz: 9db2d2eb4e8c28b4437030383e11f7a117b4a0405a17afe0fc631829479ec7ba6580d2e3b292b020ba39589e4b8f123e47f0b6a10ce53fcadd9e0de4b0c4fa7e
7
+ data.tar.gz: b1139fd50414084518919b2504fec7a39a3d0b0f39a07d0da43434f888c581e1e16a3aaffeb9dbe37577e0b38b6e2e439c05f6165706ce2782c1870818c36071
data/lib/gmt.rb CHANGED
@@ -96,13 +96,13 @@ class GMT
96
96
  # @macro [attach] wrapper_ps
97
97
  #
98
98
  # A PostScript function (accepts +:file+ and +:position+ options).
99
- # @method $1(*files, options)
99
+ # @method $1(*files, **options)
100
100
  # @param [Array<String>] files The input files
101
101
  # @param [Hash] options The GMT command-line options in hash form
102
102
  # @return [Boolean] +true+ on success
103
103
  # @see http://gmt.soest.hawaii.edu/doc/latest/$1.html
104
104
  def wrapper_ps(method)
105
- define_method(method) do |*args, options|
105
+ define_method(method) do |*args, **options|
106
106
  coerce_string_arguments!(args)
107
107
  coerce_postscript_options!(options)
108
108
  coerce_append_option!(options)
@@ -111,13 +111,13 @@ class GMT
111
111
  end
112
112
 
113
113
  # @macro [attach] wrapper_other
114
- # @method $1(*arguments, options)
114
+ # @method $1(*arguments, **options)
115
115
  # @param [Array<String>] arguments The arguments
116
116
  # @param [Hash] options The GMT command-line options in hash form
117
117
  # @return [Boolean] +true+ on success
118
118
  # @see http://gmt.soest.hawaii.edu/doc/latest/$1.html
119
119
  def wrapper_other(method)
120
- define_method(method) do |*args, options|
120
+ define_method(method) do |*args, **options|
121
121
  coerce_string_arguments!(args)
122
122
  coerce_append_option!(options)
123
123
  self.send(api_function(method), *args, options_as_pairs(options))
@@ -128,7 +128,9 @@ class GMT
128
128
 
129
129
  # @yield [gmt] yields the {GMT} session to the block
130
130
  def session
131
- yield GMT.new
131
+ gmt = GMT.new
132
+ yield gmt
133
+ gmt.free
132
134
  end
133
135
 
134
136
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gmt
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - J.J. Green
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-07-07 00:00:00.000000000 Z
11
+ date: 2017-08-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler