chatwork 1.0.0 → 1.0.2
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 +4 -4
- data/.github/dependabot.yml +12 -0
- data/.github/workflows/release_gem.yml +41 -0
- data/.github/workflows/test.yml +11 -27
- data/CHANGELOG.md +15 -1
- data/README.md +1 -1
- data/chatwork.gemspec +1 -1
- data/lib/chatwork/base_client.rb +1 -8
- data/lib/chatwork/multipart.rb +0 -2
- data/lib/chatwork/version.rb +1 -1
- metadata +7 -8
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fed09ff96338f37d85385fc5bc591f1aa3bbb10a3bfba8f8dda496d16e0f6cb6
|
|
4
|
+
data.tar.gz: c59ff6a457ed76cc3ec4b726d27af626bed5757d4dfa48125ac692e96ca03430
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 33837b97deba97b4eae2f307b937e03b29c562bca5de3b37c46c20176bfcf713ba44759d7c341d6a2542ade474ffd0f61e8ad83d83920c923d35b2367d69d87e
|
|
7
|
+
data.tar.gz: 0f97273eb31cbc1d8eeffc022f414d8f59c500eacc8de079623220d1c74e52bed8caff3e0f33fbe0497aa4d8508f2c95f63cf52bfe95749d3c20e5428d8e371e
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
# c.f. https://docs.github.com/en/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
|
|
2
|
+
version: 2
|
|
3
|
+
|
|
4
|
+
updates:
|
|
5
|
+
- package-ecosystem: github-actions
|
|
6
|
+
directory: /
|
|
7
|
+
schedule:
|
|
8
|
+
interval: weekly
|
|
9
|
+
cooldown:
|
|
10
|
+
default-days: 7
|
|
11
|
+
assignees:
|
|
12
|
+
- sue445
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
name: Publish gem to rubygems.org
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
|
|
6
|
+
jobs:
|
|
7
|
+
release:
|
|
8
|
+
if: github.repository == 'asonas/chatwork-ruby'
|
|
9
|
+
runs-on: ubuntu-latest
|
|
10
|
+
|
|
11
|
+
environment:
|
|
12
|
+
name: rubygems.org
|
|
13
|
+
url: https://rubygems.org/gems/chatwork
|
|
14
|
+
|
|
15
|
+
permissions:
|
|
16
|
+
contents: write
|
|
17
|
+
id-token: write
|
|
18
|
+
|
|
19
|
+
steps:
|
|
20
|
+
- name: Harden Runner
|
|
21
|
+
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
|
|
22
|
+
with:
|
|
23
|
+
egress-policy: audit
|
|
24
|
+
|
|
25
|
+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
|
|
26
|
+
|
|
27
|
+
- name: Set up Ruby
|
|
28
|
+
uses: ruby/setup-ruby@eaecf785f6a34567a6d97f686bbb7bccc1ac1e5c # v1.237.0
|
|
29
|
+
with:
|
|
30
|
+
bundler-cache: true
|
|
31
|
+
ruby-version: ruby
|
|
32
|
+
|
|
33
|
+
- name: Publish to RubyGems
|
|
34
|
+
uses: rubygems/release-gem@a25424ba2ba8b387abc8ef40807c2c85b96cbe32 # v1.1.1
|
|
35
|
+
|
|
36
|
+
- name: Create GitHub release
|
|
37
|
+
run: |
|
|
38
|
+
tag_name="$(git describe --tags --abbrev=0)"
|
|
39
|
+
gh release create "${tag_name}" --verify-tag --generate-notes
|
|
40
|
+
env:
|
|
41
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
data/.github/workflows/test.yml
CHANGED
|
@@ -9,61 +9,46 @@ on:
|
|
|
9
9
|
- opened
|
|
10
10
|
- synchronize
|
|
11
11
|
- reopened
|
|
12
|
-
schedule:
|
|
13
|
-
- cron: "0 10 * * 5" # JST 19:00 (Fri)
|
|
14
|
-
|
|
15
|
-
env:
|
|
16
|
-
RUBYOPT: -EUTF-8
|
|
17
12
|
|
|
18
13
|
jobs:
|
|
19
14
|
test:
|
|
20
15
|
runs-on: ubuntu-latest
|
|
21
16
|
|
|
22
|
-
container: ${{ matrix.ruby }}
|
|
23
|
-
|
|
24
17
|
strategy:
|
|
25
18
|
fail-fast: false
|
|
26
19
|
|
|
27
20
|
matrix:
|
|
28
21
|
ruby:
|
|
29
|
-
-
|
|
30
|
-
-
|
|
31
|
-
-
|
|
32
|
-
-
|
|
33
|
-
-
|
|
22
|
+
- "2.6"
|
|
23
|
+
- "2.7"
|
|
24
|
+
- "3.0"
|
|
25
|
+
- "3.1"
|
|
26
|
+
- "3.2"
|
|
27
|
+
- "3.3"
|
|
28
|
+
- "3.4"
|
|
34
29
|
gemfile:
|
|
35
30
|
- faraday_2
|
|
36
|
-
include:
|
|
37
|
-
- ruby: rubylang/ruby:master-nightly-bionic
|
|
38
|
-
allow_failures: "true"
|
|
39
31
|
|
|
40
32
|
env:
|
|
41
33
|
BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile
|
|
42
34
|
|
|
43
35
|
steps:
|
|
44
|
-
- uses: actions/checkout@
|
|
36
|
+
- uses: actions/checkout@v5
|
|
45
37
|
with:
|
|
46
38
|
submodules: "true"
|
|
47
39
|
|
|
48
|
-
-
|
|
49
|
-
uses: actions/cache@v1
|
|
50
|
-
id: cache_gem
|
|
40
|
+
- uses: ruby/setup-ruby@v1
|
|
51
41
|
with:
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
restore-keys: |
|
|
55
|
-
v1-gem-${{ runner.os }}-${{ matrix.ruby }}-
|
|
56
|
-
continue-on-error: ${{ matrix.allow_failures == 'true' }}
|
|
42
|
+
ruby-version: ${{ matrix.ruby }}
|
|
43
|
+
bundler-cache: true
|
|
57
44
|
|
|
58
45
|
- name: bundle update
|
|
59
46
|
run: |
|
|
60
47
|
set -xe
|
|
61
48
|
bundle config path vendor/bundle
|
|
62
49
|
bundle update --jobs $(nproc) --retry 3
|
|
63
|
-
continue-on-error: ${{ matrix.allow_failures == 'true' }}
|
|
64
50
|
|
|
65
51
|
- run: bundle exec rspec
|
|
66
|
-
continue-on-error: ${{ matrix.allow_failures == 'true' }}
|
|
67
52
|
|
|
68
53
|
- name: Coveralls Parallel
|
|
69
54
|
uses: coverallsapp/github-action@master
|
|
@@ -73,7 +58,6 @@ jobs:
|
|
|
73
58
|
parallel: true
|
|
74
59
|
|
|
75
60
|
- run: bundle exec rubocop
|
|
76
|
-
continue-on-error: ${{ matrix.allow_failures == 'true' }}
|
|
77
61
|
|
|
78
62
|
finish:
|
|
79
63
|
needs: test
|
data/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,20 @@
|
|
|
1
1
|
# Change Log
|
|
2
2
|
## Unreleased
|
|
3
|
-
[Full Changelog](https://github.com/asonas/chatwork-ruby/compare/v1.0.
|
|
3
|
+
[Full Changelog](https://github.com/asonas/chatwork-ruby/compare/v1.0.2...master)
|
|
4
|
+
|
|
5
|
+
## v1.0.2
|
|
6
|
+
[Full Changelog](https://github.com/asonas/chatwork-ruby/compare/v1.0.1...v1.0.2)
|
|
7
|
+
|
|
8
|
+
* Release gem from GitHub Actions
|
|
9
|
+
* https://github.com/asonas/chatwork-ruby/pull/93
|
|
10
|
+
|
|
11
|
+
## v1.0.1
|
|
12
|
+
[Full Changelog](https://github.com/asonas/chatwork-ruby/compare/v1.0.1...v1.0.0)
|
|
13
|
+
|
|
14
|
+
* Removed compatibility with old faraday
|
|
15
|
+
* https://github.com/asonas/chatwork-ruby/pull/80
|
|
16
|
+
* Fix NoMethodError: undefined method `mime_type=' for ChatWork::Multipart:Class with faraday-multipart v1.1.0+
|
|
17
|
+
* https://github.com/asonas/chatwork-ruby/pull/90
|
|
4
18
|
|
|
5
19
|
## v1.0.0
|
|
6
20
|
[Full Changelog](https://github.com/asonas/chatwork-ruby/compare/v0.12.3...v1.0.0)
|
data/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Ruby bindings of ChatWork API
|
|
4
4
|
|
|
5
5
|
[](https://badge.fury.io/rb/chatwork)
|
|
6
|
-
[](https://github.com/asonas/chatwork-ruby/actions/workflows/test.yml)
|
|
7
7
|
[](https://coveralls.io/github/asonas/chatwork-ruby)
|
|
8
8
|
|
|
9
9
|
## Installation
|
data/chatwork.gemspec
CHANGED
|
@@ -26,7 +26,7 @@ Gem::Specification.new do |spec|
|
|
|
26
26
|
|
|
27
27
|
spec.add_dependency "faraday", ">= 2.0.0"
|
|
28
28
|
spec.add_dependency "faraday-mashify"
|
|
29
|
-
spec.add_dependency "faraday-multipart"
|
|
29
|
+
spec.add_dependency "faraday-multipart", ">= 1.1.0"
|
|
30
30
|
|
|
31
31
|
spec.add_development_dependency "activesupport"
|
|
32
32
|
spec.add_development_dependency "bundler", ">= 1.3"
|
data/lib/chatwork/base_client.rb
CHANGED
|
@@ -33,16 +33,9 @@ module ChatWork
|
|
|
33
33
|
|
|
34
34
|
Faraday::Connection::METHODS.each do |method|
|
|
35
35
|
define_method(method) do |url, args = {}, &block|
|
|
36
|
-
faraday_errors =
|
|
37
|
-
if Gem::Version.create(Faraday::VERSION) >= Gem::Version.create("1.0.0")
|
|
38
|
-
[Faraday::ClientError, Faraday::ServerError]
|
|
39
|
-
else
|
|
40
|
-
[Faraday::Error::ClientError]
|
|
41
|
-
end
|
|
42
|
-
|
|
43
36
|
begin
|
|
44
37
|
response = @conn.__send__(method, @api_version + url, args.compact)
|
|
45
|
-
rescue
|
|
38
|
+
rescue Faraday::ClientError, Faraday::ServerError => e
|
|
46
39
|
raise ChatWork::APIConnectionError.faraday_error(e)
|
|
47
40
|
end
|
|
48
41
|
payload = handle_response(response)
|
data/lib/chatwork/multipart.rb
CHANGED
data/lib/chatwork/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: chatwork
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- asonas
|
|
8
8
|
- sue445
|
|
9
|
-
autorequire:
|
|
10
9
|
bindir: bin
|
|
11
10
|
cert_chain: []
|
|
12
|
-
date:
|
|
11
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
13
12
|
dependencies:
|
|
14
13
|
- !ruby/object:Gem::Dependency
|
|
15
14
|
name: faraday
|
|
@@ -45,14 +44,14 @@ dependencies:
|
|
|
45
44
|
requirements:
|
|
46
45
|
- - ">="
|
|
47
46
|
- !ruby/object:Gem::Version
|
|
48
|
-
version:
|
|
47
|
+
version: 1.1.0
|
|
49
48
|
type: :runtime
|
|
50
49
|
prerelease: false
|
|
51
50
|
version_requirements: !ruby/object:Gem::Requirement
|
|
52
51
|
requirements:
|
|
53
52
|
- - ">="
|
|
54
53
|
- !ruby/object:Gem::Version
|
|
55
|
-
version:
|
|
54
|
+
version: 1.1.0
|
|
56
55
|
- !ruby/object:Gem::Dependency
|
|
57
56
|
name: activesupport
|
|
58
57
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -286,6 +285,8 @@ extensions: []
|
|
|
286
285
|
extra_rdoc_files: []
|
|
287
286
|
files:
|
|
288
287
|
- ".env.example"
|
|
288
|
+
- ".github/dependabot.yml"
|
|
289
|
+
- ".github/workflows/release_gem.yml"
|
|
289
290
|
- ".github/workflows/test.yml"
|
|
290
291
|
- ".gitignore"
|
|
291
292
|
- ".gitmodules"
|
|
@@ -375,7 +376,6 @@ metadata:
|
|
|
375
376
|
source_code_uri: https://github.com/asonas/chatwork-ruby
|
|
376
377
|
changelog_uri: https://github.com/asonas/chatwork-ruby/blob/master/CHANGELOG.md
|
|
377
378
|
rubygems_mfa_required: 'true'
|
|
378
|
-
post_install_message:
|
|
379
379
|
rdoc_options: []
|
|
380
380
|
require_paths:
|
|
381
381
|
- lib
|
|
@@ -390,8 +390,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
390
390
|
- !ruby/object:Gem::Version
|
|
391
391
|
version: '0'
|
|
392
392
|
requirements: []
|
|
393
|
-
rubygems_version: 3.
|
|
394
|
-
signing_key:
|
|
393
|
+
rubygems_version: 3.6.7
|
|
395
394
|
specification_version: 4
|
|
396
395
|
summary: Ruby bindings of ChatWork API
|
|
397
396
|
test_files:
|