Skip to content

Commit

Permalink
tidy up a lil bit
Browse files Browse the repository at this point in the history
  • Loading branch information
ihasdapie committed Dec 31, 2020
1 parent 9c21da5 commit 3d713e9
Show file tree
Hide file tree
Showing 14 changed files with 88 additions and 92 deletions.
2 changes: 2 additions & 0 deletions nvim/.config/nvim/init.vim
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,8 @@ endif

set statusline^=%{coc#status()}%{get(b:,'coc_current_function','')}

" rename with coc
nmap <leader>rn <Plug>(coc-rename)
" Accept Coc Completion on enter
inoremap <silent><expr> <C-enter> pumvisible() ? coc#_select_confirm() : "\ijj>u\<CR>\<c-r>=coc#on_enter()\<CR>"
Expand Down
68 changes: 68 additions & 0 deletions vivaldi/.config/combined_tab_and_address_bar.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
/*
One-line UI for Vivaldi 3.3+
Before using this style, please
* remove the search bar (or adjust space-from-left below)
* disable extension toggle button, profile switch button and menu bar
* adjust the current theme to apply accent color to window (not toolbar)
* make sure you've enabled the Alt key to open menu (keyboard settings)
Otherwise you'll have to modify the style further to suit your usage.
The style is meant to be used primarily in a maximized window,
on restored windows it may not look as good.
Inspired by https://forum.vivaldi.net/topic/13042/one-line-ui-help-wanted
*/
.win.normal .toolbar-mainbar {
left: unset;
right: unset;
}

:root {
--space-from-left: 36em; /* Main toolbar space - adjust according to your buttonset */
--space-from-right: 9em; /* Extension toolbar space - adjust according to your tab bar buttons (cloud, trashbin, ...) */
}

.toolbar-mainbar {
background: transparent !important; /* Prevent toolbar background overlapping with content (different height) */
position: fixed !important; /* Set a fixed position for toolbar (before tabs) */
top: -0.2em !important; /* Align it to the top edge */
padding-left: 0em !important; /* Align to the left (corner) */
z-index: 2 !important; /* Make sure autocomplete and overlays work */
}

.UrlBar-AddressField {
left: 2.5em !important; /* Keep space for toolbar buttons (adjust accordingly) */
top: 0.3em !important; /* Align address bar with the tabs */
width: 33em !important; /* Set a fixed width for address bar */
}

#tabs-container {
padding-left: var(--space-from-left) !important;
z-index: 2 !important; /* Make sure overlays work */
}

.toolbar-addressbar, .toolbar-mainbar, .toolbar-extensions {
background-color: var(--colorAccentBg); /* Append the same background color as window caption */
}

.toolbar-addressbar:after, .toolbar-mainbar:after, .toolbar-extensions:after, .toolbar-tabbar:after {
display: none !important; /* Remove a weird white line below the toolbar */
}

.toolbar-extensions {
position: fixed !important; /* Move the extension toolbar toggle position */
right: var(--space-from-right) !important; /* Position it next to trashbin/synced tabs */
}

/* The Vivaldi button does not work when moved, so the only way to keep UI nice is
to remove it. You can still access the menu by pressing Alt anywhere on the page.
If you still want a virtual button to click, try this customizable extension:
https://chrome.google.com/webstore/detail/mymenu/embakochaelgijbeolbbgnljfgpbeeoe
Keep in mind that it may display Chromium interfaces instead of Vivaldi's,
such as the history and bookmarks manager. */

.vivaldi .burger-icon {
display: none !important;
}
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed wallpapers/Pictures/Wallpapers/1975_01.jpg
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed wallpapers/Pictures/Wallpapers/Caffeine.jpg
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion zsh/.zsh_plugins.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
zsh-users/zsh-history-substring-search
romkatv/powerlevel10k
zsh-users/zsh-syntax-highlighting
zsh-users/zsh-completions
zsh-users/zsh-autosuggestions
108 changes: 17 additions & 91 deletions zsh/.zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi

# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh

# Plugins
antibody bundle < ~/.zsh_plugins.txt > ~/.zsh_plugins.sh
source ~/.zsh_plugins.sh
Expand All @@ -15,7 +18,7 @@ source ~/.zsh_plugins.sh
source /usr/share/autojump/autojump.zsh

## Options section
setopt correct # Auto correct mistakes
# setopt correct # Auto correct mistakes
setopt extendedglob # Extended globbing. Allows using regular expressions with *
# setopt nocaseglob # Case insensitive globbing
setopt rcexpandparam # Array expension with parameters
Expand Down Expand Up @@ -48,7 +51,6 @@ export EDITOR=/usr/bin/nvim
export VISUAL=/usr/bin/nvim
WORDCHARS=${WORDCHARS//\/[&.;]} # Don't consider certain characters part of the word


## Keybindings section
bindkey -e
bindkey '^R' history-incremental-search-backward
Expand Down Expand Up @@ -79,17 +81,9 @@ bindkey '^[[Z' undo # Shift+tab undo



autoload -U colors compinit zcalc
compinit -d
colors




# enable substitution for prompt
setopt prompt_subst


# Color man pages
export LESS_TERMCAP_mb=$'\E[01;32m'
export LESS_TERMCAP_md=$'\E[01;32m'
Expand All @@ -100,38 +94,11 @@ export LESS_TERMCAP_ue=$'\E[0m'
export LESS_TERMCAP_us=$'\E[01;36m'
export LESS=-r

## Plugins section: Enable fish style features
# Use syntax highlighting
source /usr/share/zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
# Use history substring search
source /usr/share/zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.zsh
# bind UP and DOWN arrow keys to history substring search
zmodload zsh/terminfo
bindkey "$terminfo[kcuu1]" history-substring-search-up
bindkey "$terminfo[kcud1]" history-substring-search-down
bindkey '^[[A' history-substring-search-up
bindkey '^[[B' history-substring-search-down

# Apply different settigns for different terminals
case $(basename "$(cat "/proc/$PPID/comm")") in
login)
RPROMPT="%{$fg[red]%} %(?..[%?])"
alias x='startx ~/.xinitrc' # Type name of desired desktop after x, xinitrc is configured for it
;;
*)
RPROMPT='$(git_prompt_string)'
# Use autosuggestion
source /usr/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=20
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE='fg=8'
;;
esac
ZSH_AUTOSUGGEST_BUFFER_MAX_SIZE=20
ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE='fg=8'
ZSH_AUTOSUGGEST_USE_ASYNC=1


