Skip to content

Latest commit

 

History

History
90 lines (48 loc) · 1.81 KB

File metadata and controls

90 lines (48 loc) · 1.81 KB

Local File Server (One-Command Share)

Run a file server in any directory on Windows or macOS by executing a single command. Once started, files can be accessed from other devices on the same local network.

💻 macOS Setup

Prerequisites

  • Install Python

Install QR generator:

  • brew install qrencode

Create Global Command in Mac OS

Step 1.

Copy serve.sh from the Mac folder and paste it into any temporary folder. Open Terminal in that folder.

Step 2.

sudo mv serve.sh /usr/local/bin/serve

Step 3.

sudo chmod +x /usr/local/bin/serve

Now you can run:

serve

in any directory to make that folder shareable on the local network.

Note:

After installation, delete the original serve.sh file from the temporary folder to avoid command conflicts.

💻 Windows Setup

Prerequisites

  • Install Python

Install QR generator:

  • py -m pip install qrcode[pil]

Create Global Command in windows

Step 1.

Copy serve.bat and server.py from the Windows folder and paste them into a permanent folder (one that you will not delete).

Step 2.

Search “Environment Variables” → open Edit the system environment variables.

Step 3.

Click Environment Variables → under System variables, find Path → click Edit.

Step 4.

Click New and paste the folder path from Step 1 (where serve.bat and server.py are stored). Click OK.

Now you can run:

serve

from any directory in Command Prompt or PowerShell to make that folder shareable on the local network.

Usage

Navigate to any folder in CMD:

cd "your-folder"

serve

image

A local server will start, and the folder will be accessible to other devices connected to the same Wi-Fi/network.