softcover 1.1.17 → 1.1.18

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: e9ecd8397f7b90187f02cac5a389639ce36f5033
4
- data.tar.gz: 76844e2a405f8ce009b7088e8561b1e4d16ad935
3
+ metadata.gz: 4ebd367166f5274d4eec03ba0bc901a1b98fe6f7
4
+ data.tar.gz: cf640ef6a793e79e3b12e50455936be08a62bddc
5
5
  SHA512:
6
- metadata.gz: a1d495c72c7279c5c76b86c76214d1f352dfbb29051078a66196e3761f9cc0917d7002056fb0a7f203f5f2a42f03f28ec4206d673965e3e863fe9b92b04f84a2
7
- data.tar.gz: 3f13e9d907d3942ef63e752c8b7083bcfee0bbd8e2a7d1d6b2376615901ebb0530481e7db8b23698bcfa1c90fb77addb71c51f96c90e5afd1add97a26394a7a1
6
+ metadata.gz: 2922fbfa2a028f31e43251a7c9f3047ae58d5dfccdf22d9b5c086e0ebbb598e39affa0b7f7896b3eeb5a09580057680d84b5e83ccb86b525fb392688f61fd282
7
+ data.tar.gz: 4bbe06f67617c05ee6948922d5574d70460d90e047283aba8d41b47ced9b371c0a436e002597358e3f234e4defea1d3ba7e8eae9001134ff971c010ba209457c
data/lib/softcover/cli.rb CHANGED
@@ -100,9 +100,10 @@ module Softcover
100
100
 
101
101
  desc 'server', 'Run local server'
102
102
  method_option :port, type: :numeric, default: 4000, aliases: '-p'
103
+ method_option :bind, type: :string, default: '0.0.0.0', aliases: '-o'
103
104
  def server
104
105
  if Softcover::BookManifest::valid_directory?
105
- Softcover::Commands::Server.run options[:port]
106
+ Softcover::Commands::Server.run options[:port], options[:bind]
106
107
  else
107
108
  puts 'Not in a valid book directory.'
108
109
  exit 1
@@ -51,16 +51,17 @@ module Softcover::Commands::Server
51
51
  puts e.message
52
52
  end
53
53
 
54
- def start_server(port)
54
+ def start_server(port, bind)
55
55
  require 'softcover/server/app'
56
- puts "Running Softcover server on http://localhost:#{port}"
56
+ puts "Running Softcover server on http://#{bind}:#{port}"
57
57
  Softcover::App.set :port, port
58
+ Softcover::App.set :bind, bind
58
59
  Softcover::App.run!
59
60
  end
60
61
 
61
- def run(port)
62
+ def run(port, bind)
62
63
  rebuild
63
64
  listen_for_changes
64
- start_server port
65
+ start_server port, bind
65
66
  end
66
67
  end
@@ -6,7 +6,6 @@ class Softcover::App < Sinatra::Base
6
6
  register Sinatra::Async
7
7
 
8
8
  set :public_folder, 'html'
9
- set :bind, '0.0.0.0'
10
9
 
11
10
  configure do
12
11
  mime_type :map, 'application/javascript'
@@ -75,4 +74,4 @@ class Softcover::App < Sinatra::Base
75
74
  raise Sinatra::NotFound unless @chapter
76
75
  end
77
76
  end
78
- end
77
+ end
@@ -1,3 +1,3 @@
1
1
  module Softcover
2
- VERSION = "1.1.17"
2
+ VERSION = "1.1.18"
3
3
  end
data/softcover.gemspec CHANGED
@@ -8,9 +8,9 @@ Gem::Specification.new do |gem|
8
8
  gem.version = Softcover::VERSION
9
9
  gem.authors = ["Michael Hartl", "Nick Merwin"]
10
10
  gem.email = ["michael@softcover.io"]
11
- gem.description = %q{CLI interface for softcover.io}
12
- gem.summary = %q{A typesetting system for technical authors}
13
- gem.homepage = "http://manual.softcover.io/"
11
+ gem.description = %q{Command-line interface for softcover.io}
12
+ gem.summary = %q{An ebook production system & sales and marketing platform for technical authors}
13
+ gem.homepage = "http://manual.softcover.io/book"
14
14
  gem.license = "MIT"
15
15
 
16
16
  gem.files = `git ls-files`.split($/)
@@ -14,8 +14,11 @@ describe Softcover::Commands::Server do
14
14
  Softcover::App.should_receive :run!
15
15
 
16
16
  port = 5000
17
- subject.run port
17
+ bind = "localhost"
18
+
19
+ subject.run port, bind
18
20
 
19
21
  expect(Softcover::App.port).to eq port
22
+ expect(Softcover::App.bind).to eq bind
20
23
  end
21
24
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: softcover
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.17
4
+ version: 1.1.18
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Hartl
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-11-13 00:00:00.000000000 Z
12
+ date: 2015-11-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: polytexnic
@@ -291,7 +291,7 @@ dependencies:
291
291
  - - "~>"
292
292
  - !ruby/object:Gem::Version
293
293
  version: 3.0.3
294
- description: CLI interface for softcover.io
294
+ description: Command-line interface for softcover.io
295
295
  email:
296
296
  - michael@softcover.io
297
297
  executables:
@@ -1632,7 +1632,7 @@ files:
1632
1632
  - spec/utils_spec.rb
1633
1633
  - spec/webmock_helpers.rb
1634
1634
  - tasks/run_specs.rake
1635
- homepage: http://manual.softcover.io/
1635
+ homepage: http://manual.softcover.io/book
1636
1636
  licenses:
1637
1637
  - MIT
1638
1638
  metadata: {}
@@ -1652,10 +1652,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
1652
1652
  version: '0'
1653
1653
  requirements: []
1654
1654
  rubyforge_project:
1655
- rubygems_version: 2.4.5
1655
+ rubygems_version: 2.2.2
1656
1656
  signing_key:
1657
1657
  specification_version: 4
1658
- summary: A typesetting system for technical authors
1658
+ summary: An ebook production system & sales and marketing platform for technical authors
1659
1659
  test_files:
1660
1660
  - spec/app_spec.rb
1661
1661
  - spec/auth_spec.rb