hackmate-cli
v1.3.0
Published
HackMate CLI - Terminal-based social network for developers and hackers
Downloads
4,387
Maintainers
Readme
🚀 HackMate CLI
Terminal-based social network & dating platform for developers and hackers
Build connections, find collaborators, and discover talent—all from your terminal.
✨ Features
| Feature | Description | |---------|-------------| | 🎨 Beautiful TUI | Built with React + Ink for a modern terminal experience | | 🔐 Complete Auth | Signup → Email verification → Profile setup | | 💕 Smart Matching | Discover developers based on compatibility score & interests | | 💬 Real-time Chat | DMs and group messaging powered by Socket.IO | | 🤝 Networking | Connect with developers, send/accept friend requests | | 🛠️ Projects | Browse open projects, apply to collaborations | | 👥 Communities | Join groups based on tech stacks and interests | | 🔔 Notifications | Get alerts for messages, requests, and matches | | 📊 User Stats | View profile views, reputation, and engagement | | ⚡ Admin Tools | Manage users and content (admin-only) |
🚀 Quick Start
1. Install
npm install -g hackmate-cli2. Configure Server (auto)
The CLI now defaults to the hosted server:
https://hackmateserver-huhcaec4g7eua0hf.centralindia-01.azurewebsites.net
If you need a different backend, override anytime:
hackmate config set https://your-server.example.com
# or per-shell
export API_URL=https://your-server.example.com3. Sign Up
hackmate auth signupFollow the prompts to:
- Create your account
- Verify your email (OTP sent to console if SMTP not configured)
- Build your profile (bio, tech stack, interests, etc.)
4. Start Exploring
# Discover potential matches/collaborators
hackmate discover
# View your profile
hackmate profile view
# Find projects
hackmate project list📖 Command Reference
🔐 Authentication
hackmate auth signup # Create new account
hackmate auth login # Login to existing account
hackmate auth logout # Logout
hackmate auth whoami # Check current user
hackmate auth verify # Verify email with OTP👤 Profile
hackmate profile view [username] # View profile (yours or another user)
hackmate profile edit # Edit your profile💕 Matching & Discovery
hackmate discover # Find compatible developers
hackmate match list # View your matches🤝 Social Network
hackmate social list # List friends
hackmate social requests # View pending friend requests
hackmate social follow <username> # Send friend request
hackmate social unfollow <username> # Unfollow user
hackmate social block <username> # Block user💬 Chat & Messaging
hackmate chat list # List conversations
hackmate chat dm <username> # Direct message a user
hackmate chat group <groupname> # Open group chat🛠️ Projects
hackmate project list # Browse open projects
hackmate project create # Post a new project
hackmate project view <id> # View project details
hackmate project apply <id> # Apply to join project
hackmate project accept <id> <userId> # Accept applicant (owner only)👥 Groups & Communities
hackmate group list # List available groups
hackmate group create # Create new community
hackmate group view <id> # View group details
hackmate group join <id> # Join a group
hackmate group accept <id> <userId> # Accept join request (admin only)🔔 Notifications
hackmate notification list # View all notifications📊 User Stats
hackmate stats # View your stats (messages, matches, views, etc.)⚙️ Configuration
hackmate config get # Show current config
hackmate config set <url> # Set server URL
hackmate settings # Manage app settings
hackmate privacy # View privacy information⚡ Admin (requires admin role)
hackmate admin users list # List all users
hackmate admin users view <id> # View user details
hackmate admin users delete <id> # Delete user🔧 Installation Options
Option 1: Global Install (Recommended)
npm install -g hackmate-cli
# Use anywhere
hackmate --helpOption 2: Local Development
git clone https://github.com/Sameer-Bagul/hackmate.git
cd hackmate/cli
npm install
npm run dev # Watch mode
npm run build # Build for production
npm start # Run built version
npm link # Link locally for testing⚙️ Configuration
Environment Variables
Create .env in the CLI directory (or set globally):
# HackMate Server URL (required after first use)
API_URL=https://your-server.azurewebsites.net
# Optional: Socket.IO server (defaults to API_URL)
SOCKET_URL=https://your-server.azurewebsites.netLocal Config Storage
The CLI stores credentials and settings locally:
| OS | Location |
|----|----------|
| Linux | ~/.config/hackmate-cli/config.json |
| macOS | ~/Library/Preferences/hackmate-cli/config.json |
| Windows | %APPDATA%\hackmate-cli\Config\config.json |
To reset configuration:
# Linux/macOS
rm -rf ~/.config/hackmate-cli/
# Windows PowerShell
Remove-Item -Recurse $env:APPDATA\hackmate-cli🎮 Usage Tips
| Tip | Shortcut | |-----|----------| | Navigate menus | ↑ ↓ arrows | | Select option | Enter | | Exit screen | Esc | | Enter text | Type and Enter | | Exit CLI | Ctrl+C |
Interactive Menus
Most screens feature interactive menus:
- Use arrow keys to highlight options
- Press Enter to select
- Press Esc to go back
Real-time Features
The CLI auto-refreshes:
- ✅ New messages appear instantly
- ✅ Notifications pop up in real-time
- ✅ Friend requests are live-updated
🏗️ Architecture
cli/
├── src/
│ ├── features/ # Feature modules
│ │ ├── auth/ # Authentication (forms, logic)
│ │ ├── profile/ # Profile viewing & editing
│ │ ├── match/ # Matching & discovery
│ │ ├── chat/ # Messaging (DM & groups)
│ │ ├── network/ # Friend requests & connections
│ │ ├── project/ # Project browsing & applications
│ │ ├── group/ # Community management
│ │ ├── notification/ # Notifications
│ │ └── admin/ # Admin panel
│ ├── shared/ # Shared utilities
│ │ ├── components/ # Reusable UI components
│ │ ├── hooks/ # Custom React hooks
│ │ ├── utils/ # Helper functions
│ │ └── types/ # TypeScript types
│ ├── context/ # Global state
│ │ ├── AuthContext.tsx # Authentication state
│ │ └── SocketContext.tsx # Real-time Socket.IO
│ ├── api.ts # Axios HTTP client
│ ├── config.ts # Configuration management
│ └── cli.tsx # CLI entry point
├── scripts/
│ └── add-shebang.cjs # Build helper
├── dist/ # Compiled JavaScript
├── package.json
└── README.md🚨 Troubleshooting
"Cannot connect to server"
# 1. Check if server is running
curl https://your-server.azurewebsites.net/health
# 2. Verify config is correct
hackmate config get
# 3. Reset config and try again
rm -rf ~/.config/hackmate-cli/
hackmate config set https://your-server.azurewebsites.net"Login fails / Token expired"
# Clear session and login again
hackmate auth logout
hackmate auth login"Socket.IO not working (real-time features slow)"
- Check server logs for Socket.IO errors
- Ensure WebSocket connections aren't blocked by firewall
- Try restarting the CLI
"OTP not received"
If SMTP is not configured on the server:
- The OTP will be printed in the server console
- Copy the code and enter it in the CLI prompt
For production servers with SMTP:
- Check spam/junk folder
- Verify email address during signup
🤝 Contributing
We welcome contributions! Here's how to get started:
# 1. Clone and install
git clone https://github.com/Sameer-Bagul/hackmate.git
cd hackmate/cli
npm install
# 2. Create a feature branch
git checkout -b feature/amazing-feature
# 3. Make changes and test
npm run dev
npm run lint
# 4. Build and verify
npm run build
# 5. Push and create PR
git push origin feature/amazing-featureCode Standards
- Language: TypeScript (strict mode)
- UI Framework: React + Ink
- Linting: ESLint
- Format: Prettier (optional, but recommended)
📚 Resources
- Server Repository: hackmate-server
- API Documentation: API_ROUTES.md
- Issue Tracker: GitHub Issues
📦 Deployment
Publish to npm
Via CI (Recommended):
# Create a git tag
git tag cli-v1.0.1
git push origin cli-v1.0.1This triggers automated publishing via GitHub Actions.
Manual:
cd cli
npm run build
npm publish --access publicRequires:
- npm account and
npm login - Package available on npm registry
📄 License
MIT © 2024 HackMate Contributors
🙌 Support
- 🐛 Report Bugs: GitHub Issues
- 💡 Feature Requests: Discussions
Made with ❤️ for developers, by developers.
