From ab63f0d6a6978a6aec17948fb063336ef1b45918 Mon Sep 17 00:00:00 2001 From: Bartek Stalewski Date: Wed, 5 Feb 2020 18:34:50 +0100 Subject: [PATCH] deleting old configs --- legacy/abbr_pwd | 41 ------------------------------------- legacy/agnoster.zsh | 15 -------------- legacy/fish.init | 17 --------------- legacy/slimline.zsh | 14 ------------- legacy/slimline_k8s_ctx.zsh | 18 ---------------- legacy/slimline_k8s_ns.zsh | 18 ---------------- 6 files changed, 123 deletions(-) delete mode 100644 legacy/abbr_pwd delete mode 100644 legacy/agnoster.zsh delete mode 100644 legacy/fish.init delete mode 100644 legacy/slimline.zsh delete mode 100644 legacy/slimline_k8s_ctx.zsh delete mode 100644 legacy/slimline_k8s_ns.zsh diff --git a/legacy/abbr_pwd b/legacy/abbr_pwd deleted file mode 100644 index c5e3893..0000000 --- a/legacy/abbr_pwd +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/zsh - -function felix_pwd_abbr { - base_pwd=$PWD - tilda_notation=${base_pwd//$HOME/\~} - pwd_list=(${(s:/:)tilda_notation}) - list_len=${#pwd_list} - - if [[ $list_len -le 1 ]]; then - echo $tilda_notation - return - fi - - if [[ ${pwd_list[1]} != '~' ]]; then - formed_pwd='/' - fi - - firstchar=$(echo ${pwd_list[1]} | cut -c1) - if [[ $firstchar == '.' ]] ; then - firstchar=$(echo ${pwd_list[1]} | cut -c1,2) - fi - - formed_pwd=${formed_pwd}$firstchar - - for ((i=2; i <= $list_len; i++)) do - if [[ $i != ${list_len} ]]; then - - firstchar=$(echo ${pwd_list[$i]} | cut -c1) - if [[ $firstchar == '.' ]] ; then - firstchar=$(echo ${pwd_list[$i]} | cut -c1,2) - fi - - formed_pwd=${formed_pwd}/$firstchar - else - formed_pwd=${formed_pwd}/${pwd_list[$i]} - fi - done - - echo $formed_pwd - return -} diff --git a/legacy/agnoster.zsh b/legacy/agnoster.zsh deleted file mode 100644 index fb0b33e..0000000 --- a/legacy/agnoster.zsh +++ /dev/null @@ -1,15 +0,0 @@ -#git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh -#git clone https://github.com/zsh-users/zsh-autosuggestions.git ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions -#git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ~/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting -export ZSH=$HOME/.oh-my-zsh -ZSH_THEME="agnoster" -CASE_SENSITIVE="true" -ENABLE_CORRECTION="true" -plugins=(git kube-ps1 timer zsh-autosuggestions zsh-syntax-highlighting) -source $ZSH/oh-my-zsh.sh -export DEFAULT_USER=$LOGNAME -source ~/.dotfiles/zsh/abbr_pwd -prompt_dir() { - prompt_segment blue $CURRENT_FG $(felix_pwd_abbr) -} -PROMPT=$PROMPT'$(kube_ps1) ' diff --git a/legacy/fish.init b/legacy/fish.init deleted file mode 100644 index 4164b7c..0000000 --- a/legacy/fish.init +++ /dev/null @@ -1,17 +0,0 @@ -# cleaning -rm -rf ~/.config/fish ~/.local/share/fish ~/.config/omf ~/.local/share/omf -# installing omf -curl -L https://github.com/oh-my-fish/oh-my-fish/raw/master/bin/install > ~/install.omf -fish ~/install.omf --noninteractive -fish -c 'omf install bobthefish' -rm -rf ~/install.omf -# installing misc settings -mkdir -p ~/.config/fish/functions -echo 'function fish_greeting; end' > ~/.config/fish/functions/fish_greeting.fish -echo 'function fish_right_prompt; end' > ~/.config/fish/functions/fish_right_prompt.fish -touch ~/.fish.local -echo 'set -x VIRTUAL_ENV_DISABLE_PROMPT 1' > ~/.config/fish/config.fish -echo 'set -g theme_title_use_abbreviated_path no' >> ~/.config/fish/config.fish -echo 'set -g fish_prompt_pwd_dir_length 0' >> ~/.config/fish/config.fish -echo 'set -g theme_display_user yes' >> ~/.config/fish/config.fish -echo 'source ~/.fish.local' >> ~/.config/fish/config.fish diff --git a/legacy/slimline.zsh b/legacy/slimline.zsh deleted file mode 100644 index dc1bd07..0000000 --- a/legacy/slimline.zsh +++ /dev/null @@ -1,14 +0,0 @@ -#git clone --recursive https://github.com/mengelbrecht/slimline.git ~/.zsh/themes/slimline -source ~/.dotfiles/zsh/slimline_k8s_ctx.zsh -source ~/.dotfiles/zsh/slimline_k8s_ns.zsh - -SLIMLINE_RIGHT_PROMPT_SECTIONS="" -SLIMLINE_LEFT_PROMPT_SECTIONS="virtualenv aws_profile k8s_context k8s_namespace cwd git exit_status execution_time newline user_host_info symbol" -SLIMLINE_USER_HOST_INFO_FORMAT="%F{green}|user|%F{white}@%F{cyan}|host|%f" -SLIMLINE_USER_HOST_INFO_ROOT_FORMAT="%F{red}|user|%F{white}@%F{cyan}|host|%f" -SLIMLINE_VIRTUALENV_FORMAT="%F{cyan}\UE73C |basename|%f" -SLIMLINE_AWS_PROFILE_FORMAT="%F{yellow} \uF270 |profile|%f" -SLIMLINE_SYMBOL_WORKING_FORMAT="%F{red}➜%f" -SLIMLINE_SYMBOL_READY_FORMAT="%F{243}➜%f" -SLIMLINE_MAX_EXEC_TIME=2 -source ~/.zsh/themes/slimline/slimline.zsh diff --git a/legacy/slimline_k8s_ctx.zsh b/legacy/slimline_k8s_ctx.zsh deleted file mode 100644 index 8c16bd2..0000000 --- a/legacy/slimline_k8s_ctx.zsh +++ /dev/null @@ -1,18 +0,0 @@ -slimline::section::k8s_context::precmd() { - unset slimline_section_k8s_context_output -} - -slimline::section::k8s_context::async_task() { - kubectl config current-context -} - -slimline::section::k8s_context::async_task_complete() { - slimline_section_k8s_context_output=$2 -} - -slimline::section::k8s_context::render() { - [[ -z "${slimline_section_k8s_context_output}" ]] && return - - slimline::utils::expand "k8s_context" "%F{blue}\U2388 |output|%f" \ - "output" "${slimline_section_k8s_context_output}" -} diff --git a/legacy/slimline_k8s_ns.zsh b/legacy/slimline_k8s_ns.zsh deleted file mode 100644 index 1d7ebf3..0000000 --- a/legacy/slimline_k8s_ns.zsh +++ /dev/null @@ -1,18 +0,0 @@ -slimline::section::k8s_namespace::precmd() { - unset slimline_section_k8s_namespace_output -} - -slimline::section::k8s_namespace::async_task() { - kubectl config view --minify --output 'jsonpath={..namespace}' -} - -slimline::section::k8s_namespace::async_task_complete() { - slimline_section_k8s_namespace_output=$2 -} - -slimline::section::k8s_namespace::render() { - [[ -z "${slimline_section_k8s_namespace_output}" ]] && return - - slimline::utils::expand "k8s_namespace" "(%F{blue}|output|%f)" \ - "output" "${slimline_section_k8s_namespace_output}" -}