Python2 SimpleHTTPServerでファイルを素早く共有する

Python2 組み込みの SimpleHTTPServer (または Python3 では http.server) を使用すると、http サービスを開始して、ディレクトリとファイルを簡単かつ迅速に共有できます。これは、LAN 環境で特に便利です。

With default port 8000

$ cd $directory
$ python -m SimpleHTTPServer # python2
$ python -m http.server # python3
Serving HTTP on 0.0.0.0 port 8000 ...

With custom port xxxx

$ cd $directory
$ python -m SimpleHTTPServer xxxx # python2
$ python -m http.server xxxx # python3
Serving HTTP on 0.0.0.0 port xxxx ...

See python doc for reference

python