Welcome to TerminalTalk, your go-to solution for easy and seamless texting over a WAN (Wide Area Network) and LAN (Local Area Network)! Whether you're chatting with friends across the room or across the globe, TerminalTalk makes it simple and enjoyable.
TerminalTalk is a lightweight chat application that allows users to communicate in real-time using a simple terminal interface. Built using Python's socket programming, it leverages TCP connections for reliable messaging. This project is perfect for learning about networking concepts and building your own messaging system.
- 💬 Real-time messaging between users
- 🖥️ Connect over LAN or WAN
- 🛠️ Simple terminal-based user interface
- 🔒 Basic nickname handling for personalization
- Python 3.x installed on your machine
- Basic knowledge of using the terminal/command prompt
- Clone the repository:
git clone https://github.com/saicharan1901/TerminalTalk.git cd TerminalTalk
To run TerminalTalk on a Local Area Network (LAN), follow these steps:
-
Open your terminal and navigate to the project directory:
cd TerminalTalk
-
Run the server:
python server.py
- The server will start listening for connections on your local IP address and the specified port (default: 7976).
-
On another device connected to the same network, open the terminal.
-
Connect to the server using the server's local IP address:
client = socket.socket(socket.AF_INET, socket.SOCK_STREAM) client.connect(('192.168.x.x', 7976)) # Replace with the server's local IP
-
Run the client:
python client.py
You can now chat with users on the same network! 🎉
To run TerminalTalk over a Wide Area Network (WAN), follow these steps:
-
If you haven't already, install
ngrok
using Homebrew:brew install ngrok/ngrok/ngrok
-
Authenticate ngrok with your account:
ngrok authtoken YOUR_AUTHTOKEN
-
In your terminal, navigate to the project directory:
cd TerminalTalk
-
Run the server:
python server.py
- Run ngrok to expose your server:
ngrok tcp 7976
- Note the forwarding address given by ngrok (e.g.,
tcp://0.tcp.in.ngrok.io:19049
).
- Note the forwarding address given by ngrok (e.g.,
-
On any device, open the terminal and connect to ngrok's forwarding address:
client.connect(('0.tcp.in.ngrok.io', 19049)) # Use the address from ngrok
-
Run the client:
python client.py
You can now chat with friends no matter where they are! 🌍💬
Feel free to fork the repository and submit pull requests! We welcome contributions to enhance TerminalTalk.
This project is licensed under the MIT License - see the LICENSE file for details.
For any questions or suggestions, please reach out at [email protected].