vim_printer 0.1.11 → 0.1.12
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/CHANGELOG.md +8 -0
- data/README.md +27 -4
- data/lib/vim_printer/cli.rb +2 -2
- data/lib/vim_printer/version.rb +1 -1
- data/test/fixtures/inputs/vim_printer_output.tar.gz +0 -0
- data/vim_printer.gemspec +3 -3
- metadata +26 -24
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4e4212cc2eebca0ac9a55947db02541397e80c2f
|
4
|
+
data.tar.gz: 834689283e1ca888e55063dd9c01f7396473cce7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 176854b75b08c6d55c59e6d7e1221744863ab502cf77e71c14b1907ffd5d2dd5f23ff7e3e8fae91463512d9ade816a1a3a4f5fa61481c3f4dccc22bef106eb23
|
7
|
+
data.tar.gz: 08375a5ea2027ba75142896e5790a0ac0b8dc0b53644b11180ada8bb352555422973bf82e92129f445334c3b5dcb2e938ca0dcbd9906b7b2bfb193921dc41464
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
1
|
### Changelog
|
2
2
|
|
3
|
+
#### 0.1.12
|
4
|
+
|
5
|
+
- Update gemspec to be more precise about gem versions used
|
6
|
+
- Use the latest version of `code_lister` (0.1.17)
|
7
|
+
- Use the latest version of `agile_utils` (0.1.4)
|
8
|
+
- Use the latest version of `index_html` (0.1.4)
|
9
|
+
- Add example detail on how to run with `--command` option
|
10
|
+
|
3
11
|
#### 0.1.11
|
4
12
|
|
5
13
|
- Use lastest version of `code_lister` (0.1.4)
|
data/README.md
CHANGED
@@ -141,20 +141,43 @@ My personal use-cases:
|
|
141
141
|
e.g. Print out any files that were changed in the last 2 commit
|
142
142
|
|
143
143
|
```shell
|
144
|
-
|
144
|
+
# Must be run from inside the project directory containging the git project
|
145
|
+
vim_printer --command 'git diff --name-only HEAD~2'
|
145
146
|
```
|
146
147
|
|
147
|
-
- Use list of file from the result of `find` with `grep` command
|
148
|
+
- Use list of file from the result of `find` with `grep` command (from inside the project directory)
|
148
149
|
|
149
150
|
```shell
|
150
151
|
vim_printer --command 'find . -type f -iname "*.rb" | grep -v _spec'
|
151
152
|
```
|
152
153
|
|
153
|
-
|
154
|
+
### Limitation/Workaround
|
155
|
+
|
156
|
+
- The `--base-dir` must be used with the `--command` if the command is not run in the context of current directory.
|
157
|
+
|
158
|
+
e.g. Assume that you want to print all of the ruby `*.rb` files from `~/Desktop/project` and you are not currently
|
159
|
+
inside the `~/Desktop/project` directory
|
154
160
|
|
155
161
|
```
|
156
|
-
|
162
|
+
# Go to home directory
|
163
|
+
cd ~
|
164
|
+
|
165
|
+
# Note we are not inside the `~/Desktop/project` directory
|
166
|
+
vim_printer --command "find ~/Desktop/project -type f -iname '*.rb'" --base-dir ~/Desktop/project
|
167
|
+
```
|
168
|
+
|
169
|
+
Will give the proper links in the generated `index.html` file
|
170
|
+
|
171
|
+
But
|
172
|
+
|
173
|
+
```
|
174
|
+
# Go to home directory
|
175
|
+
cd ~
|
176
|
+
|
177
|
+
# Run the command from the home directory
|
178
|
+
vim_printer --command "find ~/Desktop/project -type f -iname '*.rb'" --base-dir .
|
157
179
|
```
|
180
|
+
will produces the invalid links in the generated `index.html` file
|
158
181
|
|
159
182
|
### Usage/Synopsys
|
160
183
|
|
data/lib/vim_printer/cli.rb
CHANGED
@@ -89,11 +89,11 @@ Print files to (x)html using Vim
|
|
89
89
|
# ["./Gemfile", "./lib/vim_printer/cli.rb", ..]
|
90
90
|
def get_input_files(args = {})
|
91
91
|
command = args.fetch(:command, nil)
|
92
|
-
base_dir = args[:base_dir]
|
93
92
|
if command.nil?
|
94
93
|
CodeLister.files(args)
|
95
94
|
else
|
96
|
-
|
95
|
+
# Note: base_dir must be the the same the directory where the command is executed from
|
96
|
+
CodeLister.files_from_shell(command, args.fetch(:base_dir, "."))
|
97
97
|
end
|
98
98
|
end
|
99
99
|
|
data/lib/vim_printer/version.rb
CHANGED
Binary file
|
data/vim_printer.gemspec
CHANGED
@@ -24,9 +24,9 @@ Gem::Specification.new do |spec|
|
|
24
24
|
spec.test_files = Dir.glob("{test}/**/*")
|
25
25
|
spec.require_paths = ["lib"]
|
26
26
|
spec.add_runtime_dependency "thor", "~> 0.19"
|
27
|
-
spec.add_runtime_dependency "code_lister", "~> 0.1.
|
28
|
-
spec.add_runtime_dependency "index_html", "~> 0.1"
|
29
|
-
spec.add_runtime_dependency "agile_utils", "~> 0.1"
|
27
|
+
spec.add_runtime_dependency "code_lister", "~> 0.1.7"
|
28
|
+
spec.add_runtime_dependency "index_html", "~> 0.1.4"
|
29
|
+
spec.add_runtime_dependency "agile_utils", "~> 0.1.4"
|
30
30
|
spec.add_development_dependency "bundler", "~> 1.3"
|
31
31
|
spec.add_development_dependency "rake"
|
32
32
|
spec.add_development_dependency "awesome_print", "~> 1.2"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: vim_printer
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Burin Choomnuan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-06-
|
11
|
+
date: 2014-06-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|
@@ -30,42 +30,42 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.1.
|
33
|
+
version: 0.1.7
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 0.1.
|
40
|
+
version: 0.1.7
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: index_html
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 0.1.4
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 0.1.4
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: agile_utils
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 0.1.4
|
62
62
|
type: :runtime
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 0.1.4
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: bundler
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
@@ -253,6 +253,7 @@ files:
|
|
253
253
|
- test/fixtures/inputs/java/demo4.yyy.java
|
254
254
|
- test/fixtures/inputs/noexts1_zzz
|
255
255
|
- test/fixtures/inputs/noexts2_zzz
|
256
|
+
- test/fixtures/inputs/vim_printer_output.tar.gz
|
256
257
|
- test/fixtures/outputs/demo1.xxx.rb.xhtml
|
257
258
|
- test/fixtures/outputs/demo1.yyy.rb.xhtml
|
258
259
|
- test/fixtures/outputs/demo2.xxx.rb.xhtml
|
@@ -290,24 +291,25 @@ specification_version: 4
|
|
290
291
|
summary: Batch convert multiple files to htmls using the power of Vim. Work will any
|
291
292
|
languages that can be open with Vim e.g. any non-binary files.
|
292
293
|
test_files:
|
293
|
-
- test/
|
294
|
-
- test/
|
295
|
-
- test/fixtures/
|
296
|
-
- test/fixtures/
|
297
|
-
- test/fixtures/outputs/java/demo4.yyy.java.xhtml
|
298
|
-
- test/fixtures/outputs/java/demo3.yyy.java.xhtml
|
299
|
-
- test/fixtures/outputs/java/demo4.xxx.java.xhtml
|
300
|
-
- test/fixtures/outputs/demo2.xxx.rb.xhtml
|
301
|
-
- test/fixtures/outputs/demo1.yyy.rb.xhtml
|
302
|
-
- test/fixtures/outputs/demo2.yyy.rb.xhtml
|
303
|
-
- test/fixtures/inputs/noexts2_zzz
|
294
|
+
- test/fixtures/inputs/demo1.xxx.rb
|
295
|
+
- test/fixtures/inputs/demo1.yyy.rb
|
296
|
+
- test/fixtures/inputs/demo2.xxx.rb
|
297
|
+
- test/fixtures/inputs/demo2.yyy.rb
|
304
298
|
- test/fixtures/inputs/java/demo3.xxx.java
|
305
|
-
- test/fixtures/inputs/java/demo4.xxx.java
|
306
299
|
- test/fixtures/inputs/java/demo3.yyy.java
|
300
|
+
- test/fixtures/inputs/java/demo4.xxx.java
|
307
301
|
- test/fixtures/inputs/java/demo4.yyy.java
|
308
|
-
- test/fixtures/inputs/demo2.yyy.rb
|
309
|
-
- test/fixtures/inputs/demo1.yyy.rb
|
310
|
-
- test/fixtures/inputs/demo2.xxx.rb
|
311
302
|
- test/fixtures/inputs/noexts1_zzz
|
312
|
-
- test/fixtures/inputs/
|
303
|
+
- test/fixtures/inputs/noexts2_zzz
|
304
|
+
- test/fixtures/inputs/vim_printer_output.tar.gz
|
305
|
+
- test/fixtures/outputs/demo1.xxx.rb.xhtml
|
306
|
+
- test/fixtures/outputs/demo1.yyy.rb.xhtml
|
307
|
+
- test/fixtures/outputs/demo2.xxx.rb.xhtml
|
308
|
+
- test/fixtures/outputs/demo2.yyy.rb.xhtml
|
309
|
+
- test/fixtures/outputs/java/demo3.xxx.java.xhtml
|
310
|
+
- test/fixtures/outputs/java/demo3.yyy.java.xhtml
|
311
|
+
- test/fixtures/outputs/java/demo4.xxx.java.xhtml
|
312
|
+
- test/fixtures/outputs/java/demo4.yyy.java.xhtml
|
313
|
+
- test/lib/vim_printer/test_cli.rb
|
314
|
+
- test/test_helper.rb
|
313
315
|
has_rdoc:
|