-
Notifications
You must be signed in to change notification settings - Fork 50
feat: add tmux-based development setup script #161
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: add tmux-based development setup script #161
Conversation
- Add setup.sh script to start all services in tmux session - Add stop.sh script for graceful shutdown - Add comprehensive development/README.md with setup instructions - Include prerequisite checks for Go, Node.js, npm, Docker, and tmux - Validate environment files before starting services - Auto-install dependencies if missing - Update main README.md with development setup section Fixes CCExtractor#155
|
hey @its-me-abhishek ,this is my first contribution to CCExtractor/ccsync. the workflows are currently waiting for approval could you please approve it ? |
thanks @ShivaGupta-14 ,I'm just waiting for a review !! |
its-me-abhishek
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please fix these, will merge later
|
|
||
| - **Backend**: See [backend/README.md](backend/README.md) | ||
| - **Frontend**: See [frontend/README.md](frontend/README.md) | ||
| - **Full Stack**: Use `docker-compose up` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should have been Syncserver instead, docker-compose up syncserver
development/README.md
Outdated
|
|
||
| ### Backend Environment (`backend/.env`) | ||
|
|
||
| Create a file at `backend/.env` with the following content: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should be ./backend/.env. it is easy to get confused and may end up creating a backend directory here itself
| @@ -0,0 +1,200 @@ | |||
| # CCSync Development Setup | |||
|
|
|||
| This directory contains scripts to automate local development setup for CCSync. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also maybe Add a note that the backend shall be run in a separate user only (preferably root user)
development/setup.sh
Outdated
| if [ ! -f "$ROOT_DIR/backend/.env" ]; then | ||
| echo "Error: backend/.env file not found." | ||
| echo "Please create it with required environment variables." | ||
| echo "See development/README.md for details." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please also add a reference to the website
- Change backend/.env to ./backend/.env to avoid confusion - Add note about running backend in separate user environment - Clarify sync server startup command in service URLs - Add CCSync documentation website references in setup.sh error messages - Add documentation link for OAuth credential setup
|
hey @its-me-abhishek Ready for review. Thank you! |
|
Tested this and works great! Thanks a lot! |
Description
This PR adds an automated development setup script that simplifies local development by running all three services (backend, frontend, and sync server) in a single tmux session.
Key Features:
./development/setup.sh./development/stop.shThis significantly reduces setup friction for new contributors and makes local development faster and more convenient.
Checklist
npx prettier --write .(for formatting)gofmt -w .(for Go backend)npm test(for JS/TS testing)Additional Notes
What's included:
development/setup.sh- Main setup script with:development/stop.sh- Clean shutdown script that:development/README.md- Comprehensive guide with:Updated main
README.md- Added Development Setup section linking to the new scriptsImprovements over existing approach:
Testing:
Tested on Linux with all prerequisites installed. Script successfully: