Interview Prep/CI/CD/Jenkins Build and Agent Failures

`ERROR: Couldn't find any revision to build. Verify the repository and branch configuration for this job.`

BeginnerTroubleshootingJenkins Build and Agent Failures
Answer

Likely causes → Branch specifier wrong (*/master vs main); empty repo; wrong credentials; the branch was deleted.

Diagnose →

git ls-remote https://github.com/org/repo.git

Check the job's Branch Specifier.

Fix → Use */main (or refs/heads/main), and fix repository URL or credentials.

Prevent → Use multibranch jobs, which discover branches automatically.

All CI/CD questions Roadmap: CI/CD fundamentals

More on Jenkins Build and Agent Failures