gw2-api 0.3.0 → 0.4.0

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cfee0a2b4d24bf1eb08c6e21430fc6ccf8667128b539d0a26ef215c21dbb4069
4
- data.tar.gz: a753681723c8cce8d0181a72ecafe9d6d2bcb113ada3d13f215920d2d906bb16
3
+ metadata.gz: f6dcc9e1374f9272f25aeff77172fd2c2f0b4d2e231fb0ed76c06a7fda74721a
4
+ data.tar.gz: 4d69081af045e6d07245d112c8634917c993460295841de5450733a9f8c20c56
5
5
  SHA512:
6
- metadata.gz: 50ea94f82ef032309231568840e7dacdc2e7f305d20cbbcbc9e56735979f9e7d5371f85fd4b3078b982b9e89a0f7185721d6a542b0201bc3324a90cfc49a0cea
7
- data.tar.gz: 9f81bc833ea06259dd8338f9120c613339223c543d32c3ddfdc6057e2d3985e9b835b93ac3a54bc33fecaa85d7633ec16f162c63544c3ecbba6e9db6ea1b399c
6
+ metadata.gz: 1427fbf7900e4c44b60968a9e05686ad9af3e18fbd1d681b85f652f550bfcaf4f8f93e0835eb450e32f7a3be442388b2b8ffb30e1bd5867bcac11af572edaa9e
7
+ data.tar.gz: a2cb6ba23d89dd5ac73113307f3cc48348cd6cb736c0318ce40fd6503bf9dd74afeda53b662775e112e02e41cd26a766e238bc3914d26bee70eb5243d720d3e0
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gw2-api (0.2.0)
4
+ gw2-api (0.4.0)
5
5
  rake (~> 13.0)
6
6
  rspec (~> 3.0)
7
7
  rubocop (~> 1.21)
data/README.md CHANGED
@@ -1,59 +1,59 @@
1
- # Gw2::Api
2
-
3
- This is a gem used to make calls to the Guild Wars 2 API.
4
-
5
- ## Installation
6
-
7
- Install the gem and add to the application's Gemfile by executing:
8
-
9
- $ bundle add gw2-api
10
-
11
- If bundler is not being used to manage dependencies, install the gem by executing:
12
-
13
- $ gem install gw2-api
14
-
15
- ## Usage
16
-
17
- To use the gem, first require it in the application, then create a new instance of the `Gw2::Api::Client` class:
18
-
19
- ```ruby
20
- require 'gw2-api'
21
-
22
- client = Gw2::Api::Client.new(api_key: ENV["GW2_API_KEY"])
23
-
24
- puts client.account.body
25
- puts client.achievements(ids: "1840,910")
26
- ```
27
-
28
- You can replace `ENV["GW2_API_KEY"]` with your own API Key, or set the env variable
29
-
30
- A list of available functions can be found `lib/gw2/modules`.
31
-
32
- You can find valid parameters for each function in the [Guild Wars 2 API documentation](https://wiki.guildwars2.com/wiki/API:Main) or from the public [API-CDI](https://github.com/arenanet/api-cdi) repo.
33
-
34
- ## Tests
35
-
36
- To run the tests, execute:
37
-
38
- $ bundle exec rspec
39
-
40
- Note that you need to set a valid API key in the environment variable `GW2_API_KEY` to run the tests.
41
- GW2's API Availability can affect the result of the tests (if it's down, the tests will fail).
42
-
43
- ## Development
44
-
45
- After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
46
-
47
- To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
48
-
49
- ## Contributing
50
-
51
- Bug reports and pull requests are welcome on GitHub at https://github.com/nicholasrobertm/gw2-api.
52
-
53
- ## License
54
-
55
- The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
56
-
57
- ## Code of Conduct
58
-
59
- Be a decent person, and don't be a jerk, it's that simple!
1
+ # Gw2::Api
2
+
3
+ This is a gem used to make calls to the Guild Wars 2 API.
4
+
5
+ ## Installation
6
+
7
+ Install the gem and add to the application's Gemfile by executing:
8
+
9
+ $ bundle add gw2-api
10
+
11
+ If bundler is not being used to manage dependencies, install the gem by executing:
12
+
13
+ $ gem install gw2-api
14
+
15
+ ## Usage
16
+
17
+ To use the gem, first require it in the application, then create a new instance of the `Gw2::Api::Client` class:
18
+
19
+ ```ruby
20
+ require 'gw2-api'
21
+
22
+ client = Gw2::Api::Client.new(api_key: ENV["GW2_API_KEY"])
23
+
24
+ puts client.account.body
25
+ puts client.achievements(ids: "1840,910")
26
+ ```
27
+
28
+ You can replace `ENV["GW2_API_KEY"]` with your own API Key, or set the env variable
29
+
30
+ A list of available functions can be found `lib/gw2/modules`.
31
+
32
+ You can find valid parameters for each function in the [Guild Wars 2 API documentation](https://wiki.guildwars2.com/wiki/API:Main) or from the public [API-CDI](https://github.com/arenanet/api-cdi) repo.
33
+
34
+ ## Tests
35
+
36
+ To run the tests, execute:
37
+
38
+ $ bundle exec rspec
39
+
40
+ Note that you need to set a valid API key in the environment variable `GW2_API_KEY` to run the tests.
41
+ GW2's API Availability can affect the result of the tests (if it's down, the tests will fail).
42
+
43
+ ## Development
44
+
45
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
46
+
47
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
48
+
49
+ ## Contributing
50
+
51
+ Bug reports and pull requests are welcome on GitHub at https://github.com/nicholasrobertm/gw2-api.
52
+
53
+ ## License
54
+
55
+ The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
56
+
57
+ ## Code of Conduct
58
+
59
+ Be a decent person, and don't be a jerk, it's that simple!
data/Rakefile CHANGED
@@ -5,8 +5,4 @@ require "rspec/core/rake_task"
5
5
 
