-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Devenvify project, remove Docker Compose dependency #15
base: main
Are you sure you want to change the base?
Conversation
# NOTE: it's very confusing that in a Flake usage context we still have to have this file | ||
inputs: | ||
devenv: | ||
url: github:thenonameguy/devenv/naked-shell |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need this file?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I was suprised myself, in a Flake context you would assume the Flake's devenv input governs the exact devenv version used. This is not the case the devenv has it's own internal Flake file, which uses a separate input when you invoke any devenv up
command for example.
Proof:
$ rm devenv.yaml
$ devenv up
Building shell ...
warning: updating lock file '/home/kszabo/projects/realworld-v1-rust-actix-web-diesel/devenv.lock':
• Updated input 'devenv':
'github:thenonameguy/devenv/4717da802b1868318ab60758c244c4b37774f426' (2022-12-20)
→ 'github:cachix/devenv/27f490910057a989ecac0851c5d3085bcebe1093?dir=src%2fmodules' (2022-12-19)
• Removed input 'devenv/flake-compat'
• Removed input 'devenv/nix'
• Removed input 'devenv/nix/lowdown-src'
• Removed input 'devenv/nix/nixpkgs'
• Removed input 'devenv/nix/nixpkgs-regression'
• Removed input 'devenv/nixpkgs'
• Removed input 'devenv/pre-commit-hooks'
• Removed input 'devenv/pre-commit-hooks/flake-compat'
• Removed input 'devenv/pre-commit-hooks/flake-utils'
• Removed input 'devenv/pre-commit-hooks/gitignore'
• Removed input 'devenv/pre-commit-hooks/gitignore/nixpkgs'
• Removed input 'devenv/pre-commit-hooks/nixpkgs'
• Removed input 'devenv/pre-commit-hooks/nixpkgs-stable'
warning: applying 'toString' to path '/home/kszabo/projects/realworld-v1-rust-actix-web-diesel/devenv.nix' and then accessing it is deprecated, at «stdin»:0
error:
… while evaluating the attribute 'config'
at «github:NixOS/nixpkgs/bb31220cca6d044baa6dc2715b07497a2a7c4bc7»/lib/modules.nix:341:9:
340| options = checked options;
341| config = checked (removeAttrs config [ "_module" ]);
| ^
342| _module = checked (config._module);
The option `services.postgres.initialDatabases' does not exist. Definition values:
- In `/home/kszabo/projects/realworld-v1-rust-actix-web-diesel/devenv.nix':
[
{
name = "realworld-rust-actix-web";
schema = <derivation init.sql>;
}
...
direnv: loading ~/projects/realworld-v1-rust-actix-web-diesel/.envrc
This is a huge UX painpoint with Flake-based usage, as you have keep track of inputs in 2 places so you don't end up in inconsistent scenarios.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
devenv up
will only work with devenv.*
files, avoiding the flakes. This is a drawback from the current use of flakes integration. Can be fixed though, could you open an issue please?
No description provided.