Compare commits

...

52 Commits

Author SHA1 Message Date
254fc3062c fix (zshrc): WORDCHARS are a feature from zsh and should not require an export 2026-01-02 13:48:07 +01:00
1b8218f193 fix (zshrc): iterm2 requires an explicit typeset for the precmd_define_prompt 2025-11-21 10:27:14 +01:00
3343658120 docs (zshrc): fix comment about PROMPT_SUBST 2025-11-20 17:35:02 +01:00
7fc93e8351 fix (zshrc): add prompt setup to array of precmd_functions 2025-11-20 17:22:57 +01:00
3734e7f232 feat (vimrc): disable re-use of directory listings buffers 2025-11-10 14:39:59 +01:00
8b948cd1dc feat (vimrc): disable recently-visited directory history list 2025-11-10 14:36:34 +01:00
74308124dd chore (vimrc): use one style to assign values to options 2025-11-10 14:33:13 +01:00
d1f3baacce style (zshrc): only display the latest name of the folder 2025-05-05 13:59:01 +02:00
42b4bfc7ab refactor (gitconfig): add inital gitconfig and redefine alias gst 2025-04-29 09:09:23 +02:00
124d7bc71b new (zprofile): add automatic mechanism to start or reattach a tmux when connecting onto a remote server 2024-11-09 09:52:14 +01:00
447a7e8ecd new (tmux.conf): add minimal tmux config 2024-11-09 09:47:48 +01:00
518798a7e9 fix (zshrc): avoid looping over files for sourcing them
this seems to not just have performence improvements but also avoids assignments of variables
2024-04-22 21:52:45 +02:00
a55bf30b34 feat (git-commit-template): bring the used commit template back 2024-03-28 09:45:40 +01:00
39344142d1 feat (zshrc): make glog an alias for 'git log -p' 2024-03-28 09:43:07 +01:00
24a522627e feat (vimrc): let command-line completion operates in an enhanced mode 2024-02-10 17:15:10 +01:00
20fb0f29ae del (vimrc): remove setting for foldmethod (for now?) 2024-02-10 17:00:40 +01:00
7367aefa94 feat (zshrc): include what has been written up to the cursor position while 'browsing' through history 2023-11-23 20:40:12 +01:00
43f7302dc6 del (zshrc): remove alias tmux-ssh - tmux has not been used that way 2023-11-23 15:57:47 +01:00
e85cab5fb6 del (zshrc): make cp and mv less verbose 2023-11-20 15:56:19 +01:00
f77d66a848 feat (vimrc): use foldmethod indent - lines with equal indent form a fold 2023-11-17 20:16:27 +01:00
9353d37444 fix (README.md) moar new lines 2023-11-17 19:58:07 +01:00
ccd098a2e4 feat (vimrc): let vim set the title of the terminal 2023-11-17 18:58:39 +01:00
11fb372518 del (helper/weechat.autoadjust): used on remote session - not really a local config 2023-11-17 18:47:16 +01:00
a47723cf70 del (screenrc): use tabs from the default terminal 2023-11-17 18:45:42 +01:00
cbbfc67661 fix (zshrc): use a definition of PS1 that allow to be recognized while scrolling through a wall of text 2023-08-31 21:44:16 +02:00
5bf2f19f2b new (helper/weechat.autoadjust): add commands to enhance readability while using auto adjust setting for appearance 2023-08-22 16:37:11 +02:00
940ca1075d fix (screenrc): prepare screenrc status line to be easier to read when automatic adjustment of apperance is enabled 2023-08-09 21:04:12 +02:00
ce6d070859 fix (vimrc): if one enables automatic adjust of the appearance this leads to decreased readability 2023-08-09 20:58:35 +02:00
257eae5c3e fix (screenrc): avoid jump of an empty character when switch focused window 2023-07-29 16:34:27 +02:00
b079d328e7 feat (screenrc): add a simple "status line" 2023-07-29 16:13:28 +02:00
cf9971fed4 feat (zshrc): create or reuse a tmux session while using ssh 2023-07-29 15:32:55 +02:00
048de00fe7 fix (screenrc): increase value of scrollback. the default value is way to small 2023-07-29 15:24:17 +02:00
f38e6934a9 fix (zshrc): consider this dangerous - handle repositories with more care 2023-07-29 15:13:51 +02:00
9c000263ac feat (zshrc): instead of sourcing files individually just do so with files from a certain directory 2023-07-21 10:02:12 +02:00
319f0bb0a9 fix (zshrc): decrease KEYTIMEOUT for another key to be pressed 2023-07-20 20:15:37 +02:00
dcc3582255 fix (zshrc): the default sizes do not match my level of comfort for shell history 2023-07-20 20:10:58 +02:00
6ac8ce7a60 fix (zsh/term_title): remove case for xterm - screen is the main reason for this feature 2023-06-15 20:34:21 +02:00
50d50ff069 feat (zsh/term_title): add support for displaying terminal titles in a nice way 2023-06-15 20:30:08 +02:00
9713982a79 feat (zshrc): add case-insensitive, partial-word and then substring completion 2023-05-06 16:03:23 +02:00
f092a2a747 new (screenrc): add minimal possibly silent screenrc 2023-05-06 15:58:43 +02:00
78a89156ef chore (zshrc): do not show . and .. when displaying all files 2023-05-05 22:18:02 +02:00
555b2a2524 fix (zshrc): the command is not necessarily invoked at the top-level of a specific repository so the correct work-tree must be specified 2023-02-13 15:35:53 +01:00
fe962313b5 fix (zshrc): increae amount of repositories that can be pulled from 2023-02-11 10:12:14 +01:00
59c12ff606 new (zshrc): add alias to update all git repositories within the current directory 2023-02-11 09:53:03 +01:00
a91ffe96ef chore (zshrc): move exports to a more fitting spot in the config 2023-02-11 09:38:02 +01:00
8dd42a8c0d fix (zshrc): disable beeping on error events 2023-02-03 10:42:47 +01:00
b023b1a049 fix (vimrc): disable ringing the bell for all events 2023-02-03 10:37:32 +01:00
ea909b00d7 fix (vimrc): avoid creating swap files 2023-01-24 17:41:47 +01:00
9f05dc1a87 feat (vimrc): make tabs and trailing whitespaces visible 2023-01-20 20:46:05 +01:00
0d5af8da0f feat (vimrc): add highlight for search results 2023-01-20 20:37:43 +01:00
124a1f012c fix (vimrc): do not behave case sensitive while searching 2023-01-19 10:14:40 +01:00
fe24172e4c feat (zshrc): create handy alias to create a temporary directory and cd into it 2023-01-13 17:39:34 +01:00
8 changed files with 154 additions and 22 deletions

View File

@@ -1,3 +1,5 @@
HAI
BTW if you find something that does some mess - please let me know
KTHXBYE

24
git-commit-template Normal file
View File

@@ -0,0 +1,24 @@
# Type (<scope>): <subject>
# <body>
# <footer> (Keyword #issue)
# Type should be one of the following:
# * new (new component, file, ...)
# * del (delete component, file, ...)
# * feat (new feature)
# * fix (bug fix)
# * docs (changes to documentation)
# * style (formatting, missing semi colons, etc; no code change)
# * refactor (refactoring production code)
# * test (adding missing tests, refactoring tests; no production code change)
# * chore (updating grunt tasks etc; no production code change)
# Scope can be anything from file to component or empty (much changes)
# Subject should use imperative tone and say what you did.
# The body should go into detail about changes made.
# The footer should contain any JIRA (or other tool) issue references or actions.
# Keyword should be one of the following:
# * refs (refers to the given issue - does not fix or close it)
# * fixes (the given issue is fixed)
# * closes (the given issue is cloesd - might be new component, feature, ...)

7
gitconfig Normal file
View File

@@ -0,0 +1,7 @@
[user]
email = ...
name = eeemsi
[commit]
template = ~/.git/git-commit-template
[status]
short = true

6
tmux.conf Normal file
View File

@@ -0,0 +1,6 @@
# Update the status line every interval seconds
# A setting of zero disables redrawing at interval
set -g status-interval 0
# Display string to the right of the status line
set -g status-right "[\"#h\"]"

27
vimrc
View File

@@ -4,20 +4,41 @@ set nocompatible
" disable modeline for security
set nomodeline
" Adjust the default color groups for a dark or light background, respectively.
set background=dark
" let vim set the terminal title
set title
" avoid creating a swapfile
set noswapfile
" Highlight the screen line of the cursor
set cursorline
" Ignore case in search patterns and hihglight search results
set ignorecase hlsearch
" enable syntax highlighting
syntax on
" show tabs and trailing spaces
set list listchars=tab:>-,trail:-
" Suppress the banner in netrw
let g:netrw_banner=0
" Tree style listing in netrw
let g:netrw_liststyle = 3
let g:netrw_liststyle=3
" controls maximum quantity of entries in recently-visited directory history list
let g:netrw_dirhistmax=0
" never re-use directory listings buffers
let g:netrw_fastbrowse=0
" let command-line completion operates in an enhanced mode
set wildmenu
" disable ringing the bell for all events
set belloff=all
" Automatically remove trailing whitespace
autocmd! BufWrite * mark ' | silent! %s/\s\+$// | norm '

5
zprofile Normal file
View File

@@ -0,0 +1,5 @@
# Start or reattach a tmux session when a ssh connection is established
if [[ -n "${SSH_CONNECTION}" ]] && [[ "${TERM}" != "tmux-256color" ]]; then
tmux attach-session -d || tmux new-session
exit
fi

39
zsh/term_title Normal file
View File

@@ -0,0 +1,39 @@
set_termtitle() {
# escape '%' chars in "${1}", make nonprintables visible
local a="${(V)1//\%/\%\%}"
# Truncate command, and join lines.
a="${a//[$'\r'$'\n']/}"
[[ "${a}" = "zsh" ]] && { a="${(%)${:-%~}}" }
case "${TERM}" in
screen)
# plain xterm title
print -rn -- $'\e'"]2;${(%)${:-%m}}: ${a}"$'\a'
# screen title (in ^A")
print -rn -- $'\e'"k${a}"$'\e'$'\\'
# screen location
print -rn -- $'\e'"_${(%)${:-%m}}: ${a}"$'\e'$'\\'
;;
*)
;;
esac
}
my_prompt_precmd() {
set_termtitle "zsh"
}
my_prompt_preexec() {
set_termtitle "${1}"
}
typeset -ga precmd_functions
precmd_functions+=my_prompt_precmd
typeset -ga preexec_functions
preexec_functions+=my_prompt_preexec

66
zshrc
View File

@@ -3,12 +3,34 @@ if [[ ! -o interactive ]]; then
return
fi
# Timeout, in hundredths of seconds, when reading bound multi-character
# sequences (default is 0.4 sec.)
KEYTIMEOUT=1
# Search backward in the history for a line beginning with the current line up to the cursor
bindkey '^P' history-beginning-search-backward
# Search forward in the history for a line beginning with the current line up to the cursor
bindkey '^N' history-beginning-search-forward
# List of non-alphanumeric characters considered part of a word
WORDCHARS='*?_-.[]~=&;!#$%^(){}<>'
# Do not create a history file for less
export LESSHISTFILE=/dev/null
# Disable features like shell or pipe commands and more in less
export LESSSECURE=1
# completion system
autoload -U compinit; compinit
# retrieve information from version control systems
autoload -Uz vcs_info
# Case-insensitive, partial-word and then substring completion
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
# Offers menu when > selected elements appear
zstyle ':completion:*' menu select
@@ -18,6 +40,13 @@ zstyle ':vcs_info:*' enable git
# Specify how it should be formatted
zstyle ':vcs_info:*' formats '%b'
# Disable beeping on errors
unsetopt BEEP
# Define size for HISTSIZE and SAVEHIST also define path for HISTFILE
HISTSIZE=8192
SAVEHIST=8192
# Make cd push the old directory onto the directory stack
setopt AUTO_PUSHD
@@ -39,42 +68,41 @@ setopt HIST_IGNORE_SPACE
# When writing out the history file, older commands that duplicate newer ones are omitted
setopt HIST_SAVE_NO_DUPS
# Enable vcs_info
# parameter expansion, command substitution and arithmetic expansion are performed in prompts
setopt PROMPT_SUBST
# Comfortable aliases
alias ..='cd ..'
alias cp='cp -v'
alias l='ls -F -h'
alias la='ls -F -h -A'
alias view='vim -R'
# Comfortable git aliases
alias g='git'
alias gc='g commit'
alias gd='g diff'
alias glog='g log --graph --oneline'
alias gst='g status --short --branch'
alias l='ls -F -h'
alias la='ls -F -h -a'
alias mv='mv -v'
alias view='vim -R'
alias glog='g log -p'
alias gst='g status'
# Suppresses line numbers in less
alias less='less --line-numbers'
# Create temporary directory and cd to it
alias cdt='builtin cd "$(mktemp -d)"'
# Defines the prompt
precmd() {
precmd_define_prompt() {
vcs_info
# check if vcs_info_msg_0_ is empty to avoid an anoying space in the prompt
if [[ -z ${vcs_info_msg_0_} ]]; then
PS1='%B%F{green}%(3~|…/%2~|%~)%f %%%b '
PS1='%B%K{white}%F{black}%(3~|…/%1~|%~)%k%f %%%b '
else
PS1='%B%F{green}%(3~|…/%2~|%~)%f %F{cyan}${vcs_info_msg_0_}%f %%%b '
PS1='%B%K{white}%F{black}%(3~|…/%1~|%~)%k%f %F{green}${vcs_info_msg_0_}%f %%%b '
fi
}
typeset -ga precmd_functions
precmd_functions+=precmd_define_prompt
# List of non-alphanumeric characters considered part of a word
export WORDCHARS='*?_-.[]~=&;!#$%^(){}<>'
# Do not create a history file for less
export LESSHISTFILE=/dev/null
# Disable features like shell or pipe commands and more in less
export LESSSECURE=1
# include reading files from directory
source "${HOME}"/.zsh/*