Skip to content

Commit

Permalink
chore: move back to devenv.nix
Browse files Browse the repository at this point in the history
  • Loading branch information
bklebe committed Jun 18, 2024
1 parent 378dc7a commit 13438ec
Show file tree
Hide file tree
Showing 6 changed files with 77 additions and 517 deletions.
11 changes: 2 additions & 9 deletions .envrc
Original file line number Diff line number Diff line change
@@ -1,10 +1,3 @@
if ! has nix_direnv_version || ! nix_direnv_version 2.2.1; then
source_url "https://raw.githubusercontent.com/nix-community/nix-direnv/2.2.1/direnvrc" "sha256-zelF0vLbEl5uaqrfIzbgNzJWGmLzCmYAkInj/LNxvKs="
fi
source_url "https://raw.githubusercontent.com/cachix/devenv/95f329d49a8a5289d31e0982652f7058a189bfca/direnvrc" "sha256-d+8cBpDfDBj41inrADaJt+bDWhOktwslgoP5YiGJ1v0="

nix_direnv_watch_file flake.nix
nix_direnv_watch_file flake.lock
if ! use flake . --impure
then
echo "devenv could not be built. The devenv environment was not loaded. Make the necessary changes to devenv.nix and hit enter to try again." >&2
fi
use devenv
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,3 +58,12 @@ devenv.local.nix

# pre-commit
.pre-commit-config.yaml
# Devenv
.devenv*
devenv.local.nix

# direnv
.direnv

# pre-commit
.pre-commit-config.yaml
51 changes: 51 additions & 0 deletions devenv.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{ pkgs, lib, config, inputs, ... }:

{
cachix.enable = false;

# https://devenv.sh/packages/
packages = [
pkgs.awscli2
pkgs.chezmoi
pkgs.colima
pkgs.direnv
pkgs.docker
pkgs.docker-buildx
pkgs.docker-compose
pkgs.gh
pkgs.git
pkgs.graphviz
pkgs.jq
pkgs.jujutsu
pkgs.mise
pkgs.mosquitto
pkgs.nixfmt-rfc-style
pkgs.pandoc
pkgs.protobuf
pkgs.ripgrep
pkgs.rustup
pkgs.scc
pkgs.shfmt
];

enterShell = ''
'';

# https://devenv.sh/tests/
enterTest = ''
'';

# https://devenv.sh/services/
# services.postgres.enable = true;

# https://devenv.sh/languages/
# languages.nix.enable = true;

# https://devenv.sh/pre-commit-hooks/
# pre-commit.hooks.shellcheck.enable = true;

# https://devenv.sh/processes/
# processes.ping.exec = "ping example.com";

# See full reference at https://devenv.sh/reference/options/
}
15 changes: 15 additions & 0 deletions devenv.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# yaml-language-server: $schema=https://devenv.sh/devenv.schema.json
inputs:
nixpkgs:
url: github:cachix/devenv-nixpkgs/rolling

# If you're using non-OSS software, you can set allowUnfree to true.
# allowUnfree: true

# If you're willing to use a package that's vulnerable
# permittedInsecurePackages:
# - "openssl-1.1.1w"

# If you have more than one devenv you can merge them
#imports:
# - ./backend
Loading

0 comments on commit 13438ec

Please sign in to comment.