Skip to content

Commit

Permalink
Update 2021-11-17
Browse files Browse the repository at this point in the history
  • Loading branch information
abcdw committed Nov 17, 2021
1 parent 08e0db2 commit c642dc2
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 2 deletions.
2 changes: 2 additions & 0 deletions notes/20210805075718-the_modern_emacs.org
@@ -1,7 +1,9 @@
:PROPERTIES:
:ID: 95f5c8a7-007a-4b0c-b3c7-c971d0346b98
:ROAM_REFS: https://youtu.be/ZbxUJz6a9Io
:END:
#+title: The Modern Emacs
#+filetags: :Stream:

* Introduction
- How to handle it?
Expand Down
1 change: 1 addition & 0 deletions notes/20210823124653-per_project_dev_environment.org
@@ -1,5 +1,6 @@
:PROPERTIES:
:ID: 65d096bd-7438-4b25-af01-e7da37aafade
:ROAM_REFS: https://youtu.be/pS9JBKdAy4Q
:END:
#+title: Per-Project Dev Environment
#+filetags: Stream
Expand Down
2 changes: 2 additions & 0 deletions notes/20210903103806-not_very_advanced_git.org
@@ -1,7 +1,9 @@
:PROPERTIES:
:ID: d0311574-3528-49fb-95a5-2233b2b371a9
:ROAM_REFS: https://youtu.be/tPp1dQ8y9jM
:END:
#+title: Not Very Advanced Git
#+filetags: :Stream:

* Introduction
Expectations: Intermediate level of Git knowledge.
Expand Down
1 change: 1 addition & 0 deletions notes/20210920113750-deploy_gnu_guix_to_vps.org
@@ -1,5 +1,6 @@
:PROPERTIES:
:ID: d7739104-da63-4206-b0ff-f4fa04039f0d
:ROAM_REFS: https://youtu.be/55KUH4g1OOc
:END:
#+title: Deploy GNU Guix to VPS
#+filetags: :Stream:
Expand Down
1 change: 1 addition & 0 deletions notes/20210923100149-guix_escape_hatches.org
@@ -1,5 +1,6 @@
:PROPERTIES:
:ID: f6b05f22-746c-4d78-bba2-61a8706c6609
:ROAM_REFS: https://youtu.be/0-2RyRKEPcY
:END:
#+title: Guix Escape Hatches
#+filetags: :Stream:
Expand Down
54 changes: 52 additions & 2 deletions notes/20211111141408-guix_shell_overview.org
@@ -1,21 +1,71 @@
:PROPERTIES:
:ID: 070a6b4b-39ef-4233-8a83-753ca2a4a8bd
:ROAM_REFS: https://youtu.be/UMCHuHSlVWk
:END:
#+title: guix shell: Overview
#+filetags: :Stream:

* Introduction
SCHEDULED: <2021-11-16 Tue>
- Overview of ~guix shell~.
- Comparison with ~guix environment~ and ~virtualenv~.
- Practical example and integration with [[https://direnv.net/][direnv]].
- [[id:65d096bd-7438-4b25-af01-e7da37aafade][Per-Project Dev Environment]].
* What ~guix shell~ is?
- universal virtualenv
- successor of ~guix environment~
- The tool for trying out software.
- The tool for spinning up development environments.
- Universal virtualenv.
- The tool for making isolated environments.
- Successor of ~guix environment~.
* Differences with ~guix environment~
** ad-hoc by default
** Support for guix.scm and manifest.scm
- ~guix shell~ automatically loads them if no arguments provided.
- Difference between guix.scm and manifest.scm.
- Show ~~/tmp/htop~ example
** Composable switches
** Caching
#+begin_src shell
guix shell -- make
#+end_src
* Examples
** Trying out a Package
#+begin_src shell
guix shell htop -- htop
#+end_src
** Executing in Isolated Environment
#+begin_src shell
guix shell htop --preserve=$ --container
#+end_src
** Preventing Garbage Collection
#+begin_src shell
guix shell htop -r ./persistent-profile
guix gc --list-roots
#+end_src
** Reproducible Development Environment
#+begin_src shell
guix describe -f channels > ./channels.scm
guix time-machine -C ./channels.scm -- shell
#+end_src
* How to Integrate it with direnv?
#+begin_src shell :results verbatim
guix shell python python-numpy --search-paths
#+end_src

#+RESULTS:
: export PATH="/gnu/store/lk53yz7cgj6kgw1m82mfs0843j3bgpn5-profile/bin${PATH:+:}$PATH"
: export PYTHONPATH="/gnu/store/lk53yz7cgj6kgw1m82mfs0843j3bgpn5-profile/lib/python3.8/site-packages${PYTHONPATH:+:}$PYTHONPATH"

[[file:~/work/rde/rde/features/shellutils.scm::(simple-service][features/shellutils.scm]]
* Questions
- Other tools for making dev environments.
- What to do with dev-time dependencies?
* Conclusion
- Universal, fast, feature rich, well-integrating and user-friendly tool.
- We can make it ultimate by providing additional APIs for generating
packages.
* Links
- https://guix.gnu.org/en/blog/2021/from-guix-environment-to-guix-shell/
- https://guix.gnu.org/manual/devel/en/html_node/Invoking-guix-package.html#index-manifest
- https://guix.gnu.org/manual/devel/en/html_node/Invoking-guix-shell.html#Invoking-guix-shell
- https://github.com/direnv/direnv/blob/master/stdlib.sh

0 comments on commit c642dc2

Please sign in to comment.