snibbets 2.0.31 → 2.0.32
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/Gemfile.lock +1 -1
- data/README.md +1 -1
- data/lib/snibbets/version.rb +1 -1
- data/lib/snibbets.rb +5 -4
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e6701119f370f7f3a6190d811e5278799c973ed65b7f69a096b2675c91a2a124
|
|
4
|
+
data.tar.gz: 6954526979c677af6c5cf3fece76c0df0eae2f83ae2975c00e2884e99a5a2cda
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4e3cf0a812450aacd9dd69863bb4ba02880fb57049e396ab7d02eb31b024ed12aabe1f84dd4ace68b5ccc3d2c29e09c114776fde050b4bdc5708fcf01dfe5af9
|
|
7
|
+
data.tar.gz: 761105292b069c127ec2e32f0d39235883c4bd75d88b395d1a20b83b7fc6819aec0e9b5df67af14c7a2990196e5611aabf212afead13587ed2d62c2356489d34
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
|
@@ -159,7 +159,7 @@ Snibbet's implementation of Skylighting has limited but better-looking themes, a
|
|
|
159
159
|
### Usage
|
|
160
160
|
|
|
161
161
|
```
|
|
162
|
-
Snibbets v2.0.
|
|
162
|
+
Snibbets v2.0.32
|
|
163
163
|
|
|
164
164
|
Usage: snibbets [options] query
|
|
165
165
|
-a, --all If a file contains multiple snippets, output all of them (no menu)
|
data/lib/snibbets/version.rb
CHANGED
data/lib/snibbets.rb
CHANGED
|
@@ -286,6 +286,7 @@ module Snibbets
|
|
|
286
286
|
end
|
|
287
287
|
code = snip['code']
|
|
288
288
|
lang = snip['language']
|
|
289
|
+
|
|
289
290
|
print(code, filepath, lang)
|
|
290
291
|
end
|
|
291
292
|
end
|
|
@@ -349,15 +350,15 @@ module Snibbets
|
|
|
349
350
|
end
|
|
350
351
|
|
|
351
352
|
def print(output, filepath, syntax = nil)
|
|
353
|
+
if Snibbets.options[:copy]
|
|
354
|
+
OS.copy(Snibbets.options[:all_notes] ? output : output.clean_code)
|
|
355
|
+
warn 'Copied to clipboard'
|
|
356
|
+
end
|
|
352
357
|
if Snibbets.options[:highlight] && Snibbets.options[:output] == 'raw'
|
|
353
358
|
$stdout.puts(Highlight.highlight(output, filepath, syntax))
|
|
354
359
|
else
|
|
355
360
|
$stdout.puts(Snibbets.options[:all_notes] ? output : output.clean_code)
|
|
356
361
|
end
|
|
357
|
-
if Snibbets.options[:copy]
|
|
358
|
-
OS.copy(output)
|
|
359
|
-
$stderr.puts "Copied to clipboard"
|
|
360
|
-
end
|
|
361
362
|
end
|
|
362
363
|
end
|
|
363
364
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: snibbets
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.0.
|
|
4
|
+
version: 2.0.32
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Brett Terpstra
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2023-04-
|
|
11
|
+
date: 2023-04-25 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|