48/56
Sign inSign up free

786. A Shallow Clone That Needs Its History

medium 20 XP ~8 minHands-on lab

The CI job clones webapp with git clone --depth 1 to save time. The release step runs git describe --tags to compute the version, and it fails: "No names found, cannot describe anything". The job's clone is /home/student/ci/webapp (its origin is /srv/git/webapp.git).

Task

Fix this clone (don't re-clone it) so that:

  • git describe --tags on main works and names the latest release tag reachable from main,
  • all commits since that tag are present,
  • the clone has all the release tags of origin.

It doesn't need to become a full clone.

About this machine

Ubuntu 24.04 with no internet access. You are student with passwordless sudo. The grader checks the final state of the machine, not the commands you typed. Values like names and ports are generated for you.

Teaching or writing about this? Embed this lab on your page

TerminalNot started

Your machine is ready to start

A fresh, isolated Ubuntu machine boots in a few seconds with the task already set up.

No account needed: 3 of 3 free tries left. Guest machines last 30 minutes.