Skip to content

Instantly share code, notes, and snippets.

@sathishjayapal
Created September 14, 2026 05:02
Show Gist options
  • Select an option

  • Save sathishjayapal/eba57a1df10acfb87a47b89563548fd1 to your computer and use it in GitHub Desktop.

Select an option

Save sathishjayapal/eba57a1df10acfb87a47b89563548fd1 to your computer and use it in GitHub Desktop.
IdeaProjects Workspace: Essential Git & Shell Commands - Running reference guide

πŸ› οΈ IdeaProjects Workspace Commands

Essential Git, Maven, and Shell commands. Last updated: 2026-09-14.


πŸ“¦ Maven Build

πŸ”¨ Command πŸ“ Description
./mvnw clean package -DskipTests Quick build (no tests)
./mvnw verify -B Full build with tests
./mvnw test -Dtest=MyClass#method Run single test
./mvnw spring-boot:run Start application
./mvnw spring-boot:run -Dspring-boot.run.profiles=dev Start with dev profile
./mvnw spotless:apply Format code

πŸš€ Project Setup

🎯 Command πŸ“ Description
./dev-up.sh Start PostgreSQL + create .env
./dev-up.sh --reset Complete database reset
npm run devserver Start React frontend (port 3000)
java -jar target/*.jar Run JAR file

🐳 Docker & Compose

πŸ‹ Command πŸ“ Description
docker compose up -d Start all services
docker compose down Stop containers
docker compose down -v Stop + delete volumes
docker compose ps List running containers
docker compose logs -f postgres View PostgreSQL logs
docker exec -it postgres psql -U postgres Connect to PostgreSQL

🌳 Git Basics

πŸ“š Command πŸ“ Description
git status Check branch and changes
git log --oneline -10 View last 10 commits
git checkout -b feature/name Create new branch
git diff main..feature/name Compare to main
git add . Stage all changes
git commit -m "message" Commit changes
git push origin branch-name Push to remote
git stash Save work temporarily

πŸ’Ύ Database

πŸ—„οΈ Command πŸ“ Description
psql -h localhost -p 5443 -U postgres -d runs_app_local Connect to database
\dt List tables (in psql)
\d+ table_name View table structure (in psql)
SELECT * FROM table_name LIMIT 10; View rows (in psql)
\q Exit psql

πŸ”„ CI/CD & Container

🚦 Command πŸ“ Description
gh run list --limit 10 List GitHub Actions runs
gh run view <run_id> View specific workflow run
gh run view <run_id> --job=<job_id> --log View job logs
gh workflow list List all workflows
gh workflow view <workflow_name> View workflow details
docker pull ghcr.io/sathishjayapal/runs-app:latest Pull latest image from GHCR
docker inspect image_name:latest | grep -i "created" Check image metadata
docker logs sathish-stack-watchtower-1 --tail 50 View Watchtower logs
docker kill -s HUP sathish-stack-watchtower-1 Force Watchtower update check
curl -s http://localhost:8080/actuator/health Check application health

πŸ”§ Troubleshooting

⚠️ Command πŸ“ Description
lsof -i :8080 Find process on port
kill -9 <PID> Force kill process
java -version Check Java version
./mvnw -v Check Maven version
docker compose config Validate docker-compose.yml

πŸ“ Port Reference

🌐 Service πŸ”Œ Port
runs-app 8080
runs-ai-analyzer 8081
eventstracker 9081
Config Server 8888
RabbitMQ 5672
Portainer 9000

⚑ Project Quick Start

πŸƒ EventTracker

cd eventstracker && ./start-local-with-config.sh
./mvnw spring-boot:run  # port 9081

πŸ“± Runs App

cd runs-app && ./dev-up.sh
./mvnw spring-boot:run  # port 8080
npm run devserver       # port 3000

πŸ€– Runs AI Analyzer

cd runs-ai-analyzer && ./dev-up.sh
./mvnw spring-boot:run  # port 8081

πŸ“Š MyTracker

cd mytracker
./mvnw clean package -DskipTests
./mvnw package -pl :trackgarmin -am -DskipTests  # Single module

🎨 Useful Aliases

# Maven
alias mvn-build='./mvnw clean package -DskipTests'
alias mvn-run='./mvnw spring-boot:run'
alias mvn-test='./mvnw test'

# Docker
alias dc='docker compose'
alias dc-up='docker compose up -d'
alias dc-down='docker compose down'

# Git
alias gs='git status'
alias gp='git push'
alias gl='git log --oneline -10'
alias gb='git branch -a'

# Projects
alias runs='cd ~/IdeaProjects/runs-app'
alias events='cd ~/IdeaProjects/eventstracker'
alias mytrack='cd ~/IdeaProjects/mytracker'

🌐 Public GIST | πŸ”’ No Secrets | πŸ“– Living Reference

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment