direnv
asdf
Our great sponsors
direnv | asdf | |
---|---|---|
157 | 339 | |
11,561 | 20,215 | |
2.1% | 3.0% | |
8.8 | 7.9 | |
8 days ago | 10 days ago | |
Go | Shell | |
MIT License | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
direnv
-
Nix-direnv is a quality of life improvement
I also made the export diff configurable, motivated by this post: https://github.com/direnv/direnv/pull/1233
-
Conditional Git Configuration
Nice.
For years I've been using [direnv](https://direnv.net/) for this, setting environment variables which git picks up. This looks like a more feature complete equivalent, although to be honest I only really need switching of committer email and the SSH key used.
- FLaNK 25 December 2023
-
Development Environments with Guix, similar to devenv.sh
Direnv, for the uninitiated, loads and unloads environment variables when directories are entered and exited. Under every project folder there is a `$PROJ_DIR/.envrc` which contains:
-
Emacs Advent Calendar 9: devdocs, code-cells, dREPL, etc.
buffer-env: A pure-Elisp version of the direnv utility. Useful to make Emacs aware of Python virtualenvs (which, judging by the questions posted here, is unfortunately still a complication for a lot of people). Similar to (and inspired by) envrc, but doesn't require the direnv program.
-
golang cli vs env var in windows?
You can look at direnv to see this in action as they wrote shell hooks that get loaded into the shell profile and are executed on every prompt. https://direnv.net/
-
Nix Survival Mode: macOS upgrades won't break Nix anymore
Yes, most Nix users employ https://direnv.net or the equivalent for your IDE of choice. Emacs for instance has https://github.com/purcell/envrc which set per-buffer variables.
-
What Is Wrong with TOML?
The more applications I write, the more I tend to avoid typical config files in favor of using direnv [0] to set environment variables.
asdf
-
Volta – Fastest Node version manager in Rust
Or if you need to manage more than just node, asdf has been around for over a decade and works great. You can use a .tool-versions to change runtimes for each project you have, in addition to managing your global runtime versions
-
Pyenv – lets you easily switch between multiple versions of Python
https://asdf-vm.com/ ASDF is better because it works with many more languages, other than only Python, like Rust, Go, Node, etc, and other tools, such as AWS/Google/Firebase/Azure CLIs.
Why not just use a tool like asdf (https://asdf-vm.com/) or mise (https://mise.jdx.dev/)?
These tools have the advantage of not being multi-taskers and can manage version for all your tools. You wouldn’t need pyenv and npm and rvm and…
We’ve even started committing the .mise.toml files for projects to our repos. That way, since we work on multiple projects that may need multiple versions of the same tool, it’s handled and documented.
-
A Journey to Find an Ultimate Development Environment
The purpose of a version manager is to help you navigate or install any tools for development easily. Version Manager can be one tool for each dependency (e.g. NVM, g) or One tool for all dependencies (e.g. asdf, mise).
-
Beginners Intro to Trunk Based Development
Secondly, our development environments must not drift, because then code may behave differently and a change could pass on our machine but fail in production. There are many tools for locking down environments, e.g nix, pkgx, asdf, containers, etc., and they all share the common goal of being able to lock down dependencies for an environment accurately and deterministically. And that needs to be enforced in our local workflow so we don't have to rely on CI environments for correctness. All developers must have environments that are effectively identical to what runs in CI (which itself should be representative of the production environment).
-
Practical Guide to Trunk Based Development
There are many ways this can be done (e.g nix, pkgx, asdf, containers, etc.), and we won’t get into which specific tools to use, because we'll instead cover the essential essence of preventing environment drift:
-
Criando seu ambiente com ASDF
git clone https://github.com/asdf-vm/asdf.git ~/.asdf --branch v0.13.1
-
Kotlin version manager
I've really been enjoying asdf, which is a program that allows you to install specified versions of dev utilities as well as dynamically manage them via shims and .tool-versions files.
-
How do i keep my "devops tool" always up to date in a smart way ?
I use the asdf version manager.
What are some alternatives?
SDKMan - The SDKMAN! Command Line Interface
pyenv - Simple Python version management
rbenv - Manage your app's Ruby environment
nvm - Node Version Manager - POSIX-compliant bash script to manage multiple active node.js versions
volta - Volta: JS Toolchains as Code. ⚡
HomeBrew - 🍺 The missing package manager for macOS (or Linux)
mise - dev tools, env vars, task runner
jenv - Manage your Java environment
nvm for Windows - A node.js version management utility for Windows. Ironically written in Go.
fnm - 🚀 Fast and simple Node.js version manager, built in Rust
RVM - Ruby enVironment Manager (RVM)
nix - Nix, the purely functional package manager