# THEMING
ZSH_THEME=powerlevel10k/powerlevel10k

# I'm not 100% sure what this does right now or where it's from we'll roll with it!
function set-title-precmd() {
printf "\e]2;%s\a" "${PWD/#$HOME/~}"
}
Expand All @@ -144,11 +111,11 @@ autoload -Uz add-zsh-hook
add-zsh-hook precmd set-title-precmd
add-zsh-hook preexec set-title-preexec


##################
# My Aliases START
##################
alias vim="nvim"
alias vimnorc="nvim -u NONE"
alias ll="ls -all --color=auto"
alias ls="ls --color=auto"
alias spotify="spotify --force-device-scale-factor=2"
Expand Down Expand Up @@ -187,17 +154,14 @@ export PATH=$PATH:/home/ihasdapie/Applications/
export PATH=$PATH:/home/ihasdapie/.gem/ruby/2.7.0/bin/
export PATH=$PATH:/home/ihasdapie/.cargo/bin/


####### nnn

export NNN_PLUG="p:preview-tui;j:autojump;f:fzopen" # I should add more!
export NNN_FIFO=/tmp/nnn.fifo


#### FZF
source /usr/share/fzf/completion.zsh
source /usr/share/fzf/key-bindings.zsh

export FZF_DEFAULT_OPTS='--height 40% --layout=reverse --border'
export FZF_DEFAULT_COMMAND='fd --type f --follow --exclude .git'

Expand All @@ -214,23 +178,6 @@ _fzf_compgen_dir() {
fd --type d --hidden --follow --exclude ".git" . "$1"
}

# (EXPERIMENTAL) Advanced customization of fzf options via _fzf_comprun function
# - The first argument to the function is the name of the command.
# - You should make sure to pass the rest of the arguments to fzf.
_fzf_comprun() {
local command=$1
shift

case "$command" in
cd) fzf "$@" --preview 'tree -C {} | head -200' ;;
export|unset) fzf "$@" --preview "eval 'echo \$'{}" ;;
ssh) fzf "$@" --preview 'dig {}' ;;
*) fzf "$@" ;;
esac
}




# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
Expand All @@ -247,64 +194,43 @@ fi
unset __conda_setup
# <<< conda initialize <<<





#### DIRENV

eval "$(direnv hook zsh)"

### COMPLETIONS #########
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}" # Colored completion (different colors for dirs/files/etc)
# Speed up completions
zstyle ':completion:*' accept-exact '*(N)'
zstyle ':completion:*' use-cache on
zstyle ':completion:*' cache-path ~/.zsh/cache


# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh

# The following lines were added by compinstall

zstyle ':completion:*' auto-description 'specify: %d'
zstyle ':completion:*' completer _expand _complete _ignored _correct # _approximate
zstyle ':completion:*' completions 1
zstyle ':completion:*' completer _expand _complete _ignored _approximate
zstyle ':completion:*' expand prefix suffix
zstyle ':completion:*' format 'Completing %d'
zstyle ':completion:*' glob 1
zstyle ':completion:*' group-name ''
zstyle ':completion:*' list-colors ''
zstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s
zstyle ':completion:*' list-suffixes true
zstyle ':completion:*' matcher-list '' 'm:{[:lower:]}={[:upper:]} m:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|[._-]=** r:|=**' 'l:|=* r:|=*'
zstyle ':completion:*' menu select=5
zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]} m:{[:lower:][:upper:]}={[:upper:][:lower:]}' 'r:|[._-]=* r:|=*' '' 'l:|=* r:|=*'
zstyle ':completion:*' menu select=long
zstyle ':completion:*' select-prompt %SScrolling active: current selection at %p%s
zstyle ':completion:*' special-dirs true
zstyle ':completion:*' substitute 1
zstyle ':completion:*' squeeze-slashes true
zstyle :compinstall filename '/home/ihasdapie/.zshrc'

autoload -U colors compinit zcalc
colors # Put standard ANSI color codes in shell parameters for easy use.
compinit -d

# End of lines added by compinstall
### Kitty

# Completion for kitty
kitty + complete setup zsh | source /dev/stdin


# ROS
#
source /opt/ros/noetic/local_setup.zsh



# Startup commands
fortune | cowthink


# To customize prompt, run `p10k configure` or edit ~/.p10k.zsh.
[[ ! -f ~/.p10k.zsh ]] || source ~/.p10k.zsh

#
# zprof


Expand Down

0 comments on commit 3d713e9

Please sign in to comment.