# Git Clone without Ancestry

My website, <https://codingindex.xyz> is run on GitHub pages. Whenever I write a blog post and push to the repository, a GitHub actions pulls that new blog post, does some processing, and publishes the resulting static site in the same repository.

Needless to say, this means that the repository is *huge.* Hence, on a new computer, it isn't really wise to clone the entire repository, because there is just no need to maintain ancestry.

Luckily, `git` has a way to clone without getting every single commit since the project started: `git clone <git url> --depth=1 --single-branch`. When doing `git log`, you will see that the latest commit has become `grafted`, which lets your repository pretend that it doesn't have parents past the latest commit (source: <https://stackoverflow.com/questions/27296188/what-exactly-is-a-grafted-commit-in-a-shallow-clone>).


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://chaos.codingindex.xyz/git-clone-without-ancestry.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
