toon-fu 4.1.3 → 4.1.4
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/README.md +19 -0
- data/exe/toon +13 -0
- data/lib/toon_fu/version.rb +1 -1
- metadata +5 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4a5a734c469d08f497c36883702683c8a1c7edc3245df9f886d5f6159ff26db1
|
|
4
|
+
data.tar.gz: 784178fff8819a4895e5252b8e356ffaddaceca1ff10d9d6067a73984d5ef8cc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4acf57be096b69fa1c675a97efb59fe63db7b66234e649305f5cb1dafa319465fa3ffb235d2aa252dd714861476720a910b7859e6916dc6ba45584b1d75a886c
|
|
7
|
+
data.tar.gz: 3ba5aa86ccfae68c53da20cfaa66a31d3ddee6b5e57af7c72f3ef884d36be45fe485b234973cd6cef2b31d1751d482d1f36b20a9d5eff746f02ff486ccc997e3
|
data/README.md
CHANGED
|
@@ -147,6 +147,23 @@ decoder = ToonFu::Decoder.new(indent_size: 4) # reuse for many documents
|
|
|
147
147
|
decoder.decode(text)
|
|
148
148
|
```
|
|
149
149
|
|
|
150
|
+
## On the command line
|
|
151
|
+
|
|
152
|
+
The gem installs a `toon` executable that encodes JSON on stdin — handy for reading a command's output in fewer tokens:
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
$ gh api repos/ruby/ruby/pulls --jq '.[0] | {number, title}' | toon
|
|
156
|
+
number: 13579
|
|
157
|
+
title: Fix a typo
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
Input it cannot encode is passed through unchanged, so putting it at the end of a pipe never costs you the output:
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
$ git log --oneline -1 | toon
|
|
164
|
+
b08ea2d feat: ship a toon executable
|
|
165
|
+
```
|
|
166
|
+
|
|
150
167
|
## Compared with other Ruby TOON gems
|
|
151
168
|
|
|
152
169
|
The only one that passes every spec fixture: toon-fu passes all 179 encode and all 359 decode fixtures. The table compares encoding — the 154 encode fixtures that use default options, which every gem can run; none of the others reads TOON back.
|
|
@@ -186,6 +203,8 @@ The gem version tracks the TOON specification it implements:
|
|
|
186
203
|
- `MAJOR.MINOR` is the spec version: `X.Y.Z` speaks TOON `X.Y`.
|
|
187
204
|
- `PATCH` is the gem's own: fixes and improvements within the same dialect.
|
|
188
205
|
|
|
206
|
+
This release speaks `toon-spec: 4.1`.
|
|
207
|
+
|
|
189
208
|
Pin the spec line with `gem "toon-fu", "~> X.Y.0"`: it takes our fixes and keeps you on the dialect you speak. The gem badge above shows the current release; the spec-drift badge turns red when a newer spec is released and toon-fu has not caught up yet.
|
|
190
209
|
|
|
191
210
|
Release notes: [GitHub releases](https://github.com/hoblin/toon-fu/releases).
|
data/exe/toon
ADDED
data/lib/toon_fu/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: toon-fu
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 4.1.
|
|
4
|
+
version: 4.1.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Yevhenii Hurin
|
|
8
|
-
bindir:
|
|
8
|
+
bindir: exe
|
|
9
9
|
cert_chain: []
|
|
10
10
|
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
11
|
dependencies: []
|
|
@@ -16,12 +16,14 @@ description: 'Encodes Ruby hashes, arrays, dates and your own objects into TOON,
|
|
|
16
16
|
an error so your data arrives complete.'
|
|
17
17
|
email:
|
|
18
18
|
- evgeny.gurin@gmail.com
|
|
19
|
-
executables:
|
|
19
|
+
executables:
|
|
20
|
+
- toon
|
|
20
21
|
extensions: []
|
|
21
22
|
extra_rdoc_files: []
|
|
22
23
|
files:
|
|
23
24
|
- LICENSE
|
|
24
25
|
- README.md
|
|
26
|
+
- exe/toon
|
|
25
27
|
- lib/toon-fu.rb
|
|
26
28
|
- lib/toon_fu.rb
|
|
27
29
|
- lib/toon_fu/decimal_literal.rb
|