aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJinweiClarkChao <[email protected]>2014-09-23 22:34:14 +0800
committerJinwei Zhao <[email protected]>2017-01-13 15:07:44 +0800
commitb214f38d2c24a890ce36512a0c8bab965e27a508 (patch)
tree1522b651444407cbf120798e79be4657f1b472ab /Code/Blocks/syntax/tests/webrick.rb
parente13882d1656b143533cec307a19425e0a56ec999 (diff)
downloadjinwei.me-b214f38d2c24a890ce36512a0c8bab965e27a508.tar.gz
README
Diffstat (limited to 'Code/Blocks/syntax/tests/webrick.rb')
-rw-r--r--Code/Blocks/syntax/tests/webrick.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/Code/Blocks/syntax/tests/webrick.rb b/Code/Blocks/syntax/tests/webrick.rb
new file mode 100644
index 0000000..0b3c93c
--- /dev/null
+++ b/Code/Blocks/syntax/tests/webrick.rb
@@ -0,0 +1,11 @@
1require 'webrick'
2include WEBrick
3
4s = HTTPServer.new(
5 :Port => 2010,
6 :DocumentRoot => Dir::pwd
7)
8s.mount('/sh/scripts', WEBrick::HTTPServlet::FileHandler, '../scripts')
9s.mount('/sh/styles', WEBrick::HTTPServlet::FileHandler, '../styles')
10trap('INT') { s.stop }
11s.start
Powered by cgit v1.2.3 (git 2.41.0)