0.4.2 • Published 8 years ago

yel v0.4.2

Weekly downloads
6
License
MIT
Repository
github
Last release
8 years ago

yel

从当前路径启动一个 WEB 服务器。

安装

$ npm install -g yel

快速启动

$ cd my-project-path
$ yel start

命令

start [port]

从当前路径启动 WEB 服务器并监听 port 端口。默认监听端口 80

例如, 启动 WEB 服务器并监听 8080 端口:

$ yel start 8080

restart

重启当前路径下的 WEB 服务器。

stop

停止当前路径下的 WEB 服务器。

config 配置文件

使用 config 配置文件启动 WEB 服务器,config 配置文件必须在 WEB 服务器的根路径下。

  • workers 服务器进程数,默认 2

  • log 日志记录文件的路径,默认 '#<date>.log'

  • host 服务器主机地址,默认 '0.0.0.0'

  • port 服务器端口,默认 80

  • cache 静态文件缓存选项:

    • maxAge 缓存最大时间期限,单位 ms,默认 0(无限期)

    • cacheControl 缓存控制字符串,默认 'public,max-age=#<maxAge>'

    • md5Encoding 文件 MD5 编码:'hex''base64',默认 'hex'

    • ignores 忽略文件列表,默认 ['node_modules', 'plugins', 'tmp', '*.log', 'config']

  • alias 路径别名表

  • plugins 使用插件列表

关于插件

详细查看“关于插件”。


(The MIT License)

Copyright (c) 2015-2015 Kan Kung-Yip <gon@gyeq.in>

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

0.4.3

8 years ago

0.4.2

8 years ago

0.4.1

8 years ago

0.4.0

8 years ago

0.3.2

8 years ago

0.3.1

8 years ago

0.3.0

8 years ago

0.2.9

8 years ago

0.2.8

8 years ago

0.2.7

8 years ago

0.2.6

8 years ago

0.2.5

8 years ago

0.2.4

8 years ago

0.2.3

8 years ago

0.2.2

8 years ago

0.2.1

8 years ago

0.2.0

8 years ago

0.1.10

8 years ago

0.1.9

8 years ago

0.1.8

8 years ago

0.1.7

8 years ago

0.1.6

8 years ago

0.1.5

8 years ago

0.1.4

8 years ago

0.1.3

8 years ago

0.1.2

8 years ago

0.1.1

8 years ago

0.1.0

8 years ago