bibtex_to_scrapbox 0.1.0 → 0.2.0

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: e7264a9ab6d4b3d17073eac2336355818d6cf6a2
4
- data.tar.gz: 6124a1ad6f125e08fb8654efc3a273a0c6478492
3
+ metadata.gz: 25e4ad6cf53cca3fefc23d46d4ee9fc216d8ae59
4
+ data.tar.gz: ad6e3eefb017330ba8fc02a0e44b725330e934ff
5
5
  SHA512:
6
- metadata.gz: 0f4b268c5514022bc19a52e3e86da4636e6766b2e8d515c852a451a2b20ea75e38fc95dacc6587f8605e4ab8dffe53017d932d10ce2e9300c78203bf79031b4d
7
- data.tar.gz: e01ae2fa64cfd487710a935b1257764776e7657e3fb609d9aad18b881f08f8351266a5f1f2a256076c9070ecdb7870547533728cef59549083c1b67b4c22b500
6
+ metadata.gz: a7f9f682b5f2a3053e7f39f1ff26840ef9a3702826885dd243ad686bfdd55f7280a3cd9608ddf8ab1c97760bd75abdb62895cad2a7bd7a4d2d0d0fef0cd469d1
7
+ data.tar.gz: f57fe9e84d51a5b13827506965d1c4e4361dbcf845c486d11ca5d6a60c318a7e93d8312f9f219de5db25e231e9680173798da3732409865fb60479064cdd6777
@@ -9,7 +9,7 @@ module BibtexToScrapbox
9
9
  @@converters.push Converter.new(path)
10
10
  end
11
11
 
12
- def Converter.start()
12
+ def Converter.perform()
13
13
  pages=[]
14
14
  @@converters.map do |converter|
15
15
  pages.concat converter.start()
@@ -1,3 +1,3 @@
1
1
  module BibtexToScrapbox
2
- VERSION = "0.1.0"
2
+ VERSION = "0.2.0"
3
3
  end
data/lib/cli.rb CHANGED
@@ -9,10 +9,16 @@ module BibtexToScrapbox
9
9
 
10
10
  desc 'convert FILES [options]', 'Convert bibtex files to scrapbox-json'
11
11
  def convert(*paths)
12
- paths.each do |path|
13
- BibtexToScrapbox::Converter.add(path)
12
+ if paths.length > 0
13
+ paths.each do |path|
14
+ BibtexToScrapbox::Converter.add(path)
15
+ end
16
+ else
17
+ while path=$stdin.gets
18
+ BibtexToScrapbox::Converter.add(path.chomp)
19
+ end
14
20
  end
15
- BibtexToScrapbox::Converter.start()
21
+ BibtexToScrapbox::Converter.perform()
16
22
  end
17
23
 
18
24
  desc 'version', 'version'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bibtex_to_scrapbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hiroharu Sugawara
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-07-27 00:00:00.000000000 Z
11
+ date: 2017-08-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler