Compare commits
9 Commits
f4f2db7de1
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
673db9e2cc
|
|||
|
4040adc7b2
|
|||
|
95deaa4fda
|
|||
|
d9c91162f5
|
|||
|
d64708126b
|
|||
|
110df8e08b
|
|||
|
4b4e3ac97c
|
|||
|
a3914f5474
|
|||
|
4a1a5abb96
|
1
.gitignore
vendored
1
.gitignore
vendored
@@ -6,3 +6,4 @@
|
||||
*.tmp
|
||||
*.tmp*
|
||||
*.vscdb
|
||||
.DS_Store
|
||||
|
||||
@@ -34,8 +34,8 @@ alias ll='ls -palFh --color=auto'
|
||||
alias mkdir='mkdir -pv'
|
||||
alias where='whereis' # zsh builtin
|
||||
|
||||
alias ps='ps auxf'
|
||||
alias psg='ps aux | grep -v grep | grep -i -e VSZ -e'
|
||||
# alias ps='ps auxf'
|
||||
# alias psg='ps aux | grep -v grep | grep -i -e VSZ -e'
|
||||
|
||||
alias wine='LANG=ru_RU.utf8 wine'
|
||||
alias wine64='LANG=ru_RU.utf8 wine64'
|
||||
|
||||
168
shell/.p10k.zsh
168
shell/.p10k.zsh
@@ -1,8 +1,8 @@
|
||||
# Generated by Powerlevel10k configuration wizard on 2026-03-26 at 00:08 +08.
|
||||
# Based on romkatv/powerlevel10k/config/p10k-rainbow.zsh, checksum 57633.
|
||||
# Wizard options: nerdfont-v3 + powerline, small icons, rainbow, unicode, 24h time,
|
||||
# round separators, round heads, flat tails, 2 lines, dotted, no frame, light-ornaments,
|
||||
# sparse, many icons, concise, instant_prompt=verbose.
|
||||
# Generated by Powerlevel10k configuration wizard on 2026-04-29 at 22:33 +08.
|
||||
# Based on romkatv/powerlevel10k/config/p10k-rainbow.zsh, checksum 24045.
|
||||
# Wizard options: nerdfont-complete + powerline, small icons, rainbow, unicode,
|
||||
# 24h time, round separators, round heads, round tails, 2 lines, solid, no frame,
|
||||
# darkest-ornaments, sparse, many icons, concise, instant_prompt=verbose.
|
||||
# Type `p10k configure` to generate another config.
|
||||
#
|
||||
# Config for Powerlevel10k with powerline prompt style with colorful background.
|
||||
@@ -27,7 +27,7 @@
|
||||
unset -m '(POWERLEVEL9K_*|DEFAULT_USER)~POWERLEVEL9K_GITSTATUS_DIR'
|
||||
|
||||
# Zsh >= 5.1 is required.
|
||||
[[ $ZSH_VERSION == (5.<1->*|<6->.*) ]] || return
|
||||
autoload -Uz is-at-least && is-at-least 5.1 || return
|
||||
|
||||
# The list of segments shown on the left. Fill it with the most important segments.
|
||||
typeset -g POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(
|
||||
@@ -53,7 +53,7 @@
|
||||
# asdf # asdf version manager (https://github.com/asdf-vm/asdf)
|
||||
virtualenv # python virtual environment (https://docs.python.org/3/library/venv.html)
|
||||
anaconda # conda environment (https://conda.io/)
|
||||
# pyenv # python environment (https://github.com/pyenv/pyenv)
|
||||
pyenv # python environment (https://github.com/pyenv/pyenv)
|
||||
goenv # go environment (https://github.com/syndbg/goenv)
|
||||
nodenv # node.js version from nodenv (https://github.com/nodenv/nodenv)
|
||||
nvm # node.js version from nvm (https://github.com/nvm-sh/nvm)
|
||||
@@ -102,15 +102,12 @@
|
||||
# disk_usage # disk usage
|
||||
# ram # free RAM
|
||||
# swap # used swap
|
||||
todo # todo items (https://github.com/todotxt/todo.txt-cli)
|
||||
# todo # todo items (https://github.com/todotxt/todo.txt-cli)
|
||||
# timewarrior # timewarrior tracking status (https://timewarrior.net/)
|
||||
# taskwarrior # taskwarrior task count (https://taskwarrior.org/)
|
||||
per_directory_history # Oh My Zsh per-directory-history local/global indicator
|
||||
# cpu_arch # CPU architecture
|
||||
time # current time
|
||||
# =========================[ Line #2 ]=========================
|
||||
# newline
|
||||
# status # exit code of the last command
|
||||
newline
|
||||
# ip # ip address and bandwidth usage for a specified network interface
|
||||
# public_ip # public IP address
|
||||
# proxy # system-wide http/https/ftp proxy
|
||||
@@ -120,7 +117,7 @@
|
||||
)
|
||||
|
||||
# Defines character set used by powerlevel10k. It's best to let `p10k configure` set it for you.
|
||||
typeset -g POWERLEVEL9K_MODE=nerdfont-v3
|
||||
typeset -g POWERLEVEL9K_MODE=nerdfont-complete
|
||||
# When set to `moderate`, some icons will have an extra space after them. This is meant to avoid
|
||||
# icon overlap when using non-monospace fonts. When set to `none`, spaces are not added.
|
||||
typeset -g POWERLEVEL9K_ICON_PADDING=none
|
||||
@@ -155,13 +152,13 @@
|
||||
# '─'. The last two make it easier to see the alignment between left and right prompt and to
|
||||
# separate prompt from command output. You might want to set POWERLEVEL9K_PROMPT_ADD_NEWLINE=false
|
||||
# for more compact prompt if using this option.
|
||||
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR='·'
|
||||
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR='─'
|
||||
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_BACKGROUND=
|
||||
typeset -g POWERLEVEL9K_MULTILINE_NEWLINE_PROMPT_GAP_BACKGROUND=
|
||||
if [[ $POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_CHAR != ' ' ]]; then
|
||||
# The color of the filler. You'll probably want to match the color of POWERLEVEL9K_MULTILINE
|
||||
# ornaments defined above.
|
||||
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=242
|
||||
typeset -g POWERLEVEL9K_MULTILINE_FIRST_PROMPT_GAP_FOREGROUND=238
|
||||
# Start filler from the edge of the screen if there are no left segments on the first line.
|
||||
typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_FIRST_SEGMENT_END_SYMBOL='%{%}'
|
||||
# End filler on the edge of the screen if there are no right segments on the first line.
|
||||
@@ -176,17 +173,14 @@
|
||||
typeset -g POWERLEVEL9K_LEFT_SEGMENT_SEPARATOR='\uE0B4'
|
||||
# Separator between different-color segments on the right.
|
||||
typeset -g POWERLEVEL9K_RIGHT_SEGMENT_SEPARATOR='\uE0B6'
|
||||
# To remove a separator between two segments, add "_joined" to the second segment name.
|
||||
# For example: POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(os_icon context_joined)
|
||||
|
||||
# The right end of left prompt.
|
||||
typeset -g POWERLEVEL9K_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL='\uE0B4'
|
||||
# The left end of right prompt.
|
||||
typeset -g POWERLEVEL9K_RIGHT_PROMPT_FIRST_SEGMENT_START_SYMBOL='\uE0B6'
|
||||
# The left end of left prompt.
|
||||
typeset -g POWERLEVEL9K_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL=''
|
||||
typeset -g POWERLEVEL9K_LEFT_PROMPT_FIRST_SEGMENT_START_SYMBOL='\uE0B6'
|
||||
# The right end of right prompt.
|
||||
typeset -g POWERLEVEL9K_RIGHT_PROMPT_LAST_SEGMENT_END_SYMBOL=''
|
||||
typeset -g POWERLEVEL9K_RIGHT_PROMPT_LAST_SEGMENT_END_SYMBOL='\uE0B4'
|
||||
# Left prompt terminator for lines without any segments.
|
||||
typeset -g POWERLEVEL9K_EMPTY_LINE_LEFT_PROMPT_LAST_SEGMENT_END_SYMBOL=
|
||||
|
||||
@@ -251,8 +245,7 @@
|
||||
.java-version
|
||||
.perl-version
|
||||
.php-version
|
||||
.tool-versions
|
||||
.mise.toml
|
||||
.tool-version
|
||||
.shorten_folder_marker
|
||||
.svn
|
||||
.terraform
|
||||
@@ -361,7 +354,7 @@
|
||||
# typeset -g POWERLEVEL9K_DIR_PREFIX='in '
|
||||
|
||||
#####################################[ vcs: git status ]######################################
|
||||
# Version control background colors.
|
||||
# Version control system colors.
|
||||
typeset -g POWERLEVEL9K_VCS_CLEAN_BACKGROUND=2
|
||||
typeset -g POWERLEVEL9K_VCS_MODIFIED_BACKGROUND=3
|
||||
typeset -g POWERLEVEL9K_VCS_UNTRACKED_BACKGROUND=2
|
||||
@@ -439,17 +432,11 @@
|
||||
res+=" ${modified}wip"
|
||||
fi
|
||||
|
||||
if (( VCS_STATUS_COMMITS_AHEAD || VCS_STATUS_COMMITS_BEHIND )); then
|
||||
# ⇣42 if behind the remote.
|
||||
(( VCS_STATUS_COMMITS_BEHIND )) && res+=" ${clean}⇣${VCS_STATUS_COMMITS_BEHIND}"
|
||||
# ⇡42 if ahead of the remote; no leading space if also behind the remote: ⇣42⇡42.
|
||||
(( VCS_STATUS_COMMITS_AHEAD && !VCS_STATUS_COMMITS_BEHIND )) && res+=" "
|
||||
(( VCS_STATUS_COMMITS_AHEAD )) && res+="${clean}⇡${VCS_STATUS_COMMITS_AHEAD}"
|
||||
elif [[ -n $VCS_STATUS_REMOTE_BRANCH ]]; then
|
||||
# Tip: Uncomment the next line to display '=' if up to date with the remote.
|
||||
# res+=" ${clean}="
|
||||
fi
|
||||
|
||||
# ⇠42 if behind the push remote.
|
||||
(( VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" ${clean}⇠${VCS_STATUS_PUSH_COMMITS_BEHIND}"
|
||||
(( VCS_STATUS_PUSH_COMMITS_AHEAD && !VCS_STATUS_PUSH_COMMITS_BEHIND )) && res+=" "
|
||||
@@ -519,21 +506,21 @@
|
||||
# Status on success. No content, just an icon. No need to show it if prompt_char is enabled as
|
||||
# it will signify success by turning green.
|
||||
typeset -g POWERLEVEL9K_STATUS_OK=true
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_VISUAL_IDENTIFIER_EXPANSION='✔'
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_VISUAL_IDENTIFIER_EXPANSION='0'
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_FOREGROUND=2
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_BACKGROUND=22
|
||||
|
||||
# Status when some part of a pipe command fails but the overall exit status is zero. It may look
|
||||
# like this: 1|0.
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE=true
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_VISUAL_IDENTIFIER_EXPANSION='✔'
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_VISUAL_IDENTIFIER_EXPANSION='0'
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_FOREGROUND=2
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_BACKGROUND=0
|
||||
typeset -g POWERLEVEL9K_STATUS_OK_PIPE_BACKGROUND=22
|
||||
|
||||
# Status when it's just an error code (e.g., '1'). No need to show it if prompt_char is enabled as
|
||||
# it will signify error by turning red.
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR=true
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_VISUAL_IDENTIFIER_EXPANSION='✘'
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_VISUAL_IDENTIFIER_EXPANSION='✕'
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_FOREGROUND=3
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_BACKGROUND=1
|
||||
|
||||
@@ -541,7 +528,7 @@
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL=true
|
||||
# Use terse signal names: "INT" instead of "SIGINT(2)".
|
||||
typeset -g POWERLEVEL9K_STATUS_VERBOSE_SIGNAME=false
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_VISUAL_IDENTIFIER_EXPANSION='✘'
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_VISUAL_IDENTIFIER_EXPANSION='✕'
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_FOREGROUND=3
|
||||
typeset -g POWERLEVEL9K_STATUS_ERROR_SIGNAL_BACKGROUND=1
|
||||
|
||||
@@ -758,13 +745,6 @@
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_RANGER_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
####################[ yazi: yazi shell (https://github.com/sxyazi/yazi) ]#####################
|
||||
# Yazi shell color.
|
||||
typeset -g POWERLEVEL9K_YAZI_FOREGROUND=3
|
||||
typeset -g POWERLEVEL9K_YAZI_BACKGROUND=0
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_YAZI_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
######################[ nnn: nnn shell (https://github.com/jarun/nnn) ]#######################
|
||||
# Nnn shell color.
|
||||
typeset -g POWERLEVEL9K_NNN_FOREGROUND=0
|
||||
@@ -772,13 +752,6 @@
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_NNN_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
######################[ lf: lf shell (https://github.com/gokcehan/lf) ]#######################
|
||||
# lf shell color.
|
||||
typeset -g POWERLEVEL9K_LF_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_LF_BACKGROUND=6
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_LF_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
##################[ xplr: xplr shell (https://github.com/sayanarijit/xplr) ]##################
|
||||
# xplr shell color.
|
||||
typeset -g POWERLEVEL9K_XPLR_FOREGROUND=0
|
||||
@@ -805,22 +778,12 @@
|
||||
typeset -g POWERLEVEL9K_NIX_SHELL_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_NIX_SHELL_BACKGROUND=4
|
||||
|
||||
# Display the icon of nix_shell if PATH contains a subdirectory of /nix/store.
|
||||
# typeset -g POWERLEVEL9K_NIX_SHELL_INFER_FROM_PATH=false
|
||||
|
||||
# Tip: If you want to see just the icon without "pure" and "impure", uncomment the next line.
|
||||
# typeset -g POWERLEVEL9K_NIX_SHELL_CONTENT_EXPANSION=
|
||||
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_NIX_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
##################[ chezmoi_shell: chezmoi shell (https://www.chezmoi.io/) ]##################
|
||||
# chezmoi shell color.
|
||||
typeset -g POWERLEVEL9K_CHEZMOI_SHELL_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_CHEZMOI_SHELL_BACKGROUND=4
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_CHEZMOI_SHELL_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
##################################[ disk_usage: disk usage ]##################################
|
||||
# Colors for different levels of disk usage.
|
||||
typeset -g POWERLEVEL9K_DISK_USAGE_NORMAL_FOREGROUND=3
|
||||
@@ -852,8 +815,6 @@
|
||||
# Text and color for insert vi mode.
|
||||
typeset -g POWERLEVEL9K_VI_INSERT_MODE_STRING=
|
||||
typeset -g POWERLEVEL9K_VI_MODE_INSERT_FOREGROUND=8
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_VI_MODE_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
######################################[ ram: free RAM ]#######################################
|
||||
# RAM color.
|
||||
@@ -944,33 +905,6 @@
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_TASKWARRIOR_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
######[ per_directory_history: Oh My Zsh per-directory-history local/global indicator ]#######
|
||||
# Color when using local/global history.
|
||||
typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_BACKGROUND=5
|
||||
typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_BACKGROUND=3
|
||||
|
||||
# Tip: Uncomment the next two lines to hide "local"/"global" text and leave just the icon.
|
||||
# typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_CONTENT_EXPANSION=''
|
||||
# typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_CONTENT_EXPANSION=''
|
||||
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_LOCAL_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
# typeset -g POWERLEVEL9K_PER_DIRECTORY_HISTORY_GLOBAL_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
################################[ cpu_arch: CPU architecture ]################################
|
||||
# CPU architecture color.
|
||||
typeset -g POWERLEVEL9K_CPU_ARCH_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_CPU_ARCH_BACKGROUND=3
|
||||
|
||||
# Hide the segment when on a specific CPU architecture.
|
||||
# typeset -g POWERLEVEL9K_CPU_ARCH_X86_64_CONTENT_EXPANSION=
|
||||
# typeset -g POWERLEVEL9K_CPU_ARCH_X86_64_VISUAL_IDENTIFIER_EXPANSION=
|
||||
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_CPU_ARCH_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
##################################[ context: user@hostname ]##################################
|
||||
# Context color when running with privileges.
|
||||
typeset -g POWERLEVEL9K_CONTEXT_ROOT_FOREGROUND=1
|
||||
@@ -1105,11 +1039,6 @@
|
||||
# Nvm color.
|
||||
typeset -g POWERLEVEL9K_NVM_FOREGROUND=0
|
||||
typeset -g POWERLEVEL9K_NVM_BACKGROUND=5
|
||||
# If set to false, hide node version if it's the same as default:
|
||||
# $(nvm version current) == $(nvm version default).
|
||||
typeset -g POWERLEVEL9K_NVM_PROMPT_ALWAYS_SHOW=false
|
||||
# If set to false, hide node version if it's equal to "system".
|
||||
typeset -g POWERLEVEL9K_NVM_SHOW_SYSTEM=true
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_NVM_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
@@ -1372,10 +1301,13 @@
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_TERRAFORM_VERSION_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
################[ terraform_version: It shows active terraform version (https://www.terraform.io) ]#################
|
||||
typeset -g POWERLEVEL9K_TERRAFORM_VERSION_SHOW_ON_COMMAND='terraform|tf'
|
||||
|
||||
#############[ kubecontext: current kubernetes context (https://kubernetes.io/) ]#############
|
||||
# Show kubecontext only when the command you are typing invokes one of these tools.
|
||||
# Tip: Remove the next line to always show kubecontext.
|
||||
typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|kubectx|oc|istioctl|kogito|k9s|helmfile|flux|fluxctl|stern|kubeseal|skaffold|kubent|kubecolor|cmctl|sparkctl'
|
||||
typeset -g POWERLEVEL9K_KUBECONTEXT_SHOW_ON_COMMAND='kubectl|helm|kubens|kubectx|oc|istioctl|kogito|k9s|helmfile|flux|fluxctl|stern|kubeseal|skaffold'
|
||||
|
||||
# Kubernetes context classes for the purpose of using different colors, icons and expansions with
|
||||
# different contexts.
|
||||
@@ -1464,7 +1396,7 @@
|
||||
#[ aws: aws profile (https://docs.aws.amazon.com/cli/latest/userguide/cli-configure-profiles.html) ]#
|
||||
# Show aws only when the command you are typing invokes one of these tools.
|
||||
# Tip: Remove the next line to always show aws.
|
||||
typeset -g POWERLEVEL9K_AWS_SHOW_ON_COMMAND='aws|awless|cdk|terraform|tofu|pulumi|terragrunt'
|
||||
typeset -g POWERLEVEL9K_AWS_SHOW_ON_COMMAND='aws|awless|terraform|pulumi|terragrunt'
|
||||
|
||||
# POWERLEVEL9K_AWS_CLASSES is an array with even number of elements. The first element
|
||||
# in each pair defines a pattern against which the current AWS profile gets matched.
|
||||
@@ -1513,42 +1445,12 @@
|
||||
##########[ azure: azure account name (https://docs.microsoft.com/en-us/cli/azure) ]##########
|
||||
# Show azure only when the command you are typing invokes one of these tools.
|
||||
# Tip: Remove the next line to always show azure.
|
||||
typeset -g POWERLEVEL9K_AZURE_SHOW_ON_COMMAND='az|terraform|tofu|pulumi|terragrunt'
|
||||
|
||||
# POWERLEVEL9K_AZURE_CLASSES is an array with even number of elements. The first element
|
||||
# in each pair defines a pattern against which the current azure account name gets matched.
|
||||
# More specifically, it's P9K_CONTENT prior to the application of context expansion (see below)
|
||||
# that gets matched. If you unset all POWERLEVEL9K_AZURE_*CONTENT_EXPANSION parameters,
|
||||
# you'll see this value in your prompt. The second element of each pair in
|
||||
# POWERLEVEL9K_AZURE_CLASSES defines the account class. Patterns are tried in order. The
|
||||
# first match wins.
|
||||
#
|
||||
# For example, given these settings:
|
||||
#
|
||||
# typeset -g POWERLEVEL9K_AZURE_CLASSES=(
|
||||
# '*prod*' PROD
|
||||
# '*test*' TEST
|
||||
# '*' OTHER)
|
||||
#
|
||||
# If your current azure account is "company_test", its class is TEST because "company_test"
|
||||
# doesn't match the pattern '*prod*' but does match '*test*'.
|
||||
#
|
||||
# You can define different colors, icons and content expansions for different classes:
|
||||
#
|
||||
# typeset -g POWERLEVEL9K_AZURE_TEST_FOREGROUND=2
|
||||
# typeset -g POWERLEVEL9K_AZURE_TEST_BACKGROUND=0
|
||||
# typeset -g POWERLEVEL9K_AZURE_TEST_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
# typeset -g POWERLEVEL9K_AZURE_TEST_CONTENT_EXPANSION='> ${P9K_CONTENT} <'
|
||||
typeset -g POWERLEVEL9K_AZURE_CLASSES=(
|
||||
# '*prod*' PROD # These values are examples that are unlikely
|
||||
# '*test*' TEST # to match your needs. Customize them as needed.
|
||||
'*' OTHER)
|
||||
|
||||
typeset -g POWERLEVEL9K_AZURE_SHOW_ON_COMMAND='az|terraform|pulumi|terragrunt'
|
||||
# Azure account name color.
|
||||
typeset -g POWERLEVEL9K_AZURE_OTHER_FOREGROUND=7
|
||||
typeset -g POWERLEVEL9K_AZURE_OTHER_BACKGROUND=4
|
||||
typeset -g POWERLEVEL9K_AZURE_FOREGROUND=7
|
||||
typeset -g POWERLEVEL9K_AZURE_BACKGROUND=4
|
||||
# Custom icon.
|
||||
# typeset -g POWERLEVEL9K_AZURE_OTHER_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
# typeset -g POWERLEVEL9K_AZURE_VISUAL_IDENTIFIER_EXPANSION='⭐'
|
||||
|
||||
##########[ gcloud: google cloud account and project (https://cloud.google.com/) ]###########
|
||||
# Show gcloud only when the command you are typing invokes one of these tools.
|
||||
@@ -1595,7 +1497,7 @@
|
||||
#[ google_app_cred: google application credentials (https://cloud.google.com/docs/authentication/production) ]#
|
||||
# Show google_app_cred only when the command you are typing invokes one of these tools.
|
||||
# Tip: Remove the next line to always show google_app_cred.
|
||||
typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_SHOW_ON_COMMAND='terraform|tofu|pulumi|terragrunt'
|
||||
typeset -g POWERLEVEL9K_GOOGLE_APP_CRED_SHOW_ON_COMMAND='terraform|pulumi|terragrunt'
|
||||
|
||||
# Google application credentials classes for the purpose of using different colors, icons and
|
||||
# expansions with different credentials.
|
||||
@@ -1674,7 +1576,7 @@
|
||||
typeset -g POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION=
|
||||
# Regular expression for the VPN network interface. Run `ifconfig` or `ip -4 a show` while on VPN
|
||||
# to see the name of the interface.
|
||||
typeset -g POWERLEVEL9K_VPN_IP_INTERFACE='(gpd|wg|(.*tun)|tailscale)[0-9]*|(zt.*)'
|
||||
typeset -g POWERLEVEL9K_VPN_IP_INTERFACE='(gpd|wg|(.*tun)|tailscale)[0-9]*'
|
||||
# If set to true, show one segment per matching network interface. If set to false, show only
|
||||
# one segment corresponding to the first matching network interface.
|
||||
# Tip: If you set it to true, you'll probably want to unset POWERLEVEL9K_VPN_IP_CONTENT_EXPANSION.
|
||||
@@ -1721,7 +1623,7 @@
|
||||
# Show battery in yellow when it's discharging.
|
||||
typeset -g POWERLEVEL9K_BATTERY_DISCONNECTED_FOREGROUND=3
|
||||
# Battery pictograms going from low to high level of charge.
|
||||
typeset -g POWERLEVEL9K_BATTERY_STAGES='\UF008E\UF007A\UF007B\UF007C\UF007D\UF007E\UF007F\UF0080\UF0081\UF0082\UF0079'
|
||||
typeset -g POWERLEVEL9K_BATTERY_STAGES='\uf58d\uf579\uf57a\uf57b\uf57c\uf57d\uf57e\uf57f\uf580\uf581\uf578'
|
||||
# Don't show the remaining time to charge/discharge.
|
||||
typeset -g POWERLEVEL9K_BATTERY_VERBOSE=false
|
||||
typeset -g POWERLEVEL9K_BATTERY_BACKGROUND=0
|
||||
@@ -1780,7 +1682,7 @@
|
||||
|
||||
# User-defined prompt segments may optionally provide an instant_prompt_* function. Its job
|
||||
# is to generate the prompt segment for display in instant prompt. See
|
||||
# https://github.com/romkatv/powerlevel10k#instant-prompt.
|
||||
# https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt.
|
||||
#
|
||||
# Powerlevel10k will call instant_prompt_* at the same time as the regular prompt_* function
|
||||
# and will record all `p10k segment` calls it makes. When displaying instant prompt, Powerlevel10k
|
||||
@@ -1817,7 +1719,7 @@
|
||||
# it incompatible with your zsh configuration files.
|
||||
# - quiet: Enable instant prompt and don't print warnings when detecting console output
|
||||
# during zsh initialization. Choose this if you've read and understood
|
||||
# https://github.com/romkatv/powerlevel10k#instant-prompt.
|
||||
# https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt.
|
||||
# - verbose: Enable instant prompt and print a warning when detecting console output during
|
||||
# zsh initialization. Choose this if you've never tried instant prompt, haven't
|
||||
# seen the warning, or if you are unsure what this all means.
|
||||
|
||||
@@ -16,13 +16,57 @@ fi
|
||||
|
||||
### AAA ##########################################
|
||||
|
||||
isMac() { uname -s | grep -q "Darwin"; }
|
||||
isLinux() { uname -s | grep -q "Linux"; }
|
||||
addPath() { [ -d "$1" ] && export PATH="$1:$PATH"; }
|
||||
safeSource() { [ -s "$1" ] && source "$1" 2>/dev/null || true; }
|
||||
|
||||
export EDITOR="nano"
|
||||
export NVM_DIR="$HOME/.nvm"
|
||||
export GOPATH="$HOME/.go"
|
||||
|
||||
### MacBook section
|
||||
if isMac; then
|
||||
# brew software
|
||||
if [ -d "/opt/homebrew/bin/" ]; then
|
||||
# brew itself
|
||||
eval "$(/opt/homebrew/bin/brew shellenv zsh)"
|
||||
addPath "/opt/homebrew/bin/"
|
||||
|
||||
# java
|
||||
export JAVA_HOME="/Library/Java/JavaVirtualMachines/openjdk-17.jdk/Contents/Home"
|
||||
|
||||
# nvm (not nvim!)
|
||||
safeSource "/opt/homebrew/opt/nvm/nvm.sh" # This loads nvm
|
||||
safeSource "/opt/homebrew/opt/nvm/etc/bash_completion.d/nvm" # This loads nvm bash_completion
|
||||
fi
|
||||
|
||||
# jbtoolbox
|
||||
addPath "$HOME/Library/Application Support/JetBrains/Toolbox/scripts"
|
||||
|
||||
# orbstack
|
||||
safeSource "$HOME/.orbstack/shell/init.zsh"
|
||||
fi
|
||||
### MacBook section end
|
||||
|
||||
### Ubuntu section
|
||||
if isLinux; then
|
||||
# golang
|
||||
export PATH="$PATH:/usr/local/go/bin"
|
||||
|
||||
# java
|
||||
# export JAVA_HOME="/usr/lib/jvm/java-21-openjdk-amd64"
|
||||
export JAVA_HOME="/usr/lib/jvm/java-17-openjdk-amd64"
|
||||
export PATH="$JAVA_HOME/bin/:$PATH"
|
||||
export PATH="$PATH:/opt/nvim/bin/"
|
||||
export PATH="$PATH:$HOME/.local/bin/"
|
||||
export PATH="$PATH:$HOME/.local/share/JetBrains/Toolbox/scripts/"
|
||||
|
||||
# nvim (not nvm!)
|
||||
[ -d "/opt/nvim/bin/" ] && export PATH="$PATH:/opt/nvim/bin/"
|
||||
|
||||
# rust cargo
|
||||
[ -f "$HOME/.cargo/env" ] && source "$HOME/.cargo/env"
|
||||
|
||||
# nvm (not nvim!)
|
||||
safeSource "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
safeSource "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||
|
||||
if hash composer >/dev/null; then
|
||||
composer_home=$(composer config -g home 2>/dev/null)
|
||||
@@ -34,23 +78,19 @@ fi
|
||||
# export PHPBREW_RC_ENABLE=1
|
||||
# [ -f $HOME/.phpbrew/bashrc ] && source $HOME/.phpbrew/bashrc
|
||||
|
||||
# golang
|
||||
export PATH="$PATH:/usr/local/go/bin"
|
||||
export GOPATH="$HOME/.go"
|
||||
|
||||
# rust cargo
|
||||
[ -f "$HOME/.cargo/env" ] && source "$HOME/.cargo/env"
|
||||
|
||||
# nvm
|
||||
export NVM_DIR="$HOME/.nvm"
|
||||
[ -s "$NVM_DIR/nvm.sh" ] && source "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
[ -s "$NVM_DIR/bash_completion" ] && source "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||
|
||||
# The next line updates PATH for Yandex Cloud CLI.
|
||||
[ -f "$HOME/yandex-cloud/path.bash.inc" ] && source "$HOME/yandex-cloud/path.bash.inc"
|
||||
safeSource "$HOME/yandex-cloud/path.bash.inc"
|
||||
|
||||
# The next line enables shell command completion for yc.
|
||||
[ -f "$HOME/yandex-cloud/completion.zsh.inc" ] && source "$HOME/yandex-cloud/completion.zsh.inc"
|
||||
safeSource "$HOME/yandex-cloud/completion.zsh.inc"
|
||||
|
||||
# misc
|
||||
[[ -f "$HOME/.profile.local" ]] && source "$HOME/.profile.local"
|
||||
# jbtoolbox
|
||||
if [ -d "$HOME/.local/share/JetBrains/Toolbox/scripts/" ]; then
|
||||
export PATH="$PATH:$HOME/.local/share/JetBrains/Toolbox/scripts/"
|
||||
fi
|
||||
fi
|
||||
### Ubuntu section end
|
||||
|
||||
addPath "$JAVA_HOME/bin/"
|
||||
|
||||
safeSource "$HOME/.profile.local"
|
||||
|
||||
40
shell/.zshrc
40
shell/.zshrc
@@ -6,13 +6,13 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
|
||||
fi
|
||||
|
||||
# If you come from bash you might have to change your $PATH.
|
||||
# export PATH=$HOME/bin:/usr/local/bin:$PATH
|
||||
# export PATH=$HOME/bin:$HOME/.local/bin:/usr/local/bin:$PATH
|
||||
|
||||
# Path to your oh-my-zsh installation.
|
||||
# Path to your Oh My Zsh installation.
|
||||
export ZSH="$HOME/.oh-my-zsh"
|
||||
|
||||
# Set name of the theme to load --- if set to "random", it will
|
||||
# load a random theme each time oh-my-zsh is loaded, in which case,
|
||||
# load a random theme each time Oh My Zsh is loaded, in which case,
|
||||
# to know which specific one was loaded, run: echo $RANDOM_THEME
|
||||
# See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes
|
||||
ZSH_THEME="powerlevel10k/powerlevel10k"
|
||||
@@ -77,13 +77,43 @@ ZSH_THEME="powerlevel10k/powerlevel10k"
|
||||
# Custom plugins may be added to $ZSH_CUSTOM/plugins/
|
||||
# Example format: plugins=(rails git textmate ruby lighthouse)
|
||||
# Add wisely, as too many plugins slow down shell startup.
|
||||
plugins=(git docker docker-compose composer zsh-autosuggestions zsh-syntax-highlighting laravel)
|
||||
plugins=(git docker docker-compose composer zsh-autosuggestions zsh-syntax-highlighting)
|
||||
|
||||
source $ZSH/oh-my-zsh.sh
|
||||
|
||||
# User configuration
|
||||
|
||||
# export MANPATH="/usr/local/man:$MANPATH"
|
||||
|
||||
# You may need to manually set your language environment
|
||||
# export LANG=en_US.UTF-8
|
||||
|
||||
# Preferred editor for local and remote sessions
|
||||
# if [[ -n $SSH_CONNECTION ]]; then
|
||||
# export EDITOR='vim'
|
||||
# else
|
||||
# export EDITOR='nvim'
|
||||
# fi
|
||||
|
||||
# Compilation flags
|
||||
# export ARCHFLAGS="-arch $(uname -m)"
|
||||
|
||||
# Set personal aliases, overriding those provided by Oh My Zsh libs,
|
||||
# plugins, and themes. Aliases can be placed here, though Oh My Zsh
|
||||
# users are encouraged to define aliases within a top-level file in
|
||||
# the $ZSH_CUSTOM folder, with .zsh extension. Examples:
|
||||
# - $ZSH_CUSTOM/aliases.zsh
|
||||
# - $ZSH_CUSTOM/macos.zsh
|
||||
# For a full list of active aliases, run `alias`.
|
||||
#
|
||||
# Example aliases
|
||||
# alias zshconfig="mate ~/.zshrc"
|
||||
# alias ohmyzsh="mate ~/.oh-my-zsh"
|
||||
|
||||
# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
|
||||
[[ -f ~/.p10k.zsh ]] && source ~/.p10k.zsh
|
||||
|
||||
### AAA
|
||||
|
||||
[[ -f ~/.bash_aliases ]] && source ~/.bash_aliases
|
||||
# [[ -f ~/.bashrc.local ]] && source ~/.bashrc.local
|
||||
[[ -f ~/.profile ]] && source ~/.profile
|
||||
|
||||
40
shell/README.md
Normal file
40
shell/README.md
Normal file
@@ -0,0 +1,40 @@
|
||||
## Краткое описание файлов
|
||||
|
||||
- `.bashrc` — bash для интерактивного non-login: история, prompt, aliases, completion.
|
||||
- `.zshrc` — zsh для интерактивного shell: плагины, тема, инициализация окружения.
|
||||
- `.profile` — общие login-настройки: PATH, переменные, platform-specific config.
|
||||
- `.bash_aliases` — набор пользовательских aliases для удобной навигации и команд.
|
||||
- `.p10k.zsh` — конфигурация темы Powerlevel10k.
|
||||
|
||||
## Иерархия загрузки
|
||||
|
||||
```
|
||||
ИНТЕРАКТИВНЫЙ ШЕЛЛ
|
||||
├── bash
|
||||
│ ├── .bashrc
|
||||
│ │ ├── .bash_aliases
|
||||
│ │ └── .profile
|
||||
│ └── .profile
|
||||
└── zsh
|
||||
├── .zshrc
|
||||
│ ├── .bash_aliases
|
||||
│ ├── .profile
|
||||
│ └── .p10k.zsh
|
||||
└── .profile
|
||||
```
|
||||
|
||||
## Загрузка по типам shell
|
||||
|
||||
```
|
||||
LOGIN SHELL
|
||||
├── bash: ~/.bash_profile → ~/.bash_login → ~/.profile
|
||||
└── zsh: ~/.zprofile → ~/.zshrc
|
||||
|
||||
INTERACTIVE NON-LOGIN
|
||||
├── bash: ~/.bashrc
|
||||
└── zsh: ~/.zshrc
|
||||
|
||||
NON-INTERACTIVE
|
||||
└── конфиги не загружаются автоматически
|
||||
```
|
||||
|
||||
@@ -1,27 +1,24 @@
|
||||
#!/usr/bin/env bash
|
||||
set -eo pipefail
|
||||
|
||||
# TODO not ready yet
|
||||
exit
|
||||
if [[ "$1" == "-h" || "$1" == "--help" ]]; then
|
||||
cat <<EOF
|
||||
Usage: $(basename "$0") [-h] [name]
|
||||
|
||||
if [ "$1" ]; then
|
||||
if [ "$1" = "-a" ]; then
|
||||
docker ps -aq \
|
||||
| xargs -n 1 docker inspect --format '{{.Name}}{{range .NetworkSettings.Networks}} {{.IPAddress}}{{end}}' \
|
||||
| sed -e 's#^/##' \
|
||||
| column -t
|
||||
elif [ "$1" = "-c" ]; then
|
||||
docker compose ps -q \
|
||||
| xargs -n 1 docker inspect --format '{{.Name}}{{range .NetworkSettings.Networks}} {{.IPAddress}}{{end}}' \
|
||||
| sed -e 's#^/##' \
|
||||
| column -t
|
||||
else
|
||||
docker inspect --format '{{range .NetworkSettings.Networks}}{{.IPAddress}}{{end}}' "$1"
|
||||
docker port "$1"
|
||||
Display IP addresses of Docker containers.
|
||||
|
||||
Options:
|
||||
-h, --help Show this help message
|
||||
|
||||
Arguments:
|
||||
name Container name to show specific IP
|
||||
|
||||
EOF
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [[ -n "$1" ]]; then
|
||||
docker ps -a --format "{{.ID}} {{.Names}} {{.Ports}}" --filter name="$1"
|
||||
else
|
||||
docker ps -q \
|
||||
| xargs -n 1 docker inspect --format '{{.Name}}{{range .NetworkSettings.Networks}} {{.IPAddress}}{{end}}' \
|
||||
| sed -e 's#^/##' \
|
||||
| column -t
|
||||
docker ps -a --format "{{.ID}} {{.Names}} {{.Ports}}"
|
||||
fi
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
|
||||
"workbench.colorTheme": "Atom One Dark",
|
||||
"workbench.preferredDarkColorTheme": "Atom One Dark",
|
||||
"workbench.iconTheme": "material-icon-theme",
|
||||
// "workbench.tree.indent": 10,
|
||||
"workbench.tree.renderIndentGuides": "always",
|
||||
"workbench.view.alwaysShowHeaderActions": true,
|
||||
@@ -138,7 +137,7 @@
|
||||
// terminal
|
||||
//----------------------------------------------------------------
|
||||
|
||||
"terminal.integrated.fontFamily": "JetBrainsMono Nerd Font, MesloLGS NF, Ubuntu Mono",
|
||||
"terminal.integrated.fontFamily": "\"JetBrainsMono Nerd Font\", \"MesloLGS NF\", Ubuntu Mono",
|
||||
"terminal.integrated.fontSize": 13,
|
||||
"terminal.integrated.cursorStyle": "line",
|
||||
"terminal.integrated.defaultProfile.linux": "zsh",
|
||||
@@ -322,5 +321,6 @@
|
||||
"git show"
|
||||
],
|
||||
"kilo-code.deniedCommands": [],
|
||||
"chat.disableAIFeatures": true
|
||||
"chat.disableAIFeatures": true,
|
||||
"terminal.external.osxExec": "zsh"
|
||||
}
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
include "%L"
|
||||
include "/usr/local/share/keyd/keyd.compose"
|
||||
|
||||
<Multi_key> <s> <h> <r> <u> <g> : "¯\\_(ツ)_/¯"
|
||||
<Multi_key> <Cyrillic_ha> <Cyrillic_ze> : "¯\\_(ツ)_/¯" # хз
|
||||
|
||||
Reference in New Issue
Block a user