mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-07-11 23:22:40 +02:00
refactor: development environment
This commit is contained in:
Generated
+34
@@ -187,6 +187,38 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"catppuccin-wezterm": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681259790,
|
||||||
|
"narHash": "sha256-McSWoZaJeK+oqdK/0vjiRxZGuLBpEB10Zg4+7p5dIGY=",
|
||||||
|
"owner": "catppuccin",
|
||||||
|
"repo": "wezterm",
|
||||||
|
"rev": "b1a81bae74d66eaae16457f2d8f151b5bd4fe5da",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "catppuccin",
|
||||||
|
"repo": "wezterm",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"cattppuccin-k9s": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1690140445,
|
||||||
|
"narHash": "sha256-PtBJRBNbLkj7D2ko7ebpEjbfK9Ywjs7zbE+Y8FQVEfA=",
|
||||||
|
"owner": "catppuccin",
|
||||||
|
"repo": "k9s",
|
||||||
|
"rev": "516f44dd1a6680357cb30d96f7e656b653aa5059",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "catppuccin",
|
||||||
|
"repo": "k9s",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"darwin": {
|
"darwin": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
@@ -659,6 +691,8 @@
|
|||||||
"catppuccin-helix": "catppuccin-helix",
|
"catppuccin-helix": "catppuccin-helix",
|
||||||
"catppuccin-hyprland": "catppuccin-hyprland",
|
"catppuccin-hyprland": "catppuccin-hyprland",
|
||||||
"catppuccin-starship": "catppuccin-starship",
|
"catppuccin-starship": "catppuccin-starship",
|
||||||
|
"catppuccin-wezterm": "catppuccin-wezterm",
|
||||||
|
"cattppuccin-k9s": "cattppuccin-k9s",
|
||||||
"home-manager": "home-manager_2",
|
"home-manager": "home-manager_2",
|
||||||
"hyprland": "hyprland",
|
"hyprland": "hyprland",
|
||||||
"mysecrets": "mysecrets",
|
"mysecrets": "mysecrets",
|
||||||
|
|||||||
@@ -247,6 +247,10 @@
|
|||||||
url = "github:catppuccin/alacritty";
|
url = "github:catppuccin/alacritty";
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
catppuccin-wezterm = {
|
||||||
|
url = "github:catppuccin/wezterm";
|
||||||
|
flake = false;
|
||||||
|
};
|
||||||
catppuccin-helix = {
|
catppuccin-helix = {
|
||||||
url = "github:catppuccin/helix";
|
url = "github:catppuccin/helix";
|
||||||
flake = false;
|
flake = false;
|
||||||
@@ -263,6 +267,10 @@
|
|||||||
url = "github:catppuccin/cava";
|
url = "github:catppuccin/cava";
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
cattppuccin-k9s = {
|
||||||
|
url = "github:catppuccin/k9s";
|
||||||
|
flake = false;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
pkgs-unstable,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
# general tools
|
||||||
|
terraform
|
||||||
|
# terraformer # generate terraform configs from existing cloud resources
|
||||||
|
pulumi
|
||||||
|
pulumictl
|
||||||
|
# istioctl
|
||||||
|
|
||||||
|
# aws
|
||||||
|
awscli2
|
||||||
|
aws-iam-authenticator
|
||||||
|
eksctl
|
||||||
|
];
|
||||||
|
|
||||||
|
programs = {
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
pkgs-unstable,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
skopeo
|
||||||
|
docker-compose
|
||||||
|
dive # explore docker layers
|
||||||
|
];
|
||||||
|
|
||||||
|
programs = {
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
{ ... }: {
|
||||||
|
imports = [
|
||||||
|
./container.nix
|
||||||
|
./kubernetes.nix
|
||||||
|
];
|
||||||
|
}
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
pkgs-unstable,
|
||||||
|
cattppuccin-k9s,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
kubectl
|
||||||
|
kubernetes-helm
|
||||||
|
];
|
||||||
|
|
||||||
|
programs = {
|
||||||
|
k9s = {
|
||||||
|
enable = true;
|
||||||
|
skin =
|
||||||
|
let
|
||||||
|
skin_file = "${cattppuccin-k9s}/dist/mocha.yml"; # theme - cattppuccin mocha
|
||||||
|
skin_attr = builtins.fromJSON (builtins.readFile
|
||||||
|
# replace 'base: &base "#1e1e2e"' with 'base: &base "default"'
|
||||||
|
# to make fg/bg color transparent
|
||||||
|
(pkgs.runCommandNoCC "get-skin-json" {} ''
|
||||||
|
cat ${skin_file} \
|
||||||
|
| sed -E 's@(base: &base ).+@\1 "default"@g' \
|
||||||
|
| ${pkgs.yj}/bin/yj > $out
|
||||||
|
'')
|
||||||
|
);
|
||||||
|
in
|
||||||
|
skin_attr;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -2,12 +2,13 @@
|
|||||||
imports = [
|
imports = [
|
||||||
../server
|
../server
|
||||||
|
|
||||||
|
./cloud
|
||||||
|
./container
|
||||||
./neovim
|
./neovim
|
||||||
|
./terminal
|
||||||
|
|
||||||
./alacritty.nix
|
|
||||||
./development.nix
|
./development.nix
|
||||||
./helix.nix
|
./helix.nix
|
||||||
./kitty.nix
|
|
||||||
./media.nix
|
./media.nix
|
||||||
./shell.nix
|
./shell.nix
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -16,24 +16,6 @@
|
|||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
pkgs-unstable.devbox
|
pkgs-unstable.devbox
|
||||||
|
|
||||||
# cloud native
|
|
||||||
skopeo
|
|
||||||
docker-compose
|
|
||||||
dive # explore docker layers
|
|
||||||
kubectl
|
|
||||||
kubernetes-helm
|
|
||||||
terraform
|
|
||||||
# terraformer # generate terraform configs from existing cloud resources
|
|
||||||
pulumi
|
|
||||||
pulumictl
|
|
||||||
k9s
|
|
||||||
# istioctl
|
|
||||||
|
|
||||||
# cloud provider
|
|
||||||
awscli2
|
|
||||||
aws-iam-authenticator
|
|
||||||
eksctl
|
|
||||||
|
|
||||||
# DO NOT install build tools for C/C++ and others, set it per project by devShell instead
|
# DO NOT install build tools for C/C++ and others, set it per project by devShell instead
|
||||||
gnumake # used by this repo, to simplify the deployment
|
gnumake # used by this repo, to simplify the deployment
|
||||||
jdk17 # used to run some java based tools(.jar)
|
jdk17 # used to run some java based tools(.jar)
|
||||||
|
|||||||
@@ -0,0 +1,7 @@
|
|||||||
|
{...}: {
|
||||||
|
imports = [
|
||||||
|
./alacritty.nix
|
||||||
|
./kitty.nix
|
||||||
|
./wezterm.nix
|
||||||
|
];
|
||||||
|
}
|
||||||
@@ -30,7 +30,10 @@
|
|||||||
{
|
{
|
||||||
programs.kitty = {
|
programs.kitty = {
|
||||||
enable = true;
|
enable = true;
|
||||||
theme = "Catppuccin-Mocha"; # kitty has catppuccin theme built-in
|
# kitty has catppuccin theme built-in,
|
||||||
|
# all the built-in themes are packaged into an extra package named `kitty-themes`
|
||||||
|
# and it's installed by home-manager if `theme` is specified.
|
||||||
|
theme = "Catppuccin-Mocha";
|
||||||
font = {
|
font = {
|
||||||
name = "JetBrainsMono Nerd Font";
|
name = "JetBrainsMono Nerd Font";
|
||||||
# use different font size on macOS
|
# use different font size on macOS
|
||||||
@@ -0,0 +1,52 @@
|
|||||||
|
{
|
||||||
|
lib,
|
||||||
|
pkgs,
|
||||||
|
catppuccin-wezterm,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
###########################################################
|
||||||
|
#
|
||||||
|
# Wezterm Configuration
|
||||||
|
#
|
||||||
|
###########################################################
|
||||||
|
{
|
||||||
|
# wezterm has catppuccin theme built-in,
|
||||||
|
# it's not necessary to install it separately.
|
||||||
|
# xdg.configFile."wezterm/colors".source = "${catppuccin-wezterm}/dist";
|
||||||
|
|
||||||
|
programs.wezterm = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
extraConfig =
|
||||||
|
let
|
||||||
|
fontsize = if pkgs.stdenv.isDarwin then "14.0" else "13.0";
|
||||||
|
in
|
||||||
|
''
|
||||||
|
-- Pull in the wezterm API
|
||||||
|
local wezterm = require 'wezterm'
|
||||||
|
|
||||||
|
-- This table will hold the configuration.
|
||||||
|
local config = {}
|
||||||
|
|
||||||
|
-- In newer versions of wezterm, use the config_builder which will
|
||||||
|
-- help provide clearer error messages
|
||||||
|
if wezterm.config_builder then
|
||||||
|
config = wezterm.config_builder()
|
||||||
|
end
|
||||||
|
|
||||||
|
-- This is where you actually apply your config choices
|
||||||
|
config.color_scheme = "Catppuccin Mocha"
|
||||||
|
config.font = wezterm.font("JetBrains Mono")
|
||||||
|
config.hide_tab_bar_if_only_one_tab = true
|
||||||
|
config.scrollback_lines = 10000
|
||||||
|
config.enable_scroll_bar = true
|
||||||
|
|
||||||
|
config.font_size = ${fontsize}
|
||||||
|
'' + (if pkgs.stdenv.isDarwin then ''
|
||||||
|
-- Spawn a fish shell in login mod
|
||||||
|
config.default_prog = { '/run/current-system/sw/bin/nu', '-l' }
|
||||||
|
'' else "") + ''
|
||||||
|
return config
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -25,6 +25,7 @@
|
|||||||
ipcalc # it is a calculator for the IPv4/v6 addresses
|
ipcalc # it is a calculator for the IPv4/v6 addresses
|
||||||
|
|
||||||
# misc
|
# misc
|
||||||
|
tldr
|
||||||
cowsay
|
cowsay
|
||||||
file
|
file
|
||||||
which
|
which
|
||||||
|
|||||||
Reference in New Issue
Block a user