Tagging Your Project's History

GitGitBeginner
Practice Now

Introduction

Welcome, time traveler! You've been tasked with organizing the historical records of the "Chrono Codex" project - a revolutionary time machine software. Your mission is to use Git tags to mark significant milestones in the project's development. As the lead chrono-engineer, you need to ensure that future developers can easily navigate through the project's timeline and access critical points in its history.


Skills Graph

%%%%{init: {'theme':'neutral'}}%%%% flowchart RL git(("Git")) -.-> git/BranchManagementGroup(["Branch Management"]) git/BranchManagementGroup -.-> git/log("Show Commits") git/BranchManagementGroup -.-> git/tag("Git Tags") subgraph Lab Skills git/log -.-> lab-387763{{"Tagging Your Project's History"}} git/tag -.-> lab-387763{{"Tagging Your Project's History"}} end

Marking the Milestones

Before you begin, you'll find a Git repository named "chrono-codex" in your ~/project directory. This repository contains the development history of the Chrono Codex project, with several commits representing different stages of development. Your task is to properly tag these milestones to create a clear historical record.

Initial Repository State

Before you start the challenge, here's what you need to know about the current state of the "chrono-codex" repository:

  1. The repository is located in ~/project/chrono-codex.
  2. It contains a README.md file and a time_machine.js file.
  3. The repository has the following commit history (from oldest to newest):
    • Initial commit (adds README.md)
    • Add initial time machine structure
    • Add initial time flux capacitor
    • Implement temporal navigation
    • Add paradox resolver
    • Finalize time travel function

You can view this history by running git log --oneline in the repository.

Tasks

  1. Create a lightweight tag named alpha-prototype for the commit that added the first functional component of the time machine (commit message: "Add initial time flux capacitor").
  2. Create an annotated tag named v1.0-release for the latest commit, marking it as the first stable release of the Chrono Codex.

Requirements

  1. All operations should be performed in the ~/project/chrono-codex directory.
  2. The annotated tag v1.0-release must include a message describing it as the "First stable release of the Chrono Codex".
  3. Use the correct commit hash for the alpha-prototype tag (you'll need to find this in the Git log).

Example

After completing the tasks, running git tag -n should produce output similar to this:

alpha-prototype Add initial time flux capacitor
v1.0-release    First stable release of the Chrono Codex
โœจ Check Solution and Practice

Summary

In this challenge, you've mastered the art of Git time travel by using tags to mark important milestones in the Chrono Codex project. You've learned how to create both lightweight and annotated tags, list tags, and display detailed tag information. These skills are crucial for managing version history in any software project, especially one as complex as a time machine! Remember, with great power comes great responsibility - use your Git tagging skills wisely to keep your project's timeline organized and accessible to all chrono-engineers of the future.