Run rubocop
This commit is contained in:
parent
3d56ecb00e
commit
31741a1bbd
2 changed files with 8 additions and 4 deletions
|
@ -1,3 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
require "bundler/setup"
|
||||
require "nanoc"
|
||||
cwd = File.realpath File.join(__dir__, "..", "..")
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
# frozen_string_literal: true
|
||||
|
||||
desc "Start web server"
|
||||
task :server, [:protocol] do |_t, args|
|
||||
require "yaml"
|
||||
|
@ -8,10 +10,10 @@ task :server, [:protocol] do |_t, args|
|
|||
p = h[:protocol] || "tcp"
|
||||
n = File.basename File.realpath(File.join(__dir__, "..", "..", "."))
|
||||
o = if p == "unix"
|
||||
{unix: nanoc.server.unix.path}
|
||||
else
|
||||
{host: nanoc.server.tcp.host, port: nanoc.server.tcp.port}
|
||||
end
|
||||
{unix: nanoc.server.unix.path}
|
||||
else
|
||||
{host: nanoc.server.tcp.host, port: nanoc.server.tcp.port}
|
||||
end
|
||||
Process.setproctitle "rake server[#{p}] [#{n}]"
|
||||
s = Server.dir(nanoc.output_dir, o)
|
||||
s.start(block: true)
|
||||
|
|
Loading…
Reference in a new issue