Deploy your projects to GitHub with a simple drag-and-drop! No CLI, no git commands, just drag, drop, and deploy.
Drag & Deploy is a beautiful web application that automates the entire deployment workflow. Simply upload a ZIP or TAR file, and watch as your code gets automatically extracted, committed, and pushed to your GitHub repository.
- 🖱️ Intuitive Drag & Drop Interface - Upload files with a simple drag-and-drop
- 📦 Automatic File Extraction - Supports ZIP and TAR archives
- 🔄 Automated Git Workflow - Handles init, add, commit, and push automatically
- 🐳 Docker Ready - Run anywhere with Docker
- 🔐 Secure Authentication - Uses GitHub Personal Access Tokens
- ⚡ Fast & Reliable - Built with Next.js 16 and TypeScript
- 🎨 Beautiful UI - Modern, responsive design with Tailwind CSS
- Drag & Drop your project ZIP file onto the upload area
- The app extracts your files automatically
- Files are copied to your configured repository
- Git operations are automated (add, commit, push)
- Your code is deployed to GitHub! 🎉
- Node.js 20+ (or Docker)
- GitHub Personal Access Token with
reposcope - A GitHub repository to deploy to
-
Clone the repository
git clone <your-repo-url> cd drag-and-deploy
-
Install dependencies
npm install
-
Set up environment variables
Create a
.envfile in the root directory:GITHUB_TOKEN=your_github_personal_access_token GIT_USER=your_github_username GIT_EMAIL=your_email@example.com REPO_URL=github.com/username/repository-name
-
Run the development server
npm run dev
-
Open your browser
Navigate to
http://localhost:3000
docker build -t drag-and-deploy .docker run -d -p 3000:3000 \
-e GITHUB_TOKEN=your_token \
-e GIT_USER=your_username \
-e GIT_EMAIL=your_email@example.com \
-e REPO_URL=github.com/username/repo.git \
-v /path/to/repo:/app/repo \
--name drag-and-deploy \
drag-and-deployOr using a .env file:
docker run -d -p 3000:3000 \
--env-file .env \
-v /path/to/repo:/app/repo \
--name drag-and-deploy \
drag-and-deployMake sure to mount your repository directory to /app/repo in the container:
-v /path/to/your/repo:/app/repo-
Go to GitHub Settings → Developer settings → Personal access tokens → Tokens (classic)
-
Click Generate new token (classic)
-
Select the following scopes:
- ✅
repo- Full control of private repositories (includes public repos too)
- ✅
-
Copy the token and use it as your
GITHUB_TOKEN
| Variable | Description | Required |
|---|---|---|
GITHUB_TOKEN |
GitHub Personal Access Token | ✅ Yes |
GIT_USER |
Your GitHub username | ✅ Yes |
GIT_EMAIL |
Your email address | ✅ Yes |
REPO_URL |
Repository URL (format: github.com/username/repo) |
✅ Yes |
- Framework: Next.js 16
- Language: TypeScript
- Styling: Tailwind CSS
- File Upload: react-dropzone
- Archive Extraction: extract-zip
- Runtime: Node.js
# Development server
npm run dev
# Production build
npm run build
# Start production server
npm start
# Lint code
npm run lintdrag-and-deploy/
├── app/
│ ├── api/
│ │ └── deploy/
│ │ └── route.ts # Deployment API endpoint
│ ├── page.tsx # Main upload page
│ ├── layout.tsx # App layout
│ └── globals.css # Global styles
├── Dockerfile # Docker configuration
├── package.json # Dependencies
└── README.md # This file
- File Upload: Client uploads ZIP/TAR file via drag-and-drop
- Server Processing:
- Saves file to
/tmp - Extracts archive to temporary directory
- Copies files to repository path (
/app/repo)
- Saves file to
- Git Operations:
- Initializes git repository (if needed)
- Configures user identity
- Sets up remote origin
- Stages all changes (
git add .) - Commits with message "Automated deploy"
- Pushes to GitHub
- Cleanup: Removes temporary files
- ✅ Check that your GitHub token has
reposcope - ✅ Verify the token hasn't expired
- ✅ Ensure the token's owner has write access to the repository
- ✅ Make sure
GIT_USERandGIT_EMAILare set correctly - ✅ The app automatically sets these, but verify your environment variables
- ✅ Ensure your ZIP file contains actual files (not empty)
- ✅ Check that files were extracted correctly
- ✅ The Dockerfile includes git installation - rebuild the image if needed
Contributions are welcome! Feel free to open issues or submit pull requests.
This project is open source and available under the MIT License.
If you find this project helpful, please give it a star!
Made with ❤️ using Next.js and TypeScript