This commit is contained in:
Riz Ashraf
2026-04-07 00:13:07 +01:00
parent d33f6ebc05
commit 6101e4c230
14 changed files with 334 additions and 36 deletions
+5
View File
@@ -121,3 +121,8 @@ if command -v pyenv 1>/dev/null 2>&1; then
eval "$(pyenv init --path)" eval "$(pyenv init --path)"
fi fi
export PYENV_ROOT="$HOME/.pyenv" export PYENV_ROOT="$HOME/.pyenv"
export XDG_DATA_DIRS="/usr/local/share:/usr/share:${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
alias ghostty="ghostty 2>/dev/null"
. "$HOME/.local/bin/env"
. "$HOME/.cargo/env"
+74
View File
@@ -0,0 +1,74 @@
# This is the configuration file for Ghostty.
#
# This template file has been automatically created at the following
# path since Ghostty couldn't find any existing config files on your system:
#
# /home/riz/.config/ghostty/config
#
# The template does not set any default options, since Ghostty ships
# with sensible defaults for all options. Users should only need to set
# options that they want to change from the default.
#
# Run `ghostty +show-config --default --docs` to view a list of
# all available config options and their default values.
#
# Additionally, each config option is also explained in detail
# on Ghostty's website, at https://ghostty.org/docs/config.
#
# Ghostty can reload the configuration while running by using the menu
# options or the bound key (default: Command + Shift + comma on macOS and
# Control + Shift + comma on other platforms). Not all config options can be
# reloaded while running; some only apply to new windows and others may require
# a full restart to take effect.
# Config syntax crash course
# ==========================
# # The config file consists of simple key-value pairs,
# # separated by equals signs.
# font-family = Iosevka
# window-padding-x = 2
#
# # Spacing around the equals sign does not matter.
# # All of these are identical:
# key=value
# key= value
# key =value
# key = value
#
# # Any line beginning with a # is a comment. It's not possible to put
# # a comment after a config option, since it would be interpreted as a
# # part of the value. For example, this will have a value of "#123abc":
# background = #123abc
#
# # Empty values are used to reset config keys to default.
# key =
#
# # Some config options have unique syntaxes for their value,
# # which is explained in the docs for that config option.
# # Just for example:
# resize-overlay-duration = 4s 200ms
font-family = CaskaydiaCove Nerd Font
font-size = 10
theme = Atom
# --- Aesthetics ---
gtk-adwaita = true
window-decoration = client
window-step-resize = true
gtk-titlebar = true
background-opacity = 0.9
background-blur = 20
window-padding-x = 10
window-padding-y = 10
# --- Cursor ---
cursor-style = block
cursor-style-blink = true
# --- Integration & Usability ---
copy-on-select = true
confirm-close-surface = false
mouse-hide-while-typing = true
View File
+31
View File
@@ -0,0 +1,31 @@
scan_timeout = 1500
format = """
$os$shell$hostname$username$directory$git_branch$git_status$status
$character"""
[os]
disabled = false
format = "[$symbol](bold $STARSHIP_DEVICE_COLOR) "
[os.symbols]
Windows = "󰍲 "
Ubuntu = " "
[shell]
disabled = false
powershell_indicator = "pwsh"
bash_indicator = "bash"
zsh_indicator = "zsh"
style = "cyan bold"
[status]
disabled = false
format = "[$symbol]($style) "
symbol = " "
[character]
success_symbol = "[>](bold green)"
error_symbol = "[>](bold red)"
+1
View File
@@ -0,0 +1 @@
/mnt/c/Users/reazul.ashraf/AppData/Local/nvim
+1
View File
@@ -0,0 +1 @@
insecure
+31
View File
@@ -0,0 +1,31 @@
# ~/.profile: executed by the command interpreter for login shells.
# This file is not read by bash(1), if ~/.bash_profile or ~/.bash_login
# exists.
# see /usr/share/doc/bash/examples/startup-files for examples.
# the files are located in the bash-doc package.
# the default umask is set in /etc/profile; for setting the umask
# for ssh logins, install and configure the libpam-umask package.
#umask 022
# if running bash
if [ -n "$BASH_VERSION" ]; then
# include .bashrc if it exists
if [ -f "$HOME/.bashrc" ]; then
. "$HOME/.bashrc"
fi
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/.local/bin" ] ; then
PATH="$HOME/.local/bin:$PATH"
fi
. "$HOME/.local/bin/env"
. "$HOME/.cargo/env"
+49
View File
@@ -0,0 +1,49 @@
set-option -g prefix C-b
set -g mouse on
# General settings
set -g base-index 1 # start windows at 1
setw -g pane-base-index 1 # start panes at 1
set -g renumber-windows on # renumber windows when one is closed
setw -g mode-keys vi # use vim keys in copy mode
set-option -g status-position top
# Key bindings
bind r source-file ~/.tmux.conf \; display "Config Reloaded!"
bind-key "|" split-window -h -c "#{pane_current_path}"
bind-key C-| split-window -h -c "#{pane_current_path}"
bind-key "\\" split-window -v -c "#{pane_current_path}"
bind-key C-\\ split-window -v -c "#{pane_current_path}"
bind-key "-" split-window -fv -c "#{pane_current_path}"
bind-key C-- split-window -fv -c "#{pane_current_path}"
bind -r "<" swap-window -d -t -1
bind -r ">" swap-window -d -t +1
bind c new-window -c "#{pane_current_path}"
bind Space last-window
bind-key C-Space switch-client -l
# Pane navigation
bind h select-pane -L
bind j select-pane -D
bind k select-pane -U
bind l select-pane -R
# Pane resizing
bind -r C-j resize-pane -D 15
bind -r C-k resize-pane -U 15
bind -r C-h resize-pane -L 15
bind -r C-l resize-pane -R 15
# Plugins
set -g @plugin 'tmux-plugins/tpm'
set -g @plugin 'tmux-plugins/tmux-sensible'
set -g @plugin 'tmux-plugins/tmux-yank'
set -g @plugin 'erikw/tmux-powerline'
# Initialize TMUX plugin manager
run '~/.tmux/plugins/tpm/tpm'
+2
View File
@@ -0,0 +1,2 @@
check-certificate=off
+1
View File
@@ -0,0 +1 @@
export XDG_DATA_DIRS="/home/riz/.local/share/flatpak/exports/share:/var/lib/flatpak/exports/share:/home/hyperion/.local/share/flatpak/exports/share:$XDG_DATA_DIRS"
+1
View File
@@ -0,0 +1 @@
. "$HOME/.cargo/env"
+137 -36
View File
@@ -1,71 +1,149 @@
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then cd ~
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi # if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
# source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
# fi
# --- Homebrew Initialization (Primary) ---
eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"
VI_MODE_SET_CURSOR=true VI_MODE_SET_CURSOR=true
MODE_INDICATOR="%F{yellow}+%f" MODE_INDICATOR="%F{yellow}+%f"
bindkey -v bindkey -v
bindkey 'jk' vi-cmd-mode bindkey 'jk' vi-cmd-mode
# Visual feedback for vi mode
function zle-keymap-select {
if [[ $KEYMAP == vicmd ]]; then
echo -ne "\e[2 q" # Block
else
echo -ne "\e[6 q" # Beam
fi
}
zle -N zle-keymap-select
echo -ne "\e[6 q" # Start with beam
precmd() { echo -ne "\e[6 q" } # Reset to beam before prompt
bindkey '^[[A' history-substring-search-up bindkey '^[[A' history-substring-search-up
bindkey '^[[B' history-substring-search-down bindkey '^[[B' history-substring-search-down
# export manpath="/usr/local/man:$manpath"
export LC_CTYPE=en_GB.UTF-8 export LC_CTYPE=en_GB.UTF-8
export LC_ALL=en_GB.UTF-8 export LC_ALL=en_GB.UTF-8
export LANG=en_GB.UTF-8 export LANG=en_GB.UTF-8
export EDITOR='/usr/bin/nvim' export EDITOR='/usr/bin/nvim'
export MAVEN_OPTS='-Dstyle.color=always'
# to customize prompt, run `p10k configure` or edit ~/.p10k.zsh. # Options
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh setopt AUTO_CD
setopt CORRECT
setopt HIST_IGNORE_DUPS
setopt SHARE_HISTORY
# History
HISTSIZE=10000
SAVEHIST=10000
HISTFILE=~/.zsh_history
# # to customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
# [[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh
export PYENV_ROOT="$HOME/.pyenv" export PYENV_ROOT="$HOME/.pyenv"
export JDK8_HOME="$HOME/.jdks/jdk-1.8" export JDK8_HOME="$HOME/.jdks/jdk-1.8"
export JDK8_32_HOME="$HOME/.jdks/jdk-1.8-i586"
export JDK21_HOME="$HOME/.jdks/jdk-21" export JDK21_HOME="$HOME/.jdks/jdk-21"
export JAVA_HOME="$JDK21_HOME" export JDK25_HOME="$HOME/.jdks/jdk-25"
export JAVA_HOME="$JDK25_HOME"
export GROOVY_HOME="$HOME/devtools/groovy" export GROOVY_HOME="$HOME/devtools/groovy"
export M2_HOME="$HOME/devtools/maven" export M2_HOME="$HOME/devtools/maven"
export NODE_ENV=development export NODE_ENV=development
export GDK_BACKEND=x11
export PATH="$JAVA_HOME/bin:$M2_HOME/bin:$GROOVY_HOME/bin:$PYENV_ROOT/bin:$HOME/.npm-global/bin:/snap/bin:$HOME/.local/bin:/usr/local/bin:/usr/bin:/mnt/c/windows/system32" # PATH Configuration (Homebrew and Local Bin prioritized)
export PATH="$HOME/.local/bin:$PATH:$JAVA_HOME/bin:$M2_HOME/bin:$GROOVY_HOME/bin:$PYENV_ROOT/bin:$HOME/.npm-global/bin:/snap/bin"
typeset -g POWERLEVEL9K_INSTANT_PROMPT=off typeset -g POWERLEVEL9K_INSTANT_PROMPT=quiet
export ZSH="/home/riz/.oh-my-zsh" export ZSH="/home/riz/.oh-my-zsh"
ZSH_THEME="powerlevel10k/powerlevel10k" # ZSH_THEME="powerlevel10k/powerlevel10k"
plugins=(git vi-mode zsh-autosuggestions zsh-syntax-highlighting zsh-history-substring-search) plugins=(
#source /usr/share/doc/fzf/examples/key-bindings.zsh git
vi-mode
zsh-autosuggestions
zsh-history-substring-search
zsh-completions
fzf-tab
zsh-syntax-highlighting
)
export LIBGL_ALWAYS_INDIRECT=1 # fzf-tab settings
#export NNN_PLUG='f:finder;o:fzopen;p:mocplay;d:diffs;t:nmount;v:imgview' zstyle ':fzf-tab:complete:cd:*' fzf-preview 'eza -1 --color=always $realpath'
export NNN_ARCHIVE="\\.(7z|a|ace|alz|arc|arj|bz|bz2|cab|cpio|deb|gz|jar|lha|lz|lzh|lzma|lzo|rar|rpm|rz|t7z|tar|tbz|tbz2|tgz|tlz|txz|tZ|tzo|war|xpi|xz|Z|zip)$" zstyle ':fzf-tab:complete:*' fzf-flags --color=fg:1,fg+:2 --height=50%
zstyle ':completion:*:descriptions' format '[%d]'
zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS}
export DENO_INSTALL="/home/riz/.deno" source <(fzf --zsh)
export PATH="$DENO_INSTALL/bin:$PATH" export FZF_DEFAULT_OPTS="--height 40% --layout=reverse --border --preview 'bat --style=numbers --color=always --line-range :500 {}'"
export FZF_CTRL_T_OPTS="--preview 'bat --style=numbers --color=always --line-range :500 {}'"
export FZF_ALT_C_OPTS="--preview 'eza --tree --icons --color=always {} | head -200'"
source $ZSH/oh-my-zsh.sh # General Aliases
alias ai='gemini'
alias fcd='cd $(find * -type d | fzf)'
alias vi=nvim alias vi=nvim
alias jdk8home="export JAVA_HOME=$JDK8_HOME"
alias jdk21home="export JAVA_HOME=$JDK21_HOME"
alias g=git alias g=git
alias cat=batcat alias lg=lazygit
alias bat=batcat alias code="/mnt/c/Users/reazul.ashraf/AppData/Local/Programs/Microsoft\ VS\ Code/bin/code"
alias code="/mnt/c/Program\ Files/Microsoft\ VS\ Code/bin/code"
alias pbcopy='xclip -selection clipboard' alias pbcopy='xclip -selection clipboard'
alias pbpaste='xclip -selection clipboard -o' alias pbpaste='xclip -selection clipboard -o'
# --- Gold Standard Tool Mapping (Deduplicated & High Performance) ---
# Homebrew provides these; aliases ensure they are used consistently.
alias ls='eza --icons --group-directories-first'
alias la='eza --icons -la --group-directories-first --git'
alias tree='eza --tree --icons'
alias cat='bat'
alias find='fd'
alias ff='fd'
alias grep='rg'
alias sed='sd'
alias awk='choose'
alias ps='procs'
alias top='btm'
alias curl='xh'
alias zip='ouch'
alias tar='ouch'
alias diff='delta'
alias tldr='tealdeer'
# --------------------------------------------------------------------
# Navigation
alias ..='cd ..'
alias ...='cd ../..'
alias ....='cd ../../..'
alias .....='cd ../../../..'
# Functions
fcd() {
local dir
dir=$(fd -t d 2>/dev/null | fzf --preview 'eza --tree --icons --color=always {} | head -200') && cd "$dir"
}
alias jdk8home="export JAVA_HOME=$JDK8_HOME"
alias jdk8home32="export JAVA_HOME=$JDK8_32_HOME"
alias jdk21home="export JAVA_HOME=$JDK21_HOME"
alias jdk25home="export JAVA_HOME=$JDK25_HOME"
java() {
$JAVA_HOME/bin/java $@
}
gsquash() { gsquash() {
git reset --soft head~$(git rev-list --count head ^$1) git reset --soft head~$(git rev-list --count head ^$1)
echo "To complete then do, git push --force" echo "To complete then do, git push --force"
} }
# Development Helpers
dmvn() { dmvn() {
ws="/mnt/c/users/reazul.ashraf/workspace/uichannel-commission-bootstrap" ws="/mnt/c/users/reazul.ashraf/workspace/uichannel-commission-bootstrap"
echo "ws: $ws" id="$(docker run -t -d -u root:root -v /home/riz/.m2:/volume/.m2 -w $ws -v $ws:$ws:rw,z -v $ws@tmp:$ws@tmp:rw,z maven:3-openjdk-8-slim cat)"
id="$(docker run -t -d -u root:root -v /home/riz/.m2:/volume/.m2 -w $ws -v $ws:$ws:rw,z -v $ws@tmp:$ws@tmp:rw,z maven:3-openjdk-8-slim cat)"
echo "id: $id"
docker exec -ti $id ls -alp $ws docker exec -ti $id ls -alp $ws
docker kill $id docker kill $id
} }
@@ -74,14 +152,37 @@ sonarscan() {
MAVEN_OPTS="-Dsonar.branch.name=$(git branch --show-current)" JAVA_HOME=$JDK21_HOME mvn org.sonarsource.scanner.maven:sonar-maven-plugin:RELEASE:sonar -DskipTests MAVEN_OPTS="-Dsonar.branch.name=$(git branch --show-current)" JAVA_HOME=$JDK21_HOME mvn org.sonarsource.scanner.maven:sonar-maven-plugin:RELEASE:sonar -DskipTests
} }
source /snap/google-cloud-cli/current/completion.zsh.inc # Environment Initializations
#if command -v pyenv >/dev/null 2>&1; then
# eval "$(pyenv init -)"
#fi
eval "$(zoxide init --cmd z zsh)" eval "$(zoxide init --cmd z zsh)"
# Start in ~ # pnpm
cd ~ export PNPM_HOME="/home/riz/.local/share/pnpm"
case ":$PATH:" in
*":$PNPM_HOME:"*) ;;
*) export PATH="$PNPM_HOME:$PATH" ;;
esac
export GOOGLE_CLOUD_PROJECT=inse-r-and-d
export XDG_DATA_DIRS="/usr/local/share:/usr/share:${XDG_DATA_DIRS:-/usr/local/share:/usr/share}"
alias ghostty="ghostty 2>/dev/null"
alias gimp='GDK_BACKEND=x11 gimp'
export PYTHONWARNINGS="ignore:Your system is avx2 capable:RuntimeWarning"
# Cargo / Local Bin
[ -f "$HOME/.local/bin/env" ] && . "$HOME/.local/bin/env"
[ -f "$HOME/.cargo/env" ] && . "$HOME/.cargo/env"
# Autosuggestions color (make it readable)
export ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE='fg=cyan'
source $ZSH/oh-my-zsh.sh
export STARSHIP_DEVICE_COLOR="orange"
export STARSHIP_CONFIG=~/.config/starship_linux.toml
eval "$(starship init zsh)"
alias refresh-vpn='powershell.exe -ExecutionPolicy Bypass -File "C:\Users\reazul.ashraf\scripts\refresh_wsl_vpn.ps1"'
export GEMINI_CLI_HOME="/mnt/c/Users/reazul.ashraf"
+1
View File
@@ -0,0 +1 @@
/mnt/c/Users/reazul.ashraf/.ssh