Introduce starship for kitch prompting
This commit is contained in:
parent
feac44c86e
commit
f4a015dc6f
1
.aliases
1
.aliases
@ -5,6 +5,7 @@ alias vim="nvim"
|
||||
alias pro="cd ~/Documents/Projects"
|
||||
alias doc="cd ~/Documents"
|
||||
|
||||
alias int="cd ~/Documents/cours/licence/L3/stage/pasteur/project/"
|
||||
|
||||
export templates_dir="~/Documents/Projects/templates"
|
||||
alias new.td='copier "$templates_dir/latex/td.template"'
|
||||
|
24
.loadenv.sh
24
.loadenv.sh
@ -2,8 +2,24 @@ export LUA_PATH='/usr/share/lua/5.4/?.lua;/usr/share/lua/5.4/?/init.lua;/usr/lib
|
||||
export LUA_CPATH='/usr/lib64/lua/5.4/?.so;/usr/lib64/lua/5.4/loadall.so;./?.so;/home/sortion/.luarocks/lib/lua/5.4/?.so;/usr/lib/lua/5.4/?.so'
|
||||
export PATH='/home/sortion/.luarocks/bin:/home/sortion/.julia/bin:/home/sortion/.nvm/versions/node/v17.9.1/bin:/home/sortion/.cargo/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/opt/quarto/quarto-1.2.335/bin:/home/sortion/.local/bin:/home/sortion/bin:/home/sortion/.antigen/bundles/robbyrussell/oh-my-zsh/lib:/home/sortion/.antigen/bundles/zsh-users/zsh-syntax-highlighting:/home/sortion/.antigen/bundles/robbyrussell/oh-my-zsh/plugins/git:/home/sortion/Documents/cours/tools/bin/'
|
||||
|
||||
if [[ -d ~/.texmf ]];
|
||||
then
|
||||
export TEXMFHOME=~/.texmf
|
||||
fi
|
||||
export TEXMFHOME=~/.texmf
|
||||
|
||||
# >>> conda initialize >>>
|
||||
# !! Contents within this block are managed by 'conda init' !!
|
||||
__conda_setup="$('/home/sortion/.local/share/mambaforge/bin/conda' 'shell.zsh' 'hook' 2> /dev/null)"
|
||||
if [ $? -eq 0 ]; then
|
||||
eval "$__conda_setup"
|
||||
else
|
||||
if [ -f "/home/sortion/.local/share/mambaforge/etc/profile.d/conda.sh" ]; then
|
||||
. "/home/sortion/.local/share/mambaforge/etc/profile.d/conda.sh"
|
||||
else
|
||||
export PATH="/home/sortion/.local/share/mambaforge/bin:$PATH"
|
||||
fi
|
||||
fi
|
||||
unset __conda_setup
|
||||
|
||||
if [ -f "/home/sortion/.local/share/mambaforge/etc/profile.d/mamba.sh" ]; then
|
||||
. "/home/sortion/.local/share/mambaforge/etc/profile.d/mamba.sh"
|
||||
fi
|
||||
# <<< conda initialize <<<
|
||||
|
||||
|
2
.zshrc
2
.zshrc
@ -14,6 +14,8 @@ antigen theme ys
|
||||
|
||||
antigen bundle zsh-users/zsh-syntax-highlighting
|
||||
|
||||
antigen bundle zsh-users/zsh-completions
|
||||
|
||||
antigen bundle git
|
||||
|
||||
antigen apply
|
||||
|
10
Makefile
10
Makefile
@ -3,9 +3,9 @@ all: pull install
|
||||
pull:
|
||||
git pull
|
||||
|
||||
install: antigen source dotmatrix
|
||||
install: antigen source fish
|
||||
|
||||
source:
|
||||
source: fishcfg
|
||||
cp ~/.dotfiles/.aliases ~/.aliases
|
||||
cp ~/.dotfiles/.zshrc ~/.zshrc
|
||||
cp ~/.dotfiles/.loadenv.sh ~/.loadenv.sh
|
||||
@ -13,7 +13,11 @@ source:
|
||||
cp ~/.dotfiles/.gitconfig ~/.gitconfig
|
||||
cp ~/.dotfiles/.latexmkrc ~/.latexmkrc
|
||||
|
||||
fishcfg:
|
||||
mkdir -p ~/.config/fish
|
||||
cp ./fish/config.fish ~/.config/fish/config.fish
|
||||
cp starship.toml ~/.config/starship.toml
|
||||
|
||||
antigen:
|
||||
git clone https://github.com/zsh-users/antigen.git
|
||||
|
||||
|
||||
|
38
fish/config.fish
Normal file
38
fish/config.fish
Normal file
@ -0,0 +1,38 @@
|
||||
function fish_greeting
|
||||
fortune
|
||||
end
|
||||
|
||||
function !!
|
||||
set var (history | head -n 1)
|
||||
if test $argv
|
||||
if test $argv = sudo #; or "any other command you want to prepend"
|
||||
eval $argv $var
|
||||
else
|
||||
eval $var $argv
|
||||
end
|
||||
else
|
||||
eval $var
|
||||
end
|
||||
end
|
||||
|
||||
set path_append "/home/sortion/.luarocks/bin:/home/sortion/.julia/bin:/home/sortion/.cargo/bin:/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin:/opt/quarto/quarto-1.2.335/bin:/home/sortion/.local/bin::/home/sortion/Documents/cours/tools/bin/"
|
||||
for path in (string split ":" $path_append)
|
||||
fish_add_path $path
|
||||
end
|
||||
|
||||
# >>> conda initialize >>>
|
||||
# !! Contents within this block are managed by 'conda init' !!
|
||||
if test -f /home/sortion/.local/share/mambaforge/bin/conda
|
||||
eval /home/sortion/.local/share/mambaforge/bin/conda "shell.fish" hook $argv | source
|
||||
end
|
||||
|
||||
if test -f "/home/sortion/.local/share/mambaforge/etc/fish/conf.d/mamba.fish"
|
||||
source "/home/sortion/.local/share/mambaforge/etc/fish/conf.d/mamba.fish"
|
||||
end
|
||||
# <<< conda initialize <<
|
||||
|
||||
function __conda_add_prompt
|
||||
end # Avoid conda prompt
|
||||
|
||||
|
||||
starship init fish | source
|
52
starship.toml
Normal file
52
starship.toml
Normal file
@ -0,0 +1,52 @@
|
||||
format = """
|
||||
$username\
|
||||
$hostname\
|
||||
$directory\
|
||||
$git_branch\
|
||||
$git_state\
|
||||
$git_status\
|
||||
$cmd_duration\
|
||||
$fill $conda$python\
|
||||
$line_break\
|
||||
$character"""
|
||||
|
||||
[directory]
|
||||
style = "bright-blue"
|
||||
|
||||
[character]
|
||||
success_symbol = "[❯](purple)"
|
||||
error_symbol = "[❯](red)"
|
||||
vimcmd_symbol = "[❮](green)"
|
||||
|
||||
[git_branch]
|
||||
format = "[$branch]($style)"
|
||||
style = "bright-black"
|
||||
|
||||
[git_status]
|
||||
format = "[[(*$conflicted$untracked$modified$staged$renamed$deleted)](218) ($ahead_behind$stashed)]($style)"
|
||||
style = "cyan"
|
||||
conflicted = ""
|
||||
untracked = ""
|
||||
modified = ""
|
||||
staged = ""
|
||||
renamed = ""
|
||||
deleted = ""
|
||||
stashed = "≡"
|
||||
|
||||
[git_state]
|
||||
format = '\([$state( $progress_current/$progress_total)]($style)\) '
|
||||
style = "bright-black"
|
||||
|
||||
[cmd_duration]
|
||||
format = "[$duration]($style) "
|
||||
style = "yellow"
|
||||
|
||||
[python]
|
||||
format = "[$symbol$virtualenv]($style) "
|
||||
style = "bright-black"
|
||||
|
||||
[conda]
|
||||
format = '[$symbol$environment](bright-green) '
|
||||
|
||||
[fill]
|
||||
symbol = " "
|
Loading…
Reference in New Issue
Block a user