6
6
  RSpec::Core::RakeTask.new(:spec)
7
7
 
8
- require "rubocop/rake_task"
9
-
10
- RuboCop::RakeTask.new
11
-
12
- task default: %i[spec rubocop]
8
+ task default: %i[spec]
data/gw2-api.gemspec ADDED
@@ -0,0 +1,38 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "lib/gw2/api/version"
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = "gw2-api"
7
+ spec.version = Gw2::Api::VERSION
8
+ spec.authors = ["Rob Nicholas"]
9
+ spec.email = ["rob@projectshiba.com"]
10
+
11
+ spec.summary = "This is an API wrapper for the Guild Wars 2 API."
12
+ spec.description = "This is a wrapper to the Guild Wars 2 API. It is designed to make it easier to interact with the API and to provide a more Ruby-like interface to the data provided by the API."
13
+ spec.homepage = "https://github.com/nicholasrobertm/gw2-api"
14
+ spec.license = "MIT"
15
+ spec.required_ruby_version = ">= 2.6.0"
16
+
17
+ spec.metadata["allowed_push_host"] = "https://rubygems.org"
18
+
19
+ spec.metadata["homepage_uri"] = spec.homepage
20
+ spec.metadata["source_code_uri"] = "https://github.com/nicholasrobertm/gw2-api"
21
+ spec.metadata["changelog_uri"] = "https://github.com/nicholasrobertm/gw2-api"
22
+
23
+ # Specify which files should be added to the gem when it is released.
24
+ # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
25
+ spec.files = Dir.chdir(__dir__) do
26
+ `git ls-files -z`.split("\x0").reject do |f|
27
+ (f == __FILE__) || f.match(%r{\A(?:(?:bin|test|spec|features)/|\.(?:git|circleci)|appveyor)})
28
+ end
29
+ end
30
+ spec.bindir = "exe"
31
+ spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
32
+ spec.require_paths = ["lib"]
33
+
34
+ spec.add_dependency "rake", "~> 13.0"
35
+ spec.add_dependency "rspec", "~> 3.0"
36
+ spec.add_dependency "rubocop", "~> 1.21"
37
+
38
+ end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Gw2
4
4
  module Api
5
- VERSION = "0.3.0"
5
+ VERSION = "0.4.0"
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gw2-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rob Nicholas
@@ -69,6 +69,7 @@ files:
69
69
  - LICENSE.txt
70
70
  - README.md
71
71
  - Rakefile
72
+ - gw2-api.gemspec
72
73
  - lib/gw2/api.rb
73
74
  - lib/gw2/api/version.rb
74
75
  - lib/gw2/modules/account.rb
@@ -100,7 +101,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
100
101
  - !ruby/object:Gem::Version
101
102
  version: '0'
102
103
  requirements: []
103
- rubygems_version: 3.4.1
104
+ rubygems_version: 3.5.11
104
105
  signing_key:
105
106
  specification_version: 4
106
107
  summary: This is an API wrapper for the Guild Wars 2 API.