# Accessing .git directory in flake with local source

**URL:** https://discourse.nixos.org/t/accessing-git-directory-in-flake-with-local-source/17370
**Category:** Help
**Created:** [January 27, 2022, 5:55pm UTC](https://discourse.nixos.org/t/accessing-git-directory-in-flake-with-local-source/17370 "2022-01-27T17:55:57Z")
**Posts on this page:** 1
**Showing post:** 4

<div class="post-metadata">

### Author: ![tobiasBora](https://discourse.nixos.org/letter_avatar_proxy/v4/letter/t/9de0a6/32.png) [@tobiasBora](https://discourse.nixos.org/u/tobiasBora)
#### Post date: [January 28, 2022, 7:21am UTC](https://discourse.nixos.org/t/accessing-git-directory-in-flake-with-local-source/17370/4 "2022-01-28T07:21:14Z")

</div>

At some points people mentionned that it could be possible to implement a tool that fake git. For instance by pre-recording git outputs and playing them in a dummy executable. It may even be possible to semi-automate the process by generating a json file while compiling in a nix shell, and then reuse this in the derivation, but it may be a bit annoying to do everytime we upgrade the package. At least the hash of the derivation is guaranteed to never shift.

---

_[View the full topic](https://discourse.nixos.org/t/accessing-git-directory-in-flake-with-local-source/17370)._
