It's not difficult. The "-Mxxx" option to perl loads module "xxx" and "-e" lets you supply an expression to evaluate (a command)
perl -MHTTP::Server::Brick -e '$s=HTTP::Server::Brick->new(port=>8080); $s->mount("/"=>{path=>"/tmp"}); $s->start'This serves /tmp and its sub-directories, if you don't want that you'll want wildcard=>0 as well as the path.
In reply to Re^3: Simple http server one-liner for some static files?
by Anonymous Monk
in thread Simple http server one-liner for some static files?
by Anonymous Monk
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |