# \`flox install .\` builds package but does not include it into environment?

**URL:** <https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807>\
**Category:** Developing with flox\
**Created:** [October 10, 2023, 12:15pm UTC](https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807 "2023-10-10T12:15:34Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anon59756714](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@anon59756714](https://discourse.flox.dev/u/anon59756714)\
**Post date:** [October 10, 2023, 12:15pm UTC](https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807/1 "2023-10-10T12:15:34Z")

</div>

I built an own package based on spotify\_player and it builds under flox build successfuly, flox run also works. I tried to run `flox install .` and it does installation but flox list shows nothing. I tried adding package name to flox install but it does not work.

For now I just linked ./result/bin/spotify\_player to ~/.local/bin, but is there option to locally install a flake? I could try doing publish but it seems it’s not polished yet, guessing on other topics.

---

<div class="post-metadata">

**Author:** ![ysndr](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.flox.dev/ysndr/32/340_2.png) [@ysndr](https://discourse.flox.dev/u/ysndr)\
**Post date:** [October 10, 2023, 3:28pm UTC](https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807/2 "2023-10-10T15:28:11Z")

</div>

Hej again!

Please understand that i have to preface this answer with the obligatory disclaimer that flox we are reworking the environment concepts and the answer to this question will change over the coming weeks.

If you already have a flake, i.e. initialized your package with flox, locally you should be able to install packages from that project using

```shell
$ flox install git+file://$PWD#spotify_player

```

assuming you package is defined in `./pkgs/spotify_player`.

Mind, that you might be unable to share this environment off of your machine as it will depend on an absolute path. If you have the repository with the package pushed to github you can also build it from there using a flake reference:

```shell
$ flox install git+ssh://git@github.com/owner/repo#spotify_player

```

The “intended” way of installing packages is to first _publish_ them to a catalog, and install them from there. That way flox has a machine independent way of referring to packages and is able to apply some performance optimizations.

However, since we are currently focused on environments themself with building and publishing further down the list, you may have a better experience using flake references for the time being.

---

<div class="post-metadata">

**Author:** ![anon59756714](https://avatars.discourse-cdn.com/v4/letter/a/48db29/32.png) [@anon59756714](https://discourse.flox.dev/u/anon59756714)\
**Post date:** [October 10, 2023, 5:20pm UTC](https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807/3 "2023-10-10T17:20:55Z")

</div>

nice, yeah this works, quite slowly but works 🙂 Exporting environments is on my list to do to share envs between machines. I tried it once but older version of Flox just force-pushed my master branch when I tried to do that 😃

---

<div class="post-metadata">

**Author:** ![robinbrantley](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.flox.dev/robinbrantley/32/39_2.png) [@robinbrantley](https://discourse.flox.dev/u/robinbrantley)\
**Post date:** [October 10, 2023, 7:08pm UTC](https://discourse.flox.dev/t/flox-install-builds-package-but-does-not-include-it-into-environment/807/4 "2023-10-10T19:08:07Z")

</div>

Hi @anon59756714 - glad you have a workaround for now.  
Please do keep an eye out regarding our release notes for updates as we move forward on these CLI changes so you can test them out when they are ready and give us feedback. 🙂
