mirror of
https://github.com/ryanccn/flake.git
synced 2025-12-06 08:10:43 +01:00
refactor: use home.sessionVariables
This commit is contained in:
parent
e4672c464a
commit
3a7c130767
6 changed files with 14 additions and 31 deletions
2
home.nix
2
home.nix
|
|
@ -6,9 +6,11 @@
|
||||||
...
|
...
|
||||||
}: {
|
}: {
|
||||||
home.stateVersion = "23.05";
|
home.stateVersion = "23.05";
|
||||||
|
|
||||||
imports = [
|
imports = [
|
||||||
ctpModule
|
ctpModule
|
||||||
discord-applemusic-rich-presence
|
discord-applemusic-rich-presence
|
||||||
|
./programs/variables.nix
|
||||||
./programs/zsh.nix
|
./programs/zsh.nix
|
||||||
./programs/fish.nix
|
./programs/fish.nix
|
||||||
./programs/starship.nix
|
./programs/starship.nix
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,4 @@
|
||||||
# basic environment variables
|
# ls
|
||||||
set -x LANG en_US.UTF-8
|
|
||||||
set -x EDITOR hx
|
|
||||||
set -x PAGER less
|
|
||||||
set -x LESS -R
|
|
||||||
set -x LS_COLORS "$(vivid generate catppuccin-frappe)"
|
set -x LS_COLORS "$(vivid generate catppuccin-frappe)"
|
||||||
|
|
||||||
# nix path patches
|
# nix path patches
|
||||||
|
|
|
||||||
|
|
@ -2,15 +2,9 @@
|
||||||
set -x SSH_AUTH_SOCK "$HOME/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"
|
set -x SSH_AUTH_SOCK "$HOME/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"
|
||||||
|
|
||||||
# Homebrew shell
|
# Homebrew shell
|
||||||
set -x HOMEBREW_NO_ANALYTICS 1
|
|
||||||
set -x HOMEBREW_CASK_OPTS --require-sha
|
|
||||||
set -x HOMEBREW_NO_INSECURE_REDIRECT 1
|
|
||||||
set -x HOMEBREW_NO_EMOJI 1
|
|
||||||
/opt/homebrew/bin/brew shellenv | source
|
/opt/homebrew/bin/brew shellenv | source
|
||||||
|
|
||||||
# fnm shell env
|
# fnm shell env
|
||||||
set -gx FNM_RESOLVE_ENGINES true
|
|
||||||
set -gx FNM_COREPACK_ENABLED true
|
|
||||||
fnm env --use-on-cd | source
|
fnm env --use-on-cd | source
|
||||||
|
|
||||||
# cargo
|
# cargo
|
||||||
|
|
@ -21,11 +15,6 @@ fish_add_path "$HOME/.deno/bin"
|
||||||
# pnpm
|
# pnpm
|
||||||
set -x PNPM_HOME "$HOME/Library/pnpm"
|
set -x PNPM_HOME "$HOME/Library/pnpm"
|
||||||
|
|
||||||
# disable telemetry
|
|
||||||
set -x NEXT_TELEMETRY_DISABLED 1 # Next.js
|
|
||||||
set -x CHECKPOINT_DISABLE 1 # Prisma
|
|
||||||
set -x DISABLE_TELEMETRY YES # diffusers
|
|
||||||
|
|
||||||
# direnv
|
# direnv
|
||||||
set -x DIRENV_LOG_FORMAT ""
|
set -x DIRENV_LOG_FORMAT ""
|
||||||
|
|
||||||
|
|
|
||||||
11
programs/variables.nix
Normal file
11
programs/variables.nix
Normal file
|
|
@ -0,0 +1,11 @@
|
||||||
|
_: {
|
||||||
|
home.sessionVariables = {
|
||||||
|
NEXT_TELEMETRY_DISABLED = "1";
|
||||||
|
CHECKPOINT_DISABLE = "1";
|
||||||
|
DISABLE_TELEMETRY = "YES";
|
||||||
|
ASTRO_TELEMETRY_DISABLED = "1";
|
||||||
|
|
||||||
|
FNM_RESOLVE_ENGINES = "true";
|
||||||
|
FNM_COREPACK_ENABLED = "true";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
@ -2,10 +2,6 @@
|
||||||
export SSH_AUTH_SOCK="$HOME/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"
|
export SSH_AUTH_SOCK="$HOME/Library/Group Containers/2BUA8C4S2C.com.1password/t/agent.sock"
|
||||||
|
|
||||||
# Homebrew shell
|
# Homebrew shell
|
||||||
export HOMEBREW_NO_ANALYTICS=1
|
|
||||||
export HOMEBREW_CASK_OPTS=--require-sha
|
|
||||||
export HOMEBREW_NO_INSECURE_REDIRECT=1
|
|
||||||
export HOMEBREW_NO_EMOJI=1
|
|
||||||
eval "$(/opt/homebrew/bin/brew shellenv)"
|
eval "$(/opt/homebrew/bin/brew shellenv)"
|
||||||
|
|
||||||
# fnm shell env
|
# fnm shell env
|
||||||
|
|
@ -17,11 +13,6 @@ export PATH="$HOME/.deno/bin:$PATH"
|
||||||
# pnpm
|
# pnpm
|
||||||
export PNPM_HOME="${HOME}/Library/pnpm"
|
export PNPM_HOME="${HOME}/Library/pnpm"
|
||||||
|
|
||||||
# disable telemetry
|
|
||||||
export NEXT_TELEMETRY_DISABLED=1 # Next.js
|
|
||||||
export CHECKPOINT_DISABLE=1 # Prisma
|
|
||||||
export DISABLE_TELEMETRY=YES # diffusers
|
|
||||||
|
|
||||||
# direnv
|
# direnv
|
||||||
export DIRENV_LOG_FORMAT=""
|
export DIRENV_LOG_FORMAT=""
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,4 @@
|
||||||
# environment variables
|
# environment variables
|
||||||
export LANG=en_US.UTF-8
|
|
||||||
|
|
||||||
export EDITOR="hx"
|
|
||||||
export PAGER="less"
|
|
||||||
export LESS="-R"
|
|
||||||
|
|
||||||
export FZF_DEFAULT_OPTS=" \
|
export FZF_DEFAULT_OPTS=" \
|
||||||
--color=bg+:#414559,bg:#303446,spinner:#f2d5cf,hl:#e78284 \
|
--color=bg+:#414559,bg:#303446,spinner:#f2d5cf,hl:#e78284 \
|
||||||
--color=fg:#c6d0f5,header:#e78284,info:#ca9ee6,pointer:#f2d5cf \
|
--color=fg:#c6d0f5,header:#e78284,info:#ca9ee6,pointer:#f2d5cf \
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue