diff options
Diffstat (limited to 'examples')
-rwxr-xr-x | examples/linux-listener-stats.rb | 4 | ||||
-rw-r--r-- | examples/middleware.ru | 1 | ||||
-rw-r--r-- | examples/watcher.ru | 1 | ||||
-rw-r--r-- | examples/watcher_demo.ru | 3 | ||||
-rw-r--r-- | examples/yahns.conf.rb | 1 | ||||
-rw-r--r-- | examples/zbatery.conf.rb | 1 |
6 files changed, 8 insertions, 3 deletions
diff --git a/examples/linux-listener-stats.rb b/examples/linux-listener-stats.rb index 1008995..5f67633 100755 --- a/examples/linux-listener-stats.rb +++ b/examples/linux-listener-stats.rb @@ -1,5 +1,6 @@ #!/usr/bin/ruby # -*- encoding: binary -*- +# frozen_string_literal: false $stdout.sync = $stderr.sync = true # this is used to show or watch the number of active and queued # connections on any listener socket from the command line @@ -15,7 +16,6 @@ end usage = "Usage: #$0 [-d DELAY] [-t QUEUED_THRESHOLD] ADDR..." ARGV.size > 0 or abort usage delay = false -all = false queued_thresh = -1 # "normal" exits when driven on the command-line trap(:INT) { exit 130 } @@ -25,7 +25,7 @@ OptionParser.new('', 24, ' ') do |opts| opts.banner = usage opts.on('-d', '--delay=DELAY', Float) { |n| delay = n } opts.on('-t', '--queued-threshold=INT', Integer) { |n| queued_thresh = n } - opts.on('-a', '--all') { all = true } + opts.on('-a', '--all') { } # noop opts.parse! ARGV end diff --git a/examples/middleware.ru b/examples/middleware.ru index 642016b..a485592 100644 --- a/examples/middleware.ru +++ b/examples/middleware.ru @@ -1,3 +1,4 @@ +# frozen_string_literal: false # sample stand-alone rackup application for Raindrops::Middleware require 'rack/lobster' require 'raindrops' diff --git a/examples/watcher.ru b/examples/watcher.ru index a3e7fdb..e2aa97c 100644 --- a/examples/watcher.ru +++ b/examples/watcher.ru @@ -1,3 +1,4 @@ +# frozen_string_literal: false # Sample standalone Rack application, recommended use is with Zbatery # See zbatery.conf.rb require "raindrops" diff --git a/examples/watcher_demo.ru b/examples/watcher_demo.ru index 7adba8e..7a6e675 100644 --- a/examples/watcher_demo.ru +++ b/examples/watcher_demo.ru @@ -1,5 +1,6 @@ +# frozen_string_literal: false # This is a snippet of the config that powers -# https://raindrops-demo.bogomips.org/ +# https://yhbt.net/raindrops-demo/ # This may be used with the packaged zbatery.conf.rb # # zbatery -c zbatery.conf.ru watcher_demo.ru -E none diff --git a/examples/yahns.conf.rb b/examples/yahns.conf.rb index f5b4f10..75f0bd1 100644 --- a/examples/yahns.conf.rb +++ b/examples/yahns.conf.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: false # Inlined rack app using yahns server (git clone git://yhbt.net/yahns.git) # Usage: yahns -c /path/to/this/file.conf.rb # There is no separate config.ru file for this example, diff --git a/examples/zbatery.conf.rb b/examples/zbatery.conf.rb index 5f94c0e..0537466 100644 --- a/examples/zbatery.conf.rb +++ b/examples/zbatery.conf.rb @@ -1,3 +1,4 @@ +# frozen_string_literal: false # Used for running Raindrops::Watcher, which requires a multi-threaded # Rack server capable of streaming a response. Threads must be used, # so any multi-threaded Rack server may be used. |