File tree 2 files changed +5
-1
lines changed 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -39,6 +39,7 @@ if (argv.h || argv.help) {
39
39
' -K --key Path to ssl key file (default: key.pem).' ,
40
40
'' ,
41
41
' -r --robots Respond to /robots.txt [User-agent: *\\nDisallow: /]' ,
42
+ ' --no-dotfiles Do not show dotfiles' ,
42
43
' -h --help Print this list and exit.'
43
44
] . join ( '\n' ) ) ;
44
45
process . exit ( ) ;
@@ -101,7 +102,8 @@ function listen(port) {
101
102
robots : argv . r || argv . robots ,
102
103
ext : argv . e || argv . ext ,
103
104
logFn : logger . request ,
104
- proxy : proxy
105
+ proxy : proxy ,
106
+ showDotfiles : argv . dotfiles
105
107
} ;
106
108
107
109
if ( argv . cors ) {
Original file line number Diff line number Diff line change @@ -46,6 +46,7 @@ function HttpServer(options) {
46
46
this . cache = options . cache === undefined ? 3600 : options . cache ; // in seconds.
47
47
this . showDir = options . showDir !== 'false' ;
48
48
this . autoIndex = options . autoIndex !== 'false' ;
49
+ this . showDotfiles = options . showDotfiles ;
49
50
this . gzip = options . gzip === true ;
50
51
this . contentType = options . contentType || 'application/octet-stream' ;
51
52
@@ -96,6 +97,7 @@ function HttpServer(options) {
96
97
root : this . root ,
97
98
cache : this . cache ,
98
99
showDir : this . showDir ,
100
+ showDotfiles : this . showDotfiles ,
99
101
autoIndex : this . autoIndex ,
100
102
defaultExt : this . ext ,
101
103
gzip : this . gzip ,
You can’t perform that action at this time.
0 commit comments