erc20 0.2.0 → 0.2.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.
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: erc20
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko
@@ -13,86 +13,86 @@ dependencies:
13
13
  name: eth
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - ">="
16
+ - - "~>"
17
17
  - !ruby/object:Gem::Version
18
- version: 0.5.13
18
+ version: '0.5'
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
- - - ">="
23
+ - - "~>"
24
24
  - !ruby/object:Gem::Version
25
- version: 0.5.13
25
+ version: '0.5'
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: faye-websocket
28
28
  requirement: !ruby/object:Gem::Requirement
29
29
  requirements:
30
- - - ">="
30
+ - - "~>"
31
31
  - !ruby/object:Gem::Version
32
- version: 0.11.3
32
+ version: '0.11'
33
33
  type: :runtime
34
34
  prerelease: false
35
35
  version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
- - - ">="
37
+ - - "~>"
38
38
  - !ruby/object:Gem::Version
39
- version: 0.11.3
39
+ version: '0.11'
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: json
42
42
  requirement: !ruby/object:Gem::Requirement
43
43
  requirements:
44
- - - ">="
44
+ - - "~>"
45
45
  - !ruby/object:Gem::Version
46
- version: 2.10.1
46
+ version: '2.10'
47
47
  type: :runtime
48
48
  prerelease: false
49
49
  version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
- - - ">="
51
+ - - "~>"
52
52
  - !ruby/object:Gem::Version
53
- version: 2.10.1
53
+ version: '2.10'
54
54
  - !ruby/object:Gem::Dependency
55
55
  name: jsonrpc-client
56
56
  requirement: !ruby/object:Gem::Requirement
57
57
  requirements:
58
- - - ">="
58
+ - - "~>"
59
59
  - !ruby/object:Gem::Version
60
- version: 0.1.4
60
+ version: '0.1'
61
61
  type: :runtime
62
62
  prerelease: false
63
63
  version_requirements: !ruby/object:Gem::Requirement
64
64
  requirements:
65
- - - ">="
65
+ - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: 0.1.4
67
+ version: '0.1'
68
68
  - !ruby/object:Gem::Dependency
69
69
  name: loog
70
70
  requirement: !ruby/object:Gem::Requirement
71
71
  requirements:
72
- - - ">"
72
+ - - "~>"
73
73
  - !ruby/object:Gem::Version
74
- version: '0'
74
+ version: '0.4'
75
75
  type: :runtime
76
76
  prerelease: false
77
77
  version_requirements: !ruby/object:Gem::Requirement
78
78
  requirements:
79
- - - ">"
79
+ - - "~>"
80
80
  - !ruby/object:Gem::Version
81
- version: '0'
81
+ version: '0.4'
82
82
  - !ruby/object:Gem::Dependency
83
83
  name: slop
84
84
  requirement: !ruby/object:Gem::Requirement
85
85
  requirements:
86
- - - ">"
86
+ - - "~>"
87
87
  - !ruby/object:Gem::Version
88
- version: '4'
88
+ version: '4.0'
89
89
  type: :runtime
90
90
  prerelease: false
91
91
  version_requirements: !ruby/object:Gem::Requirement
92
92
  requirements:
93
- - - ">"
93
+ - - "~>"
94
94
  - !ruby/object:Gem::Version
95
- version: '4'
95
+ version: '4.0'
96
96
  description: 'A simple library for making ERC20 manipulations as easy as they can
97
97
  be for cryptocurrency newbies: checking balance, sending payments, and monitoring
98
98
  addresses for incoming payments. The library expects Ethereum node to provide JSON
@@ -105,26 +105,6 @@ extra_rdoc_files:
105
105
  - LICENSE.txt
106
106
  - README.md
107
107
  files:
108
- - ".0pdd.yml"
109
- - ".gitattributes"
110
- - ".github/workflows/actionlint.yml"
111
- - ".github/workflows/codecov.yml"
112
- - ".github/workflows/copyrights.yml"
113
- - ".github/workflows/hadolint.yml"
114
- - ".github/workflows/markdown-lint.yml"
115
- - ".github/workflows/pdd.yml"
116
- - ".github/workflows/rake.yml"
117
- - ".github/workflows/reuse.yml"
118
- - ".github/workflows/shellcheck.yml"
119
- - ".github/workflows/typos.yml"
120
- - ".github/workflows/xcop.yml"
121
- - ".github/workflows/yamllint.yml"
122
- - ".gitignore"
123
- - ".gitleaksignore"
124
- - ".pdd"
125
- - ".rubocop.yml"
126
- - ".rultor.yml"
127
- - ".yamllint.yml"
128
108
  - Gemfile
129
109
  - Gemfile.lock
130
110
  - LICENSE.txt
@@ -148,12 +128,7 @@ files:
148
128
  - lib/erc20/erc20.rb
149
129
  - lib/erc20/fake_wallet.rb
