org_tp 0.0.11 → 0.0.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.org +35 -10
- data/examples/0100_basic.rb +12 -8
- data/examples/0120_default_options.rb +16 -16
- data/lib/org_tp/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8d54540c561e7433f373842cf671decf365f0c7f
|
4
|
+
data.tar.gz: 5541d5b5074820e452a6e45e3bd1c6bc679ba217
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 86ca520eaed9ab8f8e8cfba447b31f7852741690a1e26fa726dbfca6a774cd786e2a0cd7c07d14a2c2a0f385a26bafb69d722933df9795595e246613f85c61d2
|
7
|
+
data.tar.gz: 63c6a43f9348768c678ff47fd7944c0c92ea8ff4e250b50ef5113fee8d499b17240091dd65b833b402103128bd9ce0559c49097cb2d5d626f4411f493657b8e2
|
data/README.org
CHANGED
@@ -36,7 +36,7 @@ tp [{id: 1, name: 'alice'}, {id: 2, name: 'bob'}]
|
|
36
36
|
#+BEGIN_SRC ruby
|
37
37
|
tp({id: 1, name: 'alice'})
|
38
38
|
# >> |------+-------|
|
39
|
-
# >> |
|
39
|
+
# >> | id | 1 |
|
40
40
|
# >> | name | alice |
|
41
41
|
# >> |------+-------|
|
42
42
|
#+END_SRC
|
@@ -102,7 +102,7 @@ tp User.limit(1)
|
|
102
102
|
#+BEGIN_SRC ruby
|
103
103
|
tp User.first
|
104
104
|
# >> |------+-------|
|
105
|
-
# >> |
|
105
|
+
# >> | id | 1 |
|
106
106
|
# >> | name | alice |
|
107
107
|
# >> |------+-------|
|
108
108
|
#+END_SRC
|
@@ -119,6 +119,31 @@ tp ActiveRecord::Base.connection.select_all('SELECT * FROM users')
|
|
119
119
|
# >> |----+-------|
|
120
120
|
#+END_SRC
|
121
121
|
|
122
|
+
** Various alias
|
123
|
+
|
124
|
+
*pt* and *tt* are alias of *tp*
|
125
|
+
|
126
|
+
#+BEGIN_SRC ruby
|
127
|
+
pt :ok
|
128
|
+
# >> |----|
|
129
|
+
# >> | ok |
|
130
|
+
# >> |----|
|
131
|
+
#+END_SRC
|
132
|
+
|
133
|
+
#+BEGIN_SRC ruby
|
134
|
+
tp :ok
|
135
|
+
# >> |----|
|
136
|
+
# >> | ok |
|
137
|
+
# >> |----|
|
138
|
+
#+END_SRC
|
139
|
+
|
140
|
+
#+BEGIN_SRC ruby
|
141
|
+
tt :ok
|
142
|
+
# >> |----|
|
143
|
+
# >> | ok |
|
144
|
+
# >> |----|
|
145
|
+
#+END_SRC
|
146
|
+
|
122
147
|
** How to table as string
|
123
148
|
|
124
149
|
Use to_t method.
|
@@ -174,15 +199,15 @@ tp [{id: 1, name: 'alice'}, {id: 2, name: 'bob'}], intersection: '|', cover: fal
|
|
174
199
|
#+BEGIN_SRC ruby
|
175
200
|
tp OrgTp.default_options
|
176
201
|
# >> |-------------------+-------|
|
177
|
-
# >> |
|
178
|
-
# >> |
|
179
|
-
# >> |
|
180
|
-
# >> |
|
181
|
-
# >> |
|
202
|
+
# >> | markdown | false |
|
203
|
+
# >> | header | |
|
204
|
+
# >> | cover | true |
|
205
|
+
# >> | vertical | | |
|
206
|
+
# >> | intersection | + |
|
182
207
|
# >> | intersection_both | | |
|
183
|
-
# >> |
|
184
|
-
# >> |
|
185
|
-
# >> |
|
208
|
+
# >> | horizon | - |
|
209
|
+
# >> | padding | |
|
210
|
+
# >> | in_code | UTF-8 |
|
186
211
|
# >> |-------------------+-------|
|
187
212
|
|
188
213
|
tp 1
|
data/examples/0100_basic.rb
CHANGED
@@ -1,8 +1,9 @@
|
|
1
1
|
$LOAD_PATH << '../lib'
|
2
2
|
require 'org_tp'
|
3
3
|
|
4
|
-
pt
|
5
|
-
tp
|
4
|
+
pt :ok
|
5
|
+
tp :ok
|
6
|
+
tt :ok
|
6
7
|
tp 'foo'
|
7
8
|
tp :foo
|
8
9
|
tp [:alice, :bob]
|
@@ -11,12 +12,15 @@ tp [{id: 1, name: 'alice'}, {id: 2, name: 'bob'}]
|
|
11
12
|
puts [{id: 1, name: 'alice'}, {id: 2, name: 'bob'}].to_t
|
12
13
|
puts [{'a': ['a']}].to_t
|
13
14
|
puts [{'a': {'a': 1}}].to_t
|
14
|
-
# >>
|
15
|
-
# >> |
|
16
|
-
# >>
|
17
|
-
# >>
|
18
|
-
# >> |
|
19
|
-
# >>
|
15
|
+
# >> |----|
|
16
|
+
# >> | ok |
|
17
|
+
# >> |----|
|
18
|
+
# >> |----|
|
19
|
+
# >> | ok |
|
20
|
+
# >> |----|
|
21
|
+
# >> |----|
|
22
|
+
# >> | ok |
|
23
|
+
# >> |----|
|
20
24
|
# >> |-----|
|
21
25
|
# >> | foo |
|
22
26
|
# >> |-----|
|
@@ -11,24 +11,24 @@ tp OrgTp.default_options
|
|
11
11
|
# >> | 1 |
|
12
12
|
# >> +---+
|
13
13
|
# >> |-------------------+-------|
|
14
|
-
# >> |
|
15
|
-
# >> |
|
16
|
-
# >> |
|
17
|
-
# >> |
|
18
|
-
# >> |
|
14
|
+
# >> | markdown | false |
|
15
|
+
# >> | header | |
|
16
|
+
# >> | cover | true |
|
17
|
+
# >> | vertical | | |
|
18
|
+
# >> | intersection | + |
|
19
19
|
# >> | intersection_both | | |
|
20
|
-
# >> |
|
21
|
-
# >> |
|
22
|
-
# >> |
|
20
|
+
# >> | horizon | - |
|
21
|
+
# >> | padding | |
|
22
|
+
# >> | in_code | UTF-8 |
|
23
23
|
# >> |-------------------+-------|
|
24
24
|
# >> +-------------------+-------+
|
25
|
-
# >> |
|
26
|
-
# >> |
|
27
|
-
# >> |
|
28
|
-
# >> |
|
29
|
-
# >> |
|
25
|
+
# >> | markdown | false |
|
26
|
+
# >> | header | |
|
27
|
+
# >> | cover | true |
|
28
|
+
# >> | vertical | | |
|
29
|
+
# >> | intersection | + |
|
30
30
|
# >> | intersection_both | + |
|
31
|
-
# >> |
|
32
|
-
# >> |
|
33
|
-
# >> |
|
31
|
+
# >> | horizon | - |
|
32
|
+
# >> | padding | |
|
33
|
+
# >> | in_code | UTF-8 |
|
34
34
|
# >> +-------------------+-------+
|
data/lib/org_tp/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: org_tp
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- akicho8
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-09-
|
11
|
+
date: 2017-09-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|