aboutsummaryrefslogtreecommitdiff
path: root/.profile
blob: b85ef65286c7ff0d11b4b5e124c1d7771cc7330c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
#!/bin/sh
#
# this file should only contain posix-compliant shell customizations and
# environment variables. shell-specific customizations should be done in the
# respective shell's profile or init file (e.g. .zshrc, .bash_profile, etc.)

# AJATT (user account only because TTYs don't render non-ascii characters)
export LANG="ja_JP.UTF-8"

# aliases
alias cls="clear"
alias vim="nvim"
alias copy="xclip -selection c"
alias dnd="dragon-drag-and-drop -a -x"
alias mk="make"
alias sl="sl -w"
alias vv="neovide"

# one letters
alias r="ranger"
alias v="nvim"
alias m="neomutt"
alias y="yay"
alias n="ncmpcpp"
alias c="khal"
alias f="fork"
alias p="pass"

# "functions"
alias reload="sudo systemctl restart lightdm"
alias screenrecord='giph -f 60 -s -b 4 -c 255,255,255 $(date +"$HOME/%Y-%m-%d_%H-%M-%S.mp4")'

# fontpreview
if [ -n "$DISPLAY" ]; then
	export FONTPREVIEW_BG_COLOR="$(xrdb -query | grep background | cut -f2)"
	export FONTPREVIEW_FG_COLOR="$(xrdb -query | grep foreground | cut -f2)"
fi

# bat
alias bat="bat -pp --theme=base16"

# force colorterm
export COLORTERM="truecolor"

# xdg base directories
export XDG_CONFIG_HOME="$HOME/.config"
export XDG_CACHE_HOME="$HOME/.cache"
export XDG_DATA_HOME="$HOME/.local/share"

# script locations
export PATH="$HOME/.local/share/bin:$PATH"
export PATH="$HOME/.local/bin:$PATH"
export PATH="$HOME/.local/go/bin:$PATH"
export PATH="$HOME/.local/share/cargo/bin:$PATH"
# export PATH="/opt/f4pga/xc7/conda/bin:$PATH"
export PATH="$HOME/.lyp/bin:$PATH"

# other stuff
export EDITOR="nvim"
export FZF_DEFAULT_COMMAND="find ."
export FZF_DEFAULT_OPTS="--color=16"
export GOPATH="$HOME/.local/go"
. "$XDG_CONFIG_HOME/gtk-4.0/env"

# use .config/ instead of home directory
export ANDROID_SDK_HOME="$XDG_CONFIG_HOME/android"
export ADB_VENDOR_KEY="$XDG_CONFIG_HOME/android"
export CARGO_HOME="$XDG_DATA_HOME/cargo"
export gnome_user_dir="$HOME/.config/gnome/apps"
export GNUPGHOME="$XDG_DATA_HOME/gnupg"
export GRADLE_USER_HOME="$XDG_DATA_HOME/gradle"
export NPM_CONFIG_USERCONFIG="$XDG_CONFIG_HOME/npm/npmrc"
export PARALLEL_HOME="$XDG_CONFIG_HOME/parallel"
export PYLINTHOME="$XDG_CACHE_HOME/pylint"
export STACK_ROOT="$XDG_DATA_HOME/stack"
export WINEPREFIX="$XDG_DATA_HOME/wineprefixes/default"
export HISTFILE="$XDG_DATA_HOME/zsh/history"
export CUDA_CACHE_PATH="$XDG_CACHE_HOME/nv"
export CONAN_USER_HOME="$XDG_CONFIG_HOME/conan"
alias nvidia-settings=nvidia-settings --config="$XDG_CONFIG_HOME"/nvidia/settings
alias gpg2="gpg2 --homedir $XDG_DATA_HOME/gnupg"
export PASSWORD_STORE_DIR="$XDG_DATA_HOME/pass"

# disable dotnet telemetry
export DOTNET_CLI_TELEMETRY_OPTOUT=1

# java
export _JAVA_OPTIONS="-Djava.util.prefs.userRoot=$XDG_CONFIG_HOME/java -Dawt.useSystemAAFontSettings=on -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel"
export _JAVA_AWT_WM_NONREPARENTING=1

# secrets
[ -f "$HOME/.env" ] && . "$HOME/.env"