150
130
  - lib/erc20/wallet.rb
151
- - renovate.json
152
- - test/erc20/test_fake_wallet.rb
153
- - test/erc20/test_wallet.rb
154
- - test/erc20/test_wallet_live.rb
155
- - test/test__helper.rb
156
- homepage: http://github.com/yegor256/erc20.rb
131
+ homepage: https://github.com/yegor256/erc20.rb
157
132
  licenses:
158
133
  - MIT
159
134
  metadata:
@@ -164,7 +139,7 @@ require_paths:
164
139
  - lib
165
140
  required_ruby_version: !ruby/object:Gem::Requirement
166
141
  requirements:
167
- - - ">="
142
+ - - "~>"
168
143
  - !ruby/object:Gem::Version
169
144
  version: '3.0'
170
145
  required_rubygems_version: !ruby/object:Gem::Requirement
@@ -173,7 +148,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
173
148
  - !ruby/object:Gem::Version
174
149
  version: '0'
175
150
  requirements: []
176
- rubygems_version: 3.6.7
151
+ rubygems_version: 3.6.9
177
152
  specification_version: 4
178
153
  summary: Sending and receiving ERC20 tokens in Ethereum network
179
154
  test_files: []
data/.0pdd.yml DELETED
@@ -1,5 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- errors:
5
- - yegor256@gmail.com
data/.gitattributes DELETED
@@ -1,7 +0,0 @@
1
- # Check out all text files in UNIX format, with LF as end of line
2
- # Don't change this file. If you have any ideas about it, please
3
- # submit a separate issue about it and we'll discuss.
4
-
5
- * text=auto eol=lf
6
- *.java ident
7
- *.xml ident
@@ -1,25 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: actionlint
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- actionlint:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - name: Download actionlint
20
- id: get_actionlint
21
- run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
22
- shell: bash
23
- - name: Check workflow files
24
- run: ${{ steps.get_actionlint.outputs.executable }} -color
25
- shell: bash
@@ -1,27 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: codecov
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- jobs:
11
- codecov:
12
- timeout-minutes: 15
13
- runs-on: ubuntu-24.04
14
- steps:
15
- - uses: actions/checkout@v4
16
- - uses: ruby/setup-ruby@v1
17
- with:
18
- ruby-version: 3.3
19
- bundler-cache: true
20
- - run: bundle config set --global path "$(pwd)/vendor/bundle"
21
- - run: bundle install --no-color
22
- - run: bundle exec rake
23
- - uses: codecov/codecov-action@v5
24
- with:
25
- token: ${{ secrets.CODECOV_TOKEN }}
26
- files: coverage/.resultset.json
27
- fail_ci_if_error: true
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: copyrights
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- copyrights:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: yegor256/copyrights-action@0.0.8
@@ -1,16 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- name: hadolint
5
- 'on':
6
- push:
7
- pull_request:
8
- jobs:
9
- hadolint:
10
- timeout-minutes: 15
11
- runs-on: ubuntu-24.04
12
- steps:
13
- - uses: actions/checkout@v4
14
- - uses: hadolint/hadolint-action@v3.1.0
15
- with:
16
- dockerfile: hardhat/Dockerfile
@@ -1,23 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: markdown-lint
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- paths-ignore: ['paper/**', 'sandbox/**']
14
- concurrency:
15
- group: markdown-lint-${{ github.ref }}
16
- cancel-in-progress: true
17
- jobs:
18
- markdown-lint:
19
- timeout-minutes: 15
20
- runs-on: ubuntu-24.04
21
- steps:
22
- - uses: actions/checkout@v4
23
- - uses: articulate/actions-markdownlint@v1
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: pdd
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- pdd:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: volodya-lombrozo/pdd-action@master
@@ -1,38 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: rake
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- rake:
15
- strategy:
16
- matrix:
17
- os: [ubuntu-24.04]
18
- ruby: [3.3]
19
- runs-on: ${{ matrix.os }}
20
- env:
21
- INFURA_KEY: ${{ secrets.INFURA_KEY }}
22
- GETBLOCK_KEY: ${{ secrets.GETBLOCK_KEY }}
23
- GETBLOCK_SEPOILA_KEY: ${{ secrets.GETBLOCK_SEPOILA_KEY }}
24
- steps:
25
- - uses: actions/checkout@v4
26
- - run: |
27
- sudo apt-get update --yes --fix-missing
28
- sudo apt-get install --yes autoconf
29
- if: matrix.os == 'ubuntu-24.04'
30
- - run: brew install automake
31
- if: matrix.os == 'macos-15'
32
- - uses: ruby/setup-ruby@v1
33
- with:
34
- ruby-version: ${{ matrix.ruby }}
35
- bundler-cache: true
36
- - run: bundle config set --global path "$(pwd)/vendor/bundle"
37
- - run: bundle install --no-color
38
- - run: bundle exec rake
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: reuse
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- reuse:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: fsfe/reuse-action@v5
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: shellcheck
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- shellcheck:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: ludeeus/action-shellcheck@master
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: typos
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- typos:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: crate-ci/typos@v1.32.0
@@ -1,19 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: xcop
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- xcop:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: g4s8/xcop-action@master
@@ -1,21 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- name: yamllint
6
- 'on':
7
- push:
8
- branches:
9
- - master
10
- pull_request:
11
- branches:
12
- - master
13
- jobs:
14
- yamllint:
15
- timeout-minutes: 15
16
- runs-on: ubuntu-24.04
17
- steps:
18
- - uses: actions/checkout@v4
19
- - uses: ibiqlik/action-yamllint@v3
20
- with:
21
- config_file: .yamllint.yml
data/.gitignore DELETED
@@ -1,10 +0,0 @@
1
- .bundle/
2
- .DS_Store
3
- .idea/
4
- .yardoc/
5
- *.gem
6
- coverage/
7
- doc/
8
- node_modules/
9
- rdoc/
10
- vendor/
data/.gitleaksignore DELETED
@@ -1,2 +0,0 @@
1
- hardhat/hardhat.config.js:generic-api-key:38
2
- hardhat/hardhat.config.js:generic-api-key:42
data/.pdd DELETED
@@ -1,7 +0,0 @@
1
- --source=.
2
- --verbose
3
- --exclude target/**/*
4
- --exclude coverage/**/*
5
- --rule min-words:20
6
- --rule min-estimate:15
7
- --rule max-estimate:90
data/.rubocop.yml DELETED
@@ -1,49 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- AllCops:
5
- Exclude:
6
- - 'bin/**/*'
7
- - 'assets/**/*'
8
- - 'vendor/**/**'
9
- DisplayCopNames: true
10
- TargetRubyVersion: 3.2
11
- SuggestExtensions: false
12
- NewCops: enable
13
- plugins:
14
- - rubocop-performance
15
- - rubocop-rake
16
- - rubocop-minitest
17
- Minitest/EmptyLineBeforeAssertionMethods:
18
- Enabled: false
19
- Gemspec/RequiredRubyVersion:
20
- Enabled: false
21
- Metrics/MethodLength:
22
- Enabled: false
23
- Style/ClassAndModuleChildren:
24
- Enabled: false
25
- Layout/MultilineMethodCallIndentation:
26
- Enabled: false
27
- Metrics/AbcSize:
28
- Enabled: false
29
- Metrics/ParameterLists:
30
- Enabled: false
31
- Metrics/BlockLength:
32
- Max: 100
33
- Metrics/CyclomaticComplexity:
34
- Max: 25
35
- Metrics/PerceivedComplexity:
36
- Max: 30
37
- Metrics/ClassLength:
38
- Enabled: false
39
- Layout/EmptyLineAfterGuardClause:
40
- Enabled: false
41
- Naming/MethodParameterName:
42
- MinNameLength: 2
43
- Layout/EndOfLine:
44
- EnforcedStyle: lf
45
- Security/MarshalLoad:
46
- Enabled: false
47
- Layout/MultilineAssignmentLayout:
48
- Enabled: true
49
- require: []
data/.rultor.yml DELETED
@@ -1,26 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- # yamllint disable rule:line-length
5
- docker:
6
- image: yegor256/ruby
7
- assets:
8
- rubygems.yml: yegor256/home#assets/rubygems.yml
9
- install: |
10
- pdd -f /dev/null
11
- bundle install --no-color
12
- release:
13
- pre: false
14
- script: |-
15
- [[ "${tag}" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]] || exit -1
16
- DONCE_SUDO=true bundle exec rake
17
- rm -rf *.gem
18
- sed -i "s/0\.0\.0/${tag}/g" lib/erc20/erc20.rb
19
- git add lib/erc20/erc20.rb
20
- git commit -m "version set to ${tag}"
21
- gem build erc20.gemspec
22
- chmod 0600 ../rubygems.yml
23
- gem push *.gem --config-file ../rubygems.yml
24
- merge:
25
- script: |-
26
- DONCE_SUDO=true bundle exec rake
data/.yamllint.yml DELETED
@@ -1,12 +0,0 @@
1
- # SPDX-FileCopyrightText: Copyright (c) 2025 Yegor Bugayenko
2
- # SPDX-License-Identifier: MIT
3
- ---
4
- extends: default
5
- rules:
6
- line-length: disable
7
- brackets:
8
- min-spaces-inside: 0
9
- max-spaces-inside: 2
10
- truthy:
11
- level: warning
12
- allowed-values: [ 'on', 'true', 'false', 'yes', 'no' ]
data/renovate.json DELETED
@@ -1,6 +0,0 @@
1
- {
2
- "$schema": "https://docs.renovatebot.com/renovate-schema.json",
3
- "extends": [
4
- "config:base"
5
- ]
6
- }