# What is the point of using \`nix-shell\` with a function?

**URL:** https://discourse.nixos.org/t/what-is-the-point-of-using-nix-shell-with-a-function/8473
**Category:** Help
**Created:** [August 6, 2020, 9:40pm UTC](https://discourse.nixos.org/t/what-is-the-point-of-using-nix-shell-with-a-function/8473 "2020-08-06T21:40:00Z")
**Posts on this page:** 1
**Showing post:** 5

<div class="post-metadata">

### Author: ![toraritte](https://discourse.nixos.org/user_avatar/discourse.nixos.org/toraritte/32/6777_2.png) [@toraritte](https://discourse.nixos.org/u/toraritte)
#### Post date: [August 6, 2020, 11:30pm UTC](https://discourse.nixos.org/t/what-is-the-point-of-using-nix-shell-with-a-function/8473/5 "2020-08-06T23:30:16Z")

</div>

Now that you mention `nix-build`, would you share where `nix-build` and `nix-shell` is implemented in hnix? I think I found their source in NixOS/nix repo in [`nix-build.cc`](https://github.com/NixOS/nix/blob/b3e73547a03f068ae4dd9cca4bc865cde85c8dec/src/nix-build/nix-build.cc) (see [thread](https://discourse.nixos.org/t/use-buildinputs-or-nativebuildinputs-for-nix-shell/8464/3)) but it eluded me there.

---

_[View the full topic](https://discourse.nixos.org/t/what-is-the-point-of-using-nix-shell-with-a-function/8473)._
