add javascript mime type for webrick. fixes #98
This commit is contained in:
		
							parent
							
								
									add546f61e
								
							
						
					
					
						commit
						602a252364
					
				|  | @ -6,6 +6,7 @@ | |||
|     * Allow .mkd as markdown extension | ||||
|     * Use $stdout/err instead of constants (#99) | ||||
|     * Properly wrap code blocks (#91) | ||||
|     * Add javascript mime type for webrick (#98) | ||||
| 
 | ||||
| == 0.5.5 | ||||
|   * Bug Fixes | ||||
|  |  | |||
|  | @ -137,9 +137,13 @@ if options['server'] | |||
| 
 | ||||
|   FileUtils.mkdir_p(destination) | ||||
| 
 | ||||
|   mime_types = WEBrick::HTTPUtils::DefaultMimeTypes | ||||
|   mime_types.store 'js', 'application/javascript' | ||||
| 
 | ||||
|   s = HTTPServer.new( | ||||
|     :Port            => options['server_port'], | ||||
|     :DocumentRoot    => destination | ||||
|     :DocumentRoot    => destination, | ||||
|     :MimeTypes       => mime_types | ||||
|   ) | ||||
|   t = Thread.new { | ||||
|     s.start | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue