remove existing files
This commit is contained in:
parent
be98cb961e
commit
7cff4d87ab
1302 changed files with 0 additions and 86122 deletions
|
@ -1,9 +0,0 @@
|
|||
{{- $graphical := promptString "graphical" -}}
|
||||
{{- $root := promptString "root" -}}
|
||||
{{- $pass := promptString "pass" -}}
|
||||
|
||||
[data]
|
||||
email = "mail@mzhang.io"
|
||||
graphical = {{ $graphical }}
|
||||
root = {{ $root }}
|
||||
pass = {{ $pass }}
|
|
@ -1,5 +1,2 @@
|
|||
LICENSE
|
||||
README.md
|
||||
|
||||
oh-my-zsh-master.tar.gz
|
||||
|
||||
|
|
142
dot_bashrc
142
dot_bashrc
|
@ -1,142 +0,0 @@
|
|||
#
|
||||
# ~/.bashrc
|
||||
#
|
||||
|
||||
[[ $- != *i* ]] && return
|
||||
|
||||
colors() {
|
||||
local fgc bgc vals seq0
|
||||
|
||||
printf "Color escapes are %s\n" '\e[${value};...;${value}m'
|
||||
printf "Values 30..37 are \e[33mforeground colors\e[m\n"
|
||||
printf "Values 40..47 are \e[43mbackground colors\e[m\n"
|
||||
printf "Value 1 gives a \e[1mbold-faced look\e[m\n\n"
|
||||
|
||||
# foreground colors
|
||||
for fgc in {30..37}; do
|
||||
# background colors
|
||||
for bgc in {40..47}; do
|
||||
fgc=${fgc#37} # white
|
||||
bgc=${bgc#40} # black
|
||||
|
||||
vals="${fgc:+$fgc;}${bgc}"
|
||||
vals=${vals%%;}
|
||||
|
||||
seq0="${vals:+\e[${vals}m}"
|
||||
printf " %-9s" "${seq0:-(default)}"
|
||||
printf " ${seq0}TEXT\e[m"
|
||||
printf " \e[${vals:+${vals+$vals;}}1mBOLD\e[m"
|
||||
done
|
||||
echo; echo
|
||||
done
|
||||
}
|
||||
|
||||
[ -r /usr/share/bash-completion/bash_completion ] && . /usr/share/bash-completion/bash_completion
|
||||
|
||||
# Change the window title of X terminals
|
||||
case ${TERM} in
|
||||
xterm*|rxvt*|Eterm*|aterm|kterm|gnome*|interix|konsole*)
|
||||
PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/\~}\007"'
|
||||
;;
|
||||
screen*)
|
||||
PROMPT_COMMAND='echo -ne "\033_${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/\~}\033\\"'
|
||||
;;
|
||||
esac
|
||||
|
||||
use_color=true
|
||||
|
||||
# Set colorful PS1 only on colorful terminals.
|
||||
# dircolors --print-database uses its own built-in database
|
||||
# instead of using /etc/DIR_COLORS. Try to use the external file
|
||||
# first to take advantage of user additions. Use internal bash
|
||||
# globbing instead of external grep binary.
|
||||
safe_term=${TERM//[^[:alnum:]]/?} # sanitize TERM
|
||||
match_lhs=""
|
||||
[[ -f ~/.dir_colors ]] && match_lhs="${match_lhs}$(<~/.dir_colors)"
|
||||
[[ -f /etc/DIR_COLORS ]] && match_lhs="${match_lhs}$(</etc/DIR_COLORS)"
|
||||
[[ -z ${match_lhs} ]] \
|
||||
&& type -P dircolors >/dev/null \
|
||||
&& match_lhs=$(dircolors --print-database)
|
||||
[[ $'\n'${match_lhs} == *$'\n'"TERM "${safe_term}* ]] && use_color=true
|
||||
|
||||
if ${use_color} ; then
|
||||
# Enable colors for ls, etc. Prefer ~/.dir_colors #64489
|
||||
if type -P dircolors >/dev/null ; then
|
||||
if [[ -f ~/.dir_colors ]] ; then
|
||||
eval $(dircolors -b ~/.dir_colors)
|
||||
elif [[ -f /etc/DIR_COLORS ]] ; then
|
||||
eval $(dircolors -b /etc/DIR_COLORS)
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
PS1='\[\033[01;31m\][\h\[\033[01;36m\] \W\[\033[01;31m\]]\$\[\033[00m\] '
|
||||
else
|
||||
PS1='\[\033[01;32m\][\u@\h\[\033[01;37m\] \W\[\033[01;32m\]]\$\[\033[00m\] '
|
||||
fi
|
||||
|
||||
alias ls='ls --color=auto'
|
||||
alias grep='grep --colour=auto'
|
||||
alias egrep='egrep --colour=auto'
|
||||
alias fgrep='fgrep --colour=auto'
|
||||
else
|
||||
if [[ ${EUID} == 0 ]] ; then
|
||||
# show root@ when we don't have colors
|
||||
PS1='\u@\h \W \$ '
|
||||
else
|
||||
PS1='\u@\h \w \$ '
|
||||
fi
|
||||
fi
|
||||
|
||||
unset use_color safe_term match_lhs sh
|
||||
|
||||
alias cp="cp -i" # confirm before overwriting something
|
||||
alias df='df -h' # human-readable sizes
|
||||
alias free='free -m' # show sizes in MB
|
||||
alias np='nano -w PKGBUILD'
|
||||
alias more=less
|
||||
|
||||
xhost +local:root > /dev/null 2>&1
|
||||
|
||||
complete -cf sudo
|
||||
|
||||
# Bash won't get SIGWINCH if another process is in the foreground.
|
||||
# Enable checkwinsize so that bash will check the terminal size when
|
||||
# it regains control. #65623
|
||||
# http://cnswww.cns.cwru.edu/~chet/bash/FAQ (E11)
|
||||
shopt -s checkwinsize
|
||||
|
||||
shopt -s expand_aliases
|
||||
|
||||
# export QT_SELECT=4
|
||||
|
||||
# Enable history appending instead of overwriting. #139609
|
||||
shopt -s histappend
|
||||
|
||||
#
|
||||
# # ex - archive extractor
|
||||
# # usage: ex <file>
|
||||
ex ()
|
||||
{
|
||||
if [ -f $1 ] ; then
|
||||
case $1 in
|
||||
*.tar.bz2) tar xjf $1 ;;
|
||||
*.tar.gz) tar xzf $1 ;;
|
||||
*.bz2) bunzip2 $1 ;;
|
||||
*.rar) unrar x $1 ;;
|
||||
*.gz) gunzip $1 ;;
|
||||
*.tar) tar xf $1 ;;
|
||||
*.tbz2) tar xjf $1 ;;
|
||||
*.tgz) tar xzf $1 ;;
|
||||
*.zip) unzip $1 ;;
|
||||
*.Z) uncompress $1;;
|
||||
*.7z) 7z x $1 ;;
|
||||
*) echo "'$1' cannot be extracted via ex()" ;;
|
||||
esac
|
||||
else
|
||||
echo "'$1' is not a valid file"
|
||||
fi
|
||||
}
|
||||
|
||||
source $HOME/.local/scripts/common/rc.sh
|
||||
source $HOME/.local/scripts/common/aliases.sh
|
|
@ -1,14 +0,0 @@
|
|||
#!/bin/bash
|
||||
# Should not be executable, only sourced by other scripts
|
||||
|
||||
command_exists() { command -v ${1} >/dev/null; }
|
||||
source_if_exists() { [ -f "$1" ] && source $1; }
|
||||
|
||||
append_path () {
|
||||
case ":$PATH:" in
|
||||
*:"$1":*)
|
||||
;;
|
||||
*)
|
||||
PATH="${PATH:+$PATH:}$1"
|
||||
esac
|
||||
}
|
|
@ -1,11 +0,0 @@
|
|||
[compose]
|
||||
editor=nvim
|
||||
|
||||
[triggers]
|
||||
new-email=exec notify-send "New email from %n" "%s"
|
||||
|
||||
[filters]
|
||||
subject,~^\[PATCH=awk -f /usr/share/aerc/filters/hldiff
|
||||
text/html=/usr/share/aerc/filters/html
|
||||
text/*=awk -f /usr/share/aerc/filters/plaintext
|
||||
|
|
@ -1,104 +0,0 @@
|
|||
# Binds are of the form <key sequence> = <command to run>
|
||||
# To use '=' in a key sequence, substitute it with "Eq": "<Ctrl+Eq>"
|
||||
# If you wish to bind #, you can wrap the key sequence in quotes: "#" = quit
|
||||
<C-p> = :prev-tab<Enter>
|
||||
<C-n> = :next-tab<Enter>
|
||||
<C-t> = :term<Enter>
|
||||
|
||||
[messages]
|
||||
q = :quit<Enter>
|
||||
|
||||
j = :next<Enter>
|
||||
<Down> = :next<Enter>
|
||||
<C-d> = :next 50%<Enter>
|
||||
<C-f> = :next 100%<Enter>
|
||||
<PgDn> = :next -s 100%<Enter>
|
||||
|
||||
k = :prev<Enter>
|
||||
<Up> = :prev<Enter>
|
||||
<C-u> = :prev 50%<Enter>
|
||||
<C-b> = :prev 100%<Enter>
|
||||
<PgUp> = :prev -s 100%<Enter>
|
||||
g = :select 0<Enter>
|
||||
G = :select -1<Enter>
|
||||
|
||||
J = :next-folder<Enter>
|
||||
K = :prev-folder<Enter>
|
||||
|
||||
v = :mark -t<Enter>
|
||||
V = :mark -v<Enter>
|
||||
|
||||
<Enter> = :view<Enter>
|
||||
d = :prompt 'Really delete this message?' 'delete-message'<Enter>
|
||||
D = :delete<Enter>
|
||||
A = :archive flat<Enter>
|
||||
|
||||
C = :compose<Enter>
|
||||
|
||||
rr = :reply -a<Enter>
|
||||
rq = :reply -aq<Enter>
|
||||
Rr = :reply<Enter>
|
||||
Rq = :reply -q<Enter>
|
||||
|
||||
c = :cf<space>
|
||||
$ = :term<space>
|
||||
! = :term<space>
|
||||
| = :pipe<space>
|
||||
|
||||
/ = :search<space>
|
||||
\ = :filter<space>
|
||||
n = :next-result<Enter>
|
||||
N = :prev-result<Enter>
|
||||
|
||||
[view]
|
||||
q = :close<Enter>
|
||||
| = :pipe<space>
|
||||
D = :delete<Enter>
|
||||
S = :save<space>
|
||||
A = :archive flat<Enter>
|
||||
|
||||
f = :forward<Enter>
|
||||
rr = :reply -a<Enter>
|
||||
rq = :reply -aq<Enter>
|
||||
Rr = :reply<Enter>
|
||||
Rq = :reply -q<Enter>
|
||||
|
||||
H = :toggle-headers<Enter>
|
||||
<C-k> = :prev-part<Enter>
|
||||
<C-j> = :next-part<Enter>
|
||||
J = :next<Enter>
|
||||
K = :prev<Enter>
|
||||
|
||||
[compose]
|
||||
# Keybindings used when the embedded terminal is not selected in the compose
|
||||
# view
|
||||
$ex = <C-x>
|
||||
<C-k> = :prev-field<Enter>
|
||||
<C-j> = :next-field<Enter>
|
||||
<tab> = :next-field<Enter>
|
||||
|
||||
[compose::editor]
|
||||
# Keybindings used when the embedded terminal is selected in the compose view
|
||||
$noinherit = true
|
||||
$ex = <C-x>
|
||||
<C-k> = :prev-field<Enter>
|
||||
<C-j> = :next-field<Enter>
|
||||
<C-n> = :next-tab<Enter>
|
||||
<C-p> = :prev-tab<Enter>
|
||||
|
||||
[compose::review]
|
||||
# Keybindings used when reviewing a message to be sent
|
||||
y = :send<Enter>
|
||||
n = :abort<Enter>
|
||||
p = :postpone<Enter>
|
||||
q = :abort<Enter>
|
||||
e = :edit<Enter>
|
||||
a = :attach<space>
|
||||
|
||||
[terminal]
|
||||
$noinherit = true
|
||||
$ex = <C-x>
|
||||
|
||||
<C-p> = :prev-tab<Enter>
|
||||
<C-n> = :next-tab<Enter>
|
||||
|
|
@ -1,812 +0,0 @@
|
|||
# Configuration for Alacritty, the GPU enhanced terminal emulator.
|
||||
|
||||
# Import additional configuration files
|
||||
#
|
||||
# Imports are loaded in order, skipping all missing files, with the importing
|
||||
# file being loaded last. If a field is already present in a previous import, it
|
||||
# will be replaced.
|
||||
#
|
||||
# All imports must either be absolute paths starting with `/`, or paths relative
|
||||
# to the user's home directory starting with `~/`.
|
||||
#import:
|
||||
# - /path/to/alacritty.yml
|
||||
|
||||
# Any items in the `env` entry below will be added as
|
||||
# environment variables. Some entries may override variables
|
||||
# set by alacritty itself.
|
||||
env:
|
||||
# TERM variable
|
||||
#
|
||||
# This value is used to set the `$TERM` environment variable for
|
||||
# each instance of Alacritty. If it is not present, alacritty will
|
||||
# check the local terminfo database and use `alacritty` if it is
|
||||
# available, otherwise `xterm-256color` is used.
|
||||
TERM: alacritty
|
||||
|
||||
#window:
|
||||
# Window dimensions (changes require restart)
|
||||
#
|
||||
# Number of lines/columns (not pixels) in the terminal. The number of columns
|
||||
# must be at least `2`, while using a value of `0` for columns and lines will
|
||||
# fall back to the window manager's recommended size.
|
||||
#dimensions:
|
||||
# columns: 0
|
||||
# lines: 0
|
||||
|
||||
# Window position (changes require restart)
|
||||
#
|
||||
# Specified in number of pixels.
|
||||
# If the position is not set, the window manager will handle the placement.
|
||||
#position:
|
||||
# x: 0
|
||||
# y: 0
|
||||
|
||||
# Window padding (changes require restart)
|
||||
#
|
||||
# Blank space added around the window in pixels. This padding is scaled
|
||||
# by DPI and the specified value is always added at both opposing sides.
|
||||
#padding:
|
||||
# x: 0
|
||||
# y: 0
|
||||
|
||||
# Spread additional padding evenly around the terminal content.
|
||||
#dynamic_padding: false
|
||||
|
||||
# Window decorations
|
||||
#
|
||||
# Values for `decorations`:
|
||||
# - full: Borders and title bar
|
||||
# - none: Neither borders nor title bar
|
||||
#
|
||||
# Values for `decorations` (macOS only):
|
||||
# - transparent: Title bar, transparent background and title bar buttons
|
||||
# - buttonless: Title bar, transparent background and no title bar buttons
|
||||
#decorations: full
|
||||
|
||||
# Startup Mode (changes require restart)
|
||||
#
|
||||
# Values for `startup_mode`:
|
||||
# - Windowed
|
||||
# - Maximized
|
||||
# - Fullscreen
|
||||
#
|
||||
# Values for `startup_mode` (macOS only):
|
||||
# - SimpleFullscreen
|
||||
#startup_mode: Windowed
|
||||
|
||||
# Window title
|
||||
#title: Alacritty
|
||||
|
||||
# Allow terminal applications to change Alacritty's window title.
|
||||
#dynamic_title: true
|
||||
|
||||
# Window class (Linux/BSD only):
|
||||
#class:
|
||||
# Application instance name
|
||||
#instance: Alacritty
|
||||
# General application class
|
||||
#general: Alacritty
|
||||
|
||||
# GTK theme variant (Linux/BSD only)
|
||||
#
|
||||
# Override the variant of the GTK theme. Commonly supported values are `dark`
|
||||
# and `light`. Set this to `None` to use the default theme variant.
|
||||
#gtk_theme_variant: None
|
||||
|
||||
#scrolling:
|
||||
# Maximum number of lines in the scrollback buffer.
|
||||
# Specifying '0' will disable scrolling.
|
||||
#history: 10000
|
||||
|
||||
# Scrolling distance multiplier.
|
||||
#multiplier: 3
|
||||
|
||||
# Font configuration
|
||||
font:
|
||||
# Normal (roman) font face
|
||||
normal:
|
||||
# Font family
|
||||
#
|
||||
# Default:
|
||||
# - (macOS) Menlo
|
||||
# - (Linux/BSD) monospace
|
||||
# - (Windows) Consolas
|
||||
family: "PragmataPro Mono Liga"
|
||||
|
||||
# The `style` can be specified to pick a specific face.
|
||||
#style: Regular
|
||||
|
||||
# Bold font face
|
||||
#bold:
|
||||
# Font family
|
||||
#
|
||||
# If the bold family is not specified, it will fall back to the
|
||||
# value specified for the normal font.
|
||||
#family: monospace
|
||||
|
||||
# The `style` can be specified to pick a specific face.
|
||||
#style: Bold
|
||||
|
||||
# Italic font face
|
||||
#italic:
|
||||
# Font family
|
||||
#
|
||||
# If the italic family is not specified, it will fall back to the
|
||||
# value specified for the normal font.
|
||||
#family: monospace
|
||||
|
||||
# The `style` can be specified to pick a specific face.
|
||||
#style: Italic
|
||||
|
||||
# Bold italic font face
|
||||
#bold_italic:
|
||||
# Font family
|
||||
#
|
||||
# If the bold italic family is not specified, it will fall back to the
|
||||
# value specified for the normal font.
|
||||
#family: monospace
|
||||
|
||||
# The `style` can be specified to pick a specific face.
|
||||
#style: Bold Italic
|
||||
|
||||
# Point size
|
||||
size: 12.0
|
||||
|
||||
# Offset is the extra space around each character. `offset.y` can be thought
|
||||
# of as modifying the line spacing, and `offset.x` as modifying the letter
|
||||
# spacing.
|
||||
#offset:
|
||||
# x: 0
|
||||
# y: 0
|
||||
|
||||
# Glyph offset determines the locations of the glyphs within their cells with
|
||||
# the default being at the bottom. Increasing `x` moves the glyph to the
|
||||
# right, increasing `y` moves the glyph upward.
|
||||
#glyph_offset:
|
||||
# x: 0
|
||||
# y: 0
|
||||
|
||||
# Thin stroke font rendering (macOS only)
|
||||
#
|
||||
# Thin strokes are suitable for retina displays, but for non-retina screens
|
||||
# it is recommended to set `use_thin_strokes` to `false`.
|
||||
#use_thin_strokes: true
|
||||
|
||||
# If `true`, bold text is drawn using the bright color variants.
|
||||
#draw_bold_text_with_bright_colors: false
|
||||
|
||||
# Colors (Tomorrow Night)
|
||||
#colors:
|
||||
# Default colors
|
||||
#primary:
|
||||
# background: '#1d1f21'
|
||||
# foreground: '#c5c8c6'
|
||||
|
||||
# Bright and dim foreground colors
|
||||
#
|
||||
# The dimmed foreground color is calculated automatically if it is not
|
||||
# present. If the bright foreground color is not set, or
|
||||
# `draw_bold_text_with_bright_colors` is `false`, the normal foreground
|
||||
# color will be used.
|
||||
#dim_foreground: '#828482'
|
||||
#bright_foreground: '#eaeaea'
|
||||
|
||||
# Cursor colors
|
||||
#
|
||||
# Colors which should be used to draw the terminal cursor.
|
||||
#
|
||||
# Allowed values are CellForeground and CellBackground, which reference the
|
||||
# affected cell, or hexadecimal colors like #ff00ff.
|
||||
#cursor:
|
||||
# text: CellBackground
|
||||
# cursor: CellForeground
|
||||
|
||||
# Vi mode cursor colors
|
||||
#
|
||||
# Colors for the cursor when the vi mode is active.
|
||||
#
|
||||
# Allowed values are CellForeground and CellBackground, which reference the
|
||||
# affected cell, or hexadecimal colors like #ff00ff.
|
||||
#vi_mode_cursor:
|
||||
# text: CellBackground
|
||||
# cursor: CellForeground
|
||||
|
||||
# Search colors
|
||||
#
|
||||
# Colors used for the search bar and match highlighting.
|
||||
#search:
|
||||
# Allowed values are CellForeground and CellBackground, which reference the
|
||||
# affected cell, or hexadecimal colors like #ff00ff.
|
||||
#matches:
|
||||
# foreground: '#000000'
|
||||
# background: '#ffffff'
|
||||
#focused_match:
|
||||
# foreground: CellBackground
|
||||
# background: CellForeground
|
||||
|
||||
#bar:
|
||||
# background: '#c5c8c6'
|
||||
# foreground: '#1d1f21'
|
||||
|
||||
# Line indicator
|
||||
#
|
||||
# Color used for the indicator displaying the position in history during
|
||||
# search and vi mode.
|
||||
#
|
||||
# By default, these will use the opposing primary color.
|
||||
#line_indicator:
|
||||
# foreground: None
|
||||
# background: None
|
||||
|
||||
# Selection colors
|
||||
#
|
||||
# Colors which should be used to draw the selection area.
|
||||
#
|
||||
# Allowed values are CellForeground and CellBackground, which reference the
|
||||
# affected cell, or hexadecimal colors like #ff00ff.
|
||||
#selection:
|
||||
# text: CellBackground
|
||||
# background: CellForeground
|
||||
|
||||
# Normal colors
|
||||
#normal:
|
||||
# black: '#1d1f21'
|
||||
# red: '#cc6666'
|
||||
# green: '#b5bd68'
|
||||
# yellow: '#f0c674'
|
||||
# blue: '#81a2be'
|
||||
# magenta: '#b294bb'
|
||||
# cyan: '#8abeb7'
|
||||
# white: '#c5c8c6'
|
||||
|
||||
# Bright colors
|
||||
#bright:
|
||||
# black: '#666666'
|
||||
# red: '#d54e53'
|
||||
# green: '#b9ca4a'
|
||||
# yellow: '#e7c547'
|
||||
# blue: '#7aa6da'
|
||||
# magenta: '#c397d8'
|
||||
# cyan: '#70c0b1'
|
||||
# white: '#eaeaea'
|
||||
|
||||
# Dim colors
|
||||
#
|
||||
# If the dim colors are not set, they will be calculated automatically based
|
||||
# on the `normal` colors.
|
||||
#dim:
|
||||
# black: '#131415'
|
||||
# red: '#864343'
|
||||
# green: '#777c44'
|
||||
# yellow: '#9e824c'
|
||||
# blue: '#556a7d'
|
||||
# magenta: '#75617b'
|
||||
# cyan: '#5b7d78'
|
||||
# white: '#828482'
|
||||
|
||||
# Indexed Colors
|
||||
#
|
||||
# The indexed colors include all colors from 16 to 256.
|
||||
# When these are not set, they're filled with sensible defaults.
|
||||
#
|
||||
# Example:
|
||||
# `- { index: 16, color: '#ff00ff' }`
|
||||
#
|
||||
#indexed_colors: []
|
||||
|
||||
# Bell
|
||||
#
|
||||
# The bell is rung every time the BEL control character is received.
|
||||
#bell:
|
||||
# Visual Bell Animation
|
||||
#
|
||||
# Animation effect for flashing the screen when the visual bell is rung.
|
||||
#
|
||||
# Values for `animation`:
|
||||
# - Ease
|
||||
# - EaseOut
|
||||
# - EaseOutSine
|
||||
# - EaseOutQuad
|
||||
# - EaseOutCubic
|
||||
# - EaseOutQuart
|
||||
# - EaseOutQuint
|
||||
# - EaseOutExpo
|
||||
# - EaseOutCirc
|
||||
# - Linear
|
||||
#animation: EaseOutExpo
|
||||
|
||||
# Duration of the visual bell flash in milliseconds. A `duration` of `0` will
|
||||
# disable the visual bell animation.
|
||||
#duration: 0
|
||||
|
||||
# Visual bell animation color.
|
||||
#color: '#ffffff'
|
||||
|
||||
# Bell Command
|
||||
#
|
||||
# This program is executed whenever the bell is rung.
|
||||
#
|
||||
# When set to `command: None`, no command will be executed.
|
||||
#
|
||||
# Example:
|
||||
# command:
|
||||
# program: notify-send
|
||||
# args: ["Hello, World!"]
|
||||
#
|
||||
#command: None
|
||||
|
||||
# Background opacity
|
||||
#
|
||||
# Window opacity as a floating point number from `0.0` to `1.0`.
|
||||
# The value `0.0` is completely transparent and `1.0` is opaque.
|
||||
#background_opacity: 1.0
|
||||
|
||||
#selection:
|
||||
# This string contains all characters that are used as separators for
|
||||
# "semantic words" in Alacritty.
|
||||
#semantic_escape_chars: ",│`|:\"' ()[]{}<>\t"
|
||||
|
||||
# When set to `true`, selected text will be copied to the primary clipboard.
|
||||
#save_to_clipboard: false
|
||||
|
||||
#cursor:
|
||||
# Cursor style
|
||||
#style:
|
||||
# Cursor shape
|
||||
#
|
||||
# Values for `shape`:
|
||||
# - ▇ Block
|
||||
# - _ Underline
|
||||
# - | Beam
|
||||
#shape: Block
|
||||
|
||||
# Cursor blinking state
|
||||
#
|
||||
# Values for `blinking`:
|
||||
# - Never: Prevent the cursor from ever blinking
|
||||
# - Off: Disable blinking by default
|
||||
# - On: Enable blinking by default
|
||||
# - Always: Force the cursor to always blink
|
||||
#blinking: Off
|
||||
|
||||
# Vi mode cursor style
|
||||
#
|
||||
# If the vi mode cursor style is `None` or not specified, it will fall back to
|
||||
# the style of the active value of the normal cursor.
|
||||
#
|
||||
# See `cursor.style` for available options.
|
||||
#vi_mode_style: None
|
||||
|
||||
# Cursor blinking interval in milliseconds.
|
||||
#blink_interval: 750
|
||||
|
||||
# If this is `true`, the cursor will be rendered as a hollow box when the
|
||||
# window is not focused.
|
||||
#unfocused_hollow: true
|
||||
|
||||
# Thickness of the cursor relative to the cell width as floating point number
|
||||
# from `0.0` to `1.0`.
|
||||
#thickness: 0.15
|
||||
|
||||
# Live config reload (changes require restart)
|
||||
#live_config_reload: true
|
||||
|
||||
# Shell
|
||||
#
|
||||
# You can set `shell.program` to the path of your favorite shell, e.g.
|
||||
# `/bin/fish`. Entries in `shell.args` are passed unmodified as arguments to the
|
||||
# shell.
|
||||
#
|
||||
# Default:
|
||||
# - (macOS) /bin/bash --login
|
||||
# - (Linux/BSD) user login shell
|
||||
# - (Windows) powershell
|
||||
#shell:
|
||||
# program: /bin/bash
|
||||
# args:
|
||||
# - --login
|
||||
|
||||
# Startup directory
|
||||
#
|
||||
# Directory the shell is started in. If this is unset, or `None`, the working
|
||||
# directory of the parent process will be used.
|
||||
#working_directory: None
|
||||
|
||||
# Send ESC (\x1b) before characters when alt is pressed.
|
||||
#alt_send_esc: true
|
||||
|
||||
#mouse:
|
||||
# Click settings
|
||||
#
|
||||
# The `double_click` and `triple_click` settings control the time
|
||||
# alacritty should wait for accepting multiple clicks as one double
|
||||
# or triple click.
|
||||
#double_click: { threshold: 300 }
|
||||
#triple_click: { threshold: 300 }
|
||||
|
||||
# If this is `true`, the cursor is temporarily hidden when typing.
|
||||
#hide_when_typing: false
|
||||
|
||||
#url:
|
||||
# URL launcher
|
||||
#
|
||||
# This program is executed when clicking on a text which is recognized as a
|
||||
# URL. The URL is always added to the command as the last parameter.
|
||||
#
|
||||
# When set to `launcher: None`, URL launching will be disabled completely.
|
||||
#
|
||||
# Default:
|
||||
# - (macOS) open
|
||||
# - (Linux/BSD) xdg-open
|
||||
# - (Windows) explorer
|
||||
#launcher:
|
||||
# program: xdg-open
|
||||
# args: []
|
||||
|
||||
# URL modifiers
|
||||
#
|
||||
# These are the modifiers that need to be held down for opening URLs when
|
||||
# clicking on them. The available modifiers are documented in the key
|
||||
# binding section.
|
||||
#modifiers: None
|
||||
|
||||
# Mouse bindings
|
||||
#
|
||||
# Mouse bindings are specified as a list of objects, much like the key
|
||||
# bindings further below.
|
||||
#
|
||||
# To trigger mouse bindings when an application running within Alacritty
|
||||
# captures the mouse, the `Shift` modifier is automatically added as a
|
||||
# requirement.
|
||||
#
|
||||
# Each mouse binding will specify a:
|
||||
#
|
||||
# - `mouse`:
|
||||
#
|
||||
# - Middle
|
||||
# - Left
|
||||
# - Right
|
||||
# - Numeric identifier such as `5`
|
||||
#
|
||||
# - `action` (see key bindings)
|
||||
#
|
||||
# And optionally:
|
||||
#
|
||||
# - `mods` (see key bindings)
|
||||
#mouse_bindings:
|
||||
# - { mouse: Middle, action: PasteSelection }
|
||||
|
||||
# Key bindings
|
||||
#
|
||||
# Key bindings are specified as a list of objects. For example, this is the
|
||||
# default paste binding:
|
||||
#
|
||||
# `- { key: V, mods: Control|Shift, action: Paste }`
|
||||
#
|
||||
# Each key binding will specify a:
|
||||
#
|
||||
# - `key`: Identifier of the key pressed
|
||||
#
|
||||
# - A-Z
|
||||
# - F1-F24
|
||||
# - Key0-Key9
|
||||
#
|
||||
# A full list with available key codes can be found here:
|
||||
# https://docs.rs/glutin/*/glutin/event/enum.VirtualKeyCode.html#variants
|
||||
#
|
||||
# Instead of using the name of the keys, the `key` field also supports using
|
||||
# the scancode of the desired key. Scancodes have to be specified as a
|
||||
# decimal number. This command will allow you to display the hex scancodes
|
||||
# for certain keys:
|
||||
#
|
||||
# `showkey --scancodes`.
|
||||
#
|
||||
# Then exactly one of:
|
||||
#
|
||||
# - `chars`: Send a byte sequence to the running application
|
||||
#
|
||||
# The `chars` field writes the specified string to the terminal. This makes
|
||||
# it possible to pass escape sequences. To find escape codes for bindings
|
||||
# like `PageUp` (`"\x1b[5~"`), you can run the command `showkey -a` outside
|
||||
# of tmux. Note that applications use terminfo to map escape sequences back
|
||||
# to keys. It is therefore required to update the terminfo when changing an
|
||||
# escape sequence.
|
||||
#
|
||||
# - `action`: Execute a predefined action
|
||||
#
|
||||
# - ToggleViMode
|
||||
# - SearchForward
|
||||
# Start searching toward the right of the search origin.
|
||||
# - SearchBackward
|
||||
# Start searching toward the left of the search origin.
|
||||
# - Copy
|
||||
# - Paste
|
||||
# - IncreaseFontSize
|
||||
# - DecreaseFontSize
|
||||
# - ResetFontSize
|
||||
# - ScrollPageUp
|
||||
# - ScrollPageDown
|
||||
# - ScrollHalfPageUp
|
||||
# - ScrollHalfPageDown
|
||||
# - ScrollLineUp
|
||||
# - ScrollLineDown
|
||||
# - ScrollToTop
|
||||
# - ScrollToBottom
|
||||
# - ClearHistory
|
||||
# Remove the terminal's scrollback history.
|
||||
# - Hide
|
||||
# Hide the Alacritty window.
|
||||
# - Minimize
|
||||
# Minimize the Alacritty window.
|
||||
# - Quit
|
||||
# Quit Alacritty.
|
||||
# - ToggleFullscreen
|
||||
# - SpawnNewInstance
|
||||
# Spawn a new instance of Alacritty.
|
||||
# - ClearLogNotice
|
||||
# Clear Alacritty's UI warning and error notice.
|
||||
# - ClearSelection
|
||||
# Remove the active selection.
|
||||
# - ReceiveChar
|
||||
# - None
|
||||
#
|
||||
# - Vi mode exclusive actions:
|
||||
#
|
||||
# - Open
|
||||
# Open URLs at the cursor location with the launcher configured in
|
||||
# `url.launcher`.
|
||||
# - ToggleNormalSelection
|
||||
# - ToggleLineSelection
|
||||
# - ToggleBlockSelection
|
||||
# - ToggleSemanticSelection
|
||||
# Toggle semantic selection based on `selection.semantic_escape_chars`.
|
||||
#
|
||||
# - Vi mode exclusive cursor motion actions:
|
||||
#
|
||||
# - Up
|
||||
# One line up.
|
||||
# - Down
|
||||
# One line down.
|
||||
# - Left
|
||||
# One character left.
|
||||
# - Right
|
||||
# One character right.
|
||||
# - First
|
||||
# First column, or beginning of the line when already at the first column.
|
||||
# - Last
|
||||
# Last column, or beginning of the line when already at the last column.
|
||||
# - FirstOccupied
|
||||
# First non-empty cell in this terminal row, or first non-empty cell of
|
||||
# the line when already at the first cell of the row.
|
||||
# - High
|
||||
# Top of the screen.
|
||||
# - Middle
|
||||
# Center of the screen.
|
||||
# - Low
|
||||
# Bottom of the screen.
|
||||
# - SemanticLeft
|
||||
# Start of the previous semantically separated word.
|
||||
# - SemanticRight
|
||||
# Start of the next semantically separated word.
|
||||
# - SemanticLeftEnd
|
||||
# End of the previous semantically separated word.
|
||||
# - SemanticRightEnd
|
||||
# End of the next semantically separated word.
|
||||
# - WordLeft
|
||||
# Start of the previous whitespace separated word.
|
||||
# - WordRight
|
||||
# Start of the next whitespace separated word.
|
||||
# - WordLeftEnd
|
||||
# End of the previous whitespace separated word.
|
||||
# - WordRightEnd
|
||||
# End of the next whitespace separated word.
|
||||
# - Bracket
|
||||
# Character matching the bracket at the cursor's location.
|
||||
# - SearchNext
|
||||
# Beginning of the next match.
|
||||
# - SearchPrevious
|
||||
# Beginning of the previous match.
|
||||
# - SearchStart
|
||||
# Start of the match to the left of the vi mode cursor.
|
||||
# - SearchEnd
|
||||
# End of the match to the right of the vi mode cursor.
|
||||
#
|
||||
# - Search mode exclusive actions:
|
||||
# - SearchFocusNext
|
||||
# Move the focus to the next search match.
|
||||
# - SearchFocusPrevious
|
||||
# Move the focus to the previous search match.
|
||||
# - SearchConfirm
|
||||
# - SearchCancel
|
||||
# - SearchClear
|
||||
# Reset the search regex.
|
||||
# - SearchDeleteWord
|
||||
# Delete the last word in the search regex.
|
||||
# - SearchHistoryPrevious
|
||||
# Go to the previous regex in the search history.
|
||||
# - SearchHistoryNext
|
||||
# Go to the next regex in the search history.
|
||||
#
|
||||
# - macOS exclusive actions:
|
||||
# - ToggleSimpleFullscreen
|
||||
# Enter fullscreen without occupying another space.
|
||||
#
|
||||
# - Linux/BSD exclusive actions:
|
||||
#
|
||||
# - CopySelection
|
||||
# Copy from the selection buffer.
|
||||
# - PasteSelection
|
||||
# Paste from the selection buffer.
|
||||
#
|
||||
# - `command`: Fork and execute a specified command plus arguments
|
||||
#
|
||||
# The `command` field must be a map containing a `program` string and an
|
||||
# `args` array of command line parameter strings. For example:
|
||||
# `{ program: "alacritty", args: ["-e", "vttest"] }`
|
||||
#
|
||||
# And optionally:
|
||||
#
|
||||
# - `mods`: Key modifiers to filter binding actions
|
||||
#
|
||||
# - Command
|
||||
# - Control
|
||||
# - Option
|
||||
# - Super
|
||||
# - Shift
|
||||
# - Alt
|
||||
#
|
||||
# Multiple `mods` can be combined using `|` like this:
|
||||
# `mods: Control|Shift`.
|
||||
# Whitespace and capitalization are relevant and must match the example.
|
||||
#
|
||||
# - `mode`: Indicate a binding for only specific terminal reported modes
|
||||
#
|
||||
# This is mainly used to send applications the correct escape sequences
|
||||
# when in different modes.
|
||||
#
|
||||
# - AppCursor
|
||||
# - AppKeypad
|
||||
# - Search
|
||||
# - Alt
|
||||
# - Vi
|
||||
#
|
||||
# A `~` operator can be used before a mode to apply the binding whenever
|
||||
# the mode is *not* active, e.g. `~Alt`.
|
||||
#
|
||||
# Bindings are always filled by default, but will be replaced when a new
|
||||
# binding with the same triggers is defined. To unset a default binding, it can
|
||||
# be mapped to the `ReceiveChar` action. Alternatively, you can use `None` for
|
||||
# a no-op if you do not wish to receive input characters for that binding.
|
||||
#
|
||||
# If the same trigger is assigned to multiple actions, all of them are executed
|
||||
# in the order they were defined in.
|
||||
#key_bindings:
|
||||
#- { key: Paste, action: Paste }
|
||||
#- { key: Copy, action: Copy }
|
||||
#- { key: L, mods: Control, action: ClearLogNotice }
|
||||
#- { key: L, mods: Control, mode: ~Vi|~Search, chars: "\x0c" }
|
||||
#- { key: PageUp, mods: Shift, mode: ~Alt, action: ScrollPageUp, }
|
||||
#- { key: PageDown, mods: Shift, mode: ~Alt, action: ScrollPageDown }
|
||||
#- { key: Home, mods: Shift, mode: ~Alt, action: ScrollToTop, }
|
||||
#- { key: End, mods: Shift, mode: ~Alt, action: ScrollToBottom }
|
||||
|
||||
# Vi Mode
|
||||
#- { key: Space, mods: Shift|Control, mode: Vi|~Search, action: ScrollToBottom }
|
||||
#- { key: Space, mods: Shift|Control, mode: ~Search, action: ToggleViMode }
|
||||
#- { key: Escape, mode: Vi|~Search, action: ClearSelection }
|
||||
#- { key: I, mode: Vi|~Search, action: ScrollToBottom }
|
||||
#- { key: I, mode: Vi|~Search, action: ToggleViMode }
|
||||
#- { key: C, mods: Control, mode: Vi|~Search, action: ToggleViMode }
|
||||
#- { key: Y, mods: Control, mode: Vi|~Search, action: ScrollLineUp }
|
||||
#- { key: E, mods: Control, mode: Vi|~Search, action: ScrollLineDown }
|
||||
#- { key: G, mode: Vi|~Search, action: ScrollToTop }
|
||||
#- { key: G, mods: Shift, mode: Vi|~Search, action: ScrollToBottom }
|
||||
#- { key: B, mods: Control, mode: Vi|~Search, action: ScrollPageUp }
|
||||
#- { key: F, mods: Control, mode: Vi|~Search, action: ScrollPageDown }
|
||||
#- { key: U, mods: Control, mode: Vi|~Search, action: ScrollHalfPageUp }
|
||||
#- { key: D, mods: Control, mode: Vi|~Search, action: ScrollHalfPageDown }
|
||||
#- { key: Y, mode: Vi|~Search, action: Copy }
|
||||
#- { key: Y, mode: Vi|~Search, action: ClearSelection }
|
||||
#- { key: Copy, mode: Vi|~Search, action: ClearSelection }
|
||||
#- { key: V, mode: Vi|~Search, action: ToggleNormalSelection }
|
||||
#- { key: V, mods: Shift, mode: Vi|~Search, action: ToggleLineSelection }
|
||||
#- { key: V, mods: Control, mode: Vi|~Search, action: ToggleBlockSelection }
|
||||
#- { key: V, mods: Alt, mode: Vi|~Search, action: ToggleSemanticSelection }
|
||||
#- { key: Return, mode: Vi|~Search, action: Open }
|
||||
#- { key: K, mode: Vi|~Search, action: Up }
|
||||
#- { key: J, mode: Vi|~Search, action: Down }
|
||||
#- { key: H, mode: Vi|~Search, action: Left }
|
||||
#- { key: L, mode: Vi|~Search, action: Right }
|
||||
#- { key: Up, mode: Vi|~Search, action: Up }
|
||||
#- { key: Down, mode: Vi|~Search, action: Down }
|
||||
#- { key: Left, mode: Vi|~Search, action: Left }
|
||||
#- { key: Right, mode: Vi|~Search, action: Right }
|
||||
#- { key: Key0, mode: Vi|~Search, action: First }
|
||||
#- { key: Key4, mods: Shift, mode: Vi|~Search, action: Last }
|
||||
#- { key: Key6, mods: Shift, mode: Vi|~Search, action: FirstOccupied }
|
||||
#- { key: H, mods: Shift, mode: Vi|~Search, action: High }
|
||||
#- { key: M, mods: Shift, mode: Vi|~Search, action: Middle }
|
||||
#- { key: L, mods: Shift, mode: Vi|~Search, action: Low }
|
||||
#- { key: B, mode: Vi|~Search, action: SemanticLeft }
|
||||
#- { key: W, mode: Vi|~Search, action: SemanticRight }
|
||||
#- { key: E, mode: Vi|~Search, action: SemanticRightEnd }
|
||||
#- { key: B, mods: Shift, mode: Vi|~Search, action: WordLeft }
|
||||
#- { key: W, mods: Shift, mode: Vi|~Search, action: WordRight }
|
||||
#- { key: E, mods: Shift, mode: Vi|~Search, action: WordRightEnd }
|
||||
#- { key: Key5, mods: Shift, mode: Vi|~Search, action: Bracket }
|
||||
#- { key: Slash, mode: Vi|~Search, action: SearchForward }
|
||||
#- { key: Slash, mods: Shift, mode: Vi|~Search, action: SearchBackward }
|
||||
#- { key: N, mode: Vi|~Search, action: SearchNext }
|
||||
#- { key: N, mods: Shift, mode: Vi|~Search, action: SearchPrevious }
|
||||
|
||||
# Search Mode
|
||||
#- { key: Return, mode: Search|Vi, action: SearchConfirm }
|
||||
#- { key: Escape, mode: Search, action: SearchCancel }
|
||||
#- { key: C, mods: Control, mode: Search, action: SearchCancel }
|
||||
#- { key: U, mods: Control, mode: Search, action: SearchClear }
|
||||
#- { key: W, mods: Control, mode: Search, action: SearchDeleteWord }
|
||||
#- { key: P, mods: Control, mode: Search, action: SearchHistoryPrevious }
|
||||
#- { key: N, mods: Control, mode: Search, action: SearchHistoryNext }
|
||||
#- { key: Up, mode: Search, action: SearchHistoryPrevious }
|
||||
#- { key: Down, mode: Search, action: SearchHistoryNext }
|
||||
#- { key: Return, mode: Search|~Vi, action: SearchFocusNext }
|
||||
#- { key: Return, mods: Shift, mode: Search|~Vi, action: SearchFocusPrevious }
|
||||
|
||||
# (Windows, Linux, and BSD only)
|
||||
#- { key: V, mods: Control|Shift, mode: ~Vi, action: Paste }
|
||||
#- { key: C, mods: Control|Shift, action: Copy }
|
||||
#- { key: F, mods: Control|Shift, mode: ~Search, action: SearchForward }
|
||||
#- { key: B, mods: Control|Shift, mode: ~Search, action: SearchBackward }
|
||||
#- { key: C, mods: Control|Shift, mode: Vi|~Search, action: ClearSelection }
|
||||
#- { key: Insert, mods: Shift, action: PasteSelection }
|
||||
#- { key: Key0, mods: Control, action: ResetFontSize }
|
||||
#- { key: Equals, mods: Control, action: IncreaseFontSize }
|
||||
#- { key: Plus, mods: Control, action: IncreaseFontSize }
|
||||
#- { key: NumpadAdd, mods: Control, action: IncreaseFontSize }
|
||||
#- { key: Minus, mods: Control, action: DecreaseFontSize }
|
||||
#- { key: NumpadSubtract, mods: Control, action: DecreaseFontSize }
|
||||
|
||||
# (Windows only)
|
||||
#- { key: Return, mods: Alt, action: ToggleFullscreen }
|
||||
|
||||
# (macOS only)
|
||||
#- { key: K, mods: Command, mode: ~Vi|~Search, chars: "\x0c" }
|
||||
#- { key: K, mods: Command, mode: ~Vi|~Search, action: ClearHistory }
|
||||
#- { key: Key0, mods: Command, action: ResetFontSize }
|
||||
#- { key: Equals, mods: Command, action: IncreaseFontSize }
|
||||
#- { key: Plus, mods: Command, action: IncreaseFontSize }
|
||||
#- { key: NumpadAdd, mods: Command, action: IncreaseFontSize }
|
||||
#- { key: Minus, mods: Command, action: DecreaseFontSize }
|
||||
#- { key: NumpadSubtract, mods: Command, action: DecreaseFontSize }
|
||||
#- { key: V, mods: Command, action: Paste }
|
||||
#- { key: C, mods: Command, action: Copy }
|
||||
#- { key: C, mods: Command, mode: Vi|~Search, action: ClearSelection }
|
||||
#- { key: H, mods: Command, action: Hide }
|
||||
#- { key: M, mods: Command, action: Minimize }
|
||||
#- { key: Q, mods: Command, action: Quit }
|
||||
#- { key: W, mods: Command, action: Quit }
|
||||
#- { key: N, mods: Command, action: SpawnNewInstance }
|
||||
#- { key: F, mods: Command|Control, action: ToggleFullscreen }
|
||||
#- { key: F, mods: Command, mode: ~Search, action: SearchForward }
|
||||
#- { key: B, mods: Command, mode: ~Search, action: SearchBackward }
|
||||
|
||||
#debug:
|
||||
# Display the time it takes to redraw each frame.
|
||||
#render_timer: false
|
||||
|
||||
# Keep the log file after quitting Alacritty.
|
||||
#persistent_logging: false
|
||||
|
||||
# Log level
|
||||
#
|
||||
# Values for `log_level`:
|
||||
# - Off
|
||||
# - Error
|
||||
# - Warn
|
||||
# - Info
|
||||
# - Debug
|
||||
# - Trace
|
||||
#log_level: Warn
|
||||
|
||||
# Print all received window events.
|
||||
#print_events: false
|
|
@ -1,8 +0,0 @@
|
|||
[Desktop Entry]
|
||||
Name=PulseEffects
|
||||
Comment=PulseEffects Service
|
||||
Exec=pulseeffects --gapplication-service
|
||||
Icon=pulseeffects
|
||||
StartupNotify=false
|
||||
Terminal=false
|
||||
Type=Application
|
|
@ -1,45 +0,0 @@
|
|||
[global]
|
||||
alignment = left
|
||||
follow = keyboard
|
||||
font = Roboto Mono for Powerline 11
|
||||
format = "<u><span foreground='#F7B2AE'>%s</span></u>\n%b"
|
||||
frame_color = "#383838"
|
||||
geometry = 500x0-5+5
|
||||
indicate_hidden = yes
|
||||
ignore_newline = no
|
||||
padding = 10
|
||||
horizontal_padding = 10
|
||||
progress_bar = true
|
||||
separator_color = "#383838"
|
||||
separator_height = 2
|
||||
shrink = no
|
||||
word_wrap = true
|
||||
corner_radius = 2
|
||||
frame_width = 3
|
||||
|
||||
icon_position = left
|
||||
icon_folders = /usr/share/icons/gnome/32x32/actions
|
||||
max_icon_size = 32
|
||||
|
||||
mouse_left_click = do_action, close_current
|
||||
mouse_right_click = close_all
|
||||
|
||||
[urgency_low]
|
||||
background = "#101423"
|
||||
foreground = "#EEFFFF"
|
||||
timeout = 5
|
||||
|
||||
[urgency_normal]
|
||||
background = "#101423"
|
||||
foreground = "#EEFFFF"
|
||||
timeout = 10
|
||||
|
||||
[urgency_critical]
|
||||
background = "#101423"
|
||||
foreground = "#EEFFFF"
|
||||
timeout = 0
|
||||
|
||||
[shortcuts]
|
||||
history = ctrl+grave
|
||||
context = ctrl+shift+period
|
||||
|
|
@ -1,23 +0,0 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
|
||||
<fontconfig>
|
||||
<alias>
|
||||
<family>serif</family>
|
||||
<prefer>
|
||||
<family>Noto Color Emoji</family>
|
||||
</prefer>
|
||||
</alias>
|
||||
<alias>
|
||||
<family>sans-serif</family>
|
||||
<prefer>
|
||||
<family>Noto Color Emoji</family>
|
||||
</prefer>
|
||||
</alias>
|
||||
<alias>
|
||||
<family>monospace</family>
|
||||
<prefer>
|
||||
<family>Noto Color Emoji</family>
|
||||
</prefer>
|
||||
</alias>
|
||||
</fontconfig>
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
[Settings]
|
||||
gtk-application-prefer-dark-theme=1
|
|
@ -1,227 +0,0 @@
|
|||
# This file has been auto-generated by i3-config-wizard(1).
|
||||
# It will not be overwritten, so edit it as you like.
|
||||
#
|
||||
# Should you change your keyboard layout some time, delete
|
||||
# this file and re-run i3-config-wizard(1).
|
||||
#
|
||||
|
||||
# i3 config file (v4)
|
||||
#
|
||||
# Please see https://i3wm.org/docs/userguide.html for a complete reference!
|
||||
|
||||
set $mod Mod4
|
||||
|
||||
# Font for window titles. Will also be used by the bar unless a different font
|
||||
# is used in the bar {} block below.
|
||||
# font pango:monospace 8
|
||||
font pango:Roboto Mono for Powerline 11
|
||||
|
||||
# This font is widely installed, provides lots of unicode glyphs, right-to-left
|
||||
# text rendering and scalability on retina/hidpi displays (thanks to pango).
|
||||
#font pango:DejaVu Sans Mono 8
|
||||
|
||||
# KEYBOARD SHORTCUTS
|
||||
bindsym $mod+F1 exec i3lock-fancy
|
||||
bindsym Print exec $HOME/.local/scripts/screenshot.sh select
|
||||
bindsym ctrl+Print exec $HOME/.local/scripts/screenshot.sh fullscreen
|
||||
bindsym shift+Print exec $HOME/.local/scripts/screenshot.sh window
|
||||
bindsym $mod+p exec $HOME/.local/scripts/passmenu.sh
|
||||
bindsym $mod+semicolon exec alacritty -e nvim $HOME/todos.md
|
||||
bindsym $mod+m exec $HOME/.local/scripts/toggle-vpn.sh sift-vpn-mzhang
|
||||
|
||||
# MOVE WINDOW BETWEEN MONITORS
|
||||
bindsym $mod+Ctrl+greater move workspace to output right
|
||||
bindsym $mod+Ctrl+less move workspace to output left
|
||||
|
||||
# The combination of xss-lock, nm-applet and pactl is a popular choice, so
|
||||
# they are included here as an example. Modify as you see fit.
|
||||
|
||||
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
|
||||
# screen before suspend. Use loginctl lock-session to lock your screen.
|
||||
exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
|
||||
exec --no-startup-id picom
|
||||
|
||||
# NetworkManager is the most popular way to manage wireless networks on Linux,
|
||||
# and nm-applet is a desktop environment-independent system tray GUI for it.
|
||||
exec --no-startup-id nm-applet
|
||||
exec --no-startup-id feh --bg-fill $HOME/.config/i3/wallpaper.jpg
|
||||
# exec --no-startup-id polybar -r michael
|
||||
exec --no-startup-id i3-msg 'workspace 10; exec rocketchat-desktop;'
|
||||
exec --no-startup-id dex -a
|
||||
|
||||
# Use pactl to adjust volume in PulseAudio.
|
||||
set $refresh_i3status pkill -RTMIN+10 i3blocks
|
||||
bindsym $mod+equal exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +4% && $refresh_i3status
|
||||
bindsym $mod+minus exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -4% && $refresh_i3status
|
||||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +4% && $refresh_i3status
|
||||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -4% && $refresh_i3status
|
||||
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
|
||||
bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
|
||||
bindsym XF86MonBrightnessDown exec --no-startup-id brightnessctl s 7%-
|
||||
bindsym XF86MonBrightnessUp exec --no-startup-id brightnessctl s +7%
|
||||
|
||||
bindsym $mod+F10 exec --no-startup-id mpc prev
|
||||
bindsym $mod+F11 exec --no-startup-id mpc toggle
|
||||
bindsym $mod+F12 exec --no-startup-id mpc next
|
||||
|
||||
# Use Mouse+$mod to drag floating windows to their wanted position
|
||||
floating_modifier $mod
|
||||
|
||||
# start a terminal
|
||||
bindsym $mod+Return exec WINIT_X11_SCALE_FACTOR=1.15 i3-sensible-terminal
|
||||
|
||||
# kill focused window
|
||||
bindsym $mod+Shift+q kill
|
||||
|
||||
# start dmenu (a program launcher)
|
||||
# bindsym $mod+space exec dmenu_run
|
||||
bindsym $mod+space exec $HOME/.local/scripts/app-picker.sh
|
||||
# There also is the (new) i3-dmenu-desktop which only displays applications
|
||||
# shipping a .desktop file. It is a wrapper around dmenu, so you need that
|
||||
# installed.
|
||||
# bindsym $mod+d exec --no-startup-id i3-dmenu-desktop
|
||||
|
||||
# change focus
|
||||
bindsym $mod+h focus left
|
||||
bindsym $mod+j focus down
|
||||
bindsym $mod+k focus up
|
||||
bindsym $mod+l focus right
|
||||
|
||||
# alternatively, you can use the cursor keys:
|
||||
bindsym $mod+Left focus left
|
||||
bindsym $mod+Down focus down
|
||||
bindsym $mod+Up focus up
|
||||
bindsym $mod+Right focus right
|
||||
|
||||
# move focused window
|
||||
bindsym $mod+Shift+j move left
|
||||
bindsym $mod+Shift+k move down
|
||||
bindsym $mod+Shift+l move up
|
||||
bindsym $mod+Shift+semicolon move right
|
||||
|
||||
# alternatively, you can use the cursor keys:
|
||||
bindsym $mod+Shift+Left move left
|
||||
bindsym $mod+Shift+Down move down
|
||||
bindsym $mod+Shift+Up move up
|
||||
bindsym $mod+Shift+Right move right
|
||||
|
||||
# split in horizontal orientation
|
||||
# bindsym $mod+h split h
|
||||
|
||||
# split in vertical orientation
|
||||
# bindsym $mod+v split v
|
||||
|
||||
# enter fullscreen mode for the focused container
|
||||
bindsym $mod+f fullscreen toggle
|
||||
|
||||
# change container layout (stacked, tabbed, toggle split)
|
||||
bindsym $mod+s layout stacking
|
||||
bindsym $mod+w layout tabbed
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
# toggle tiling / floating
|
||||
bindsym $mod+Shift+space floating toggle
|
||||
|
||||
# change focus between tiling / floating windows
|
||||
# bindsym $mod+space focus mode_toggle
|
||||
|
||||
# focus the parent container
|
||||
bindsym $mod+a focus parent
|
||||
|
||||
# focus the child container
|
||||
#bindsym $mod+d focus child
|
||||
|
||||
# Define names for default workspaces for which we configure key bindings later on.
|
||||
# We use variables to avoid repeating the names in multiple places.
|
||||
set $ws1 "1"
|
||||
set $ws2 "2"
|
||||
set $ws3 "3"
|
||||
set $ws4 "4"
|
||||
set $ws5 "5"
|
||||
set $ws6 "6"
|
||||
set $ws7 "7"
|
||||
set $ws8 "8"
|
||||
set $ws9 "9"
|
||||
set $ws10 "10"
|
||||
|
||||
# switch to workspace
|
||||
bindsym $mod+1 workspace number $ws1
|
||||
bindsym $mod+2 workspace number $ws2
|
||||
bindsym $mod+3 workspace number $ws3
|
||||
bindsym $mod+4 workspace number $ws4
|
||||
bindsym $mod+5 workspace number $ws5
|
||||
bindsym $mod+6 workspace number $ws6
|
||||
bindsym $mod+7 workspace number $ws7
|
||||
bindsym $mod+8 workspace number $ws8
|
||||
bindsym $mod+9 workspace number $ws9
|
||||
bindsym $mod+0 workspace number $ws10
|
||||
|
||||
# move focused container to workspace
|
||||
bindsym $mod+Shift+1 move container to workspace number $ws1
|
||||
bindsym $mod+Shift+2 move container to workspace number $ws2
|
||||
bindsym $mod+Shift+3 move container to workspace number $ws3
|
||||
bindsym $mod+Shift+4 move container to workspace number $ws4
|
||||
bindsym $mod+Shift+5 move container to workspace number $ws5
|
||||
bindsym $mod+Shift+6 move container to workspace number $ws6
|
||||
bindsym $mod+Shift+7 move container to workspace number $ws7
|
||||
bindsym $mod+Shift+8 move container to workspace number $ws8
|
||||
bindsym $mod+Shift+9 move container to workspace number $ws9
|
||||
bindsym $mod+Shift+0 move container to workspace number $ws10
|
||||
|
||||
# reload the configuration file
|
||||
bindsym $mod+Shift+c reload
|
||||
# restart i3 inplace (preserves your layout/session, can be used to upgrade i3)
|
||||
bindsym $mod+Shift+r restart
|
||||
# exit i3 (logs you out of your X session)
|
||||
bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcut. Do you really want to exit i3? This will end your X session.' -B 'Yes, exit i3' 'i3-msg exit'"
|
||||
|
||||
# resize window (you can also use the mouse for that)
|
||||
mode "resize" {
|
||||
# These bindings trigger as soon as you enter the resize mode
|
||||
|
||||
# Pressing left will shrink the window’s width.
|
||||
# Pressing right will grow the window’s width.
|
||||
# Pressing up will shrink the window’s height.
|
||||
# Pressing down will grow the window’s height.
|
||||
bindsym j resize shrink width 10 px or 10 ppt
|
||||
bindsym k resize grow height 10 px or 10 ppt
|
||||
bindsym l resize shrink height 10 px or 10 ppt
|
||||
bindsym semicolon resize grow width 10 px or 10 ppt
|
||||
|
||||
# same bindings, but for the arrow keys
|
||||
bindsym Left resize shrink width 10 px or 10 ppt
|
||||
bindsym Down resize grow height 10 px or 10 ppt
|
||||
bindsym Up resize shrink height 10 px or 10 ppt
|
||||
bindsym Right resize grow width 10 px or 10 ppt
|
||||
|
||||
# back to normal: Enter or Escape or $mod+r
|
||||
bindsym Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
bindsym $mod+r mode "default"
|
||||
}
|
||||
|
||||
bindsym $mod+r mode "resize"
|
||||
|
||||
# Start i3bar to display a workspace bar (plus the system information i3status
|
||||
# finds out, if available)
|
||||
bar {
|
||||
tray_output HDMI-A-0
|
||||
tray_output DisplayPort-0
|
||||
|
||||
status_command i3blocks
|
||||
|
||||
colors {
|
||||
active_workspace #333333 #333333 #ffffff
|
||||
background #222222
|
||||
focused_workspace #0088CC #0088CC #ffffff
|
||||
inactive_workspace #333333 #333333 #888888
|
||||
separator #666666
|
||||
statusline #dddddd
|
||||
urgent_workspace #2f343a #900000 #ffffff
|
||||
}
|
||||
}
|
||||
|
||||
client.focused #0088CC #0088CC #ffffff #dddddd #0088CC
|
||||
client.focused_inactive #333333 #333333 #888888 #292d2e #333333
|
||||
client.unfocused #333333 #333333 #888888 #292d2e #333333
|
||||
client.urgent #2f343a #900000 #ffffff #900000 #2f343a
|
Binary file not shown.
Before Width: | Height: | Size: 399 KiB |
|
@ -1,31 +0,0 @@
|
|||
[memory]
|
||||
command=/usr/lib/i3blocks/memory
|
||||
label=MEM
|
||||
interval=20
|
||||
|
||||
[weather]
|
||||
command=curl -Ss "https://wttr.in/55404?m&format=%25c%25C+%25t+%25p\n"
|
||||
interval=3600
|
||||
color=#A4C2F4
|
||||
|
||||
[volume]
|
||||
command=/usr/lib/i3blocks/volume
|
||||
LABEL=VOL
|
||||
interval=once
|
||||
signal=10
|
||||
|
||||
[battery-poly]
|
||||
command=/usr/lib/i3blocks/battery-poly
|
||||
LABEL=BAT
|
||||
interval=5
|
||||
color=#999999
|
||||
|
||||
[date]
|
||||
command=date +"%a %m [%d] %Y"
|
||||
interval=5
|
||||
color=#EE92EE
|
||||
|
||||
[time]
|
||||
command=date +"[%H:%M] :%S"
|
||||
interval=5
|
||||
color=#EEEE92
|
|
@ -1,391 +0,0 @@
|
|||
# An example configuration file for MPD.
|
||||
# Read the user manual for documentation: http://www.musicpd.org/doc/user/
|
||||
|
||||
|
||||
# Files and directories #######################################################
|
||||
#
|
||||
# This setting controls the top directory which MPD will search to discover the
|
||||
# available audio files and add them to the daemon's online database. This
|
||||
# setting defaults to the XDG directory, otherwise the music directory will be
|
||||
# be disabled and audio files will only be accepted over ipc socket (using
|
||||
# file:// protocol) or streaming files over an accepted protocol.
|
||||
#
|
||||
music_directory "~/Music"
|
||||
#
|
||||
# This setting sets the MPD internal playlist directory. The purpose of this
|
||||
# directory is storage for playlists created by MPD. The server will use
|
||||
# playlist files not created by the server but only if they are in the MPD
|
||||
# format. This setting defaults to playlist saving being disabled.
|
||||
#
|
||||
playlist_directory "~/.config/mpd/playlists"
|
||||
#
|
||||
# This setting sets the location of the MPD database. This file is used to
|
||||
# load the database at server start up and store the database while the
|
||||
# server is not up. This setting defaults to disabled which will allow
|
||||
# MPD to accept files over ipc socket (using file:// protocol) or streaming
|
||||
# files over an accepted protocol.
|
||||
#
|
||||
db_file "~/.config/mpd/database"
|
||||
#
|
||||
# These settings are the locations for the daemon log files for the daemon.
|
||||
# These logs are great for troubleshooting, depending on your log_level
|
||||
# settings.
|
||||
#
|
||||
# The special value "syslog" makes MPD use the local syslog daemon. This
|
||||
# setting defaults to logging to syslog.
|
||||
#
|
||||
#log_file "~/.mpd/log"
|
||||
log_file "~/.mpd.log"
|
||||
#
|
||||
# This setting sets the location of the file which stores the process ID
|
||||
# for use of mpd --kill and some init scripts. This setting is disabled by
|
||||
# default and the pid file will not be stored.
|
||||
#
|
||||
#pid_file "~/.mpd/pid"
|
||||
#
|
||||
# This setting sets the location of the file which contains information about
|
||||
# most variables to get MPD back into the same general shape it was in before
|
||||
# it was brought down. This setting is disabled by default and the server
|
||||
# state will be reset on server start up.
|
||||
#
|
||||
state_file "~/.config/mpd/state"
|
||||
#
|
||||
# The location of the sticker database. This is a database which
|
||||
# manages dynamic information attached to songs.
|
||||
#
|
||||
#sticker_file "~/.mpd/sticker.sql"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# General music daemon options ################################################
|
||||
#
|
||||
# This setting specifies the user that MPD will run as. MPD should never run as
|
||||
# root and you may use this setting to make MPD change its user ID after
|
||||
# initialization. This setting is disabled by default and MPD is run as the
|
||||
# current user.
|
||||
#
|
||||
#user "nobody"
|
||||
#
|
||||
# This setting specifies the group that MPD will run as. If not specified
|
||||
# primary group of user specified with "user" setting will be used (if set).
|
||||
# This is useful if MPD needs to be a member of group such as "audio" to
|
||||
# have permission to use sound card.
|
||||
#
|
||||
#group "nogroup"
|
||||
#
|
||||
# This setting sets the address for the daemon to listen on. Careful attention
|
||||
# should be paid if this is assigned to anything other then the default, any.
|
||||
# This setting can deny access to control of the daemon. Not effective if
|
||||
# systemd socket activiation is in use.
|
||||
#
|
||||
# For network
|
||||
#bind_to_address "any"
|
||||
#
|
||||
# And for Unix Socket
|
||||
#bind_to_address "~/.mpd/socket"
|
||||
#
|
||||
# This setting is the TCP port that is desired for the daemon to get assigned
|
||||
# to.
|
||||
#
|
||||
#port "6600"
|
||||
#
|
||||
# This setting controls the type of information which is logged. Available
|
||||
# setting arguments are "default", "secure" or "verbose". The "verbose" setting
|
||||
# argument is recommended for troubleshooting, though can quickly stretch
|
||||
# available resources on limited hardware storage.
|
||||
#
|
||||
#log_level "default"
|
||||
#
|
||||
# Setting "restore_paused" to "yes" puts MPD into pause mode instead
|
||||
# of starting playback after startup.
|
||||
#
|
||||
#restore_paused "no"
|
||||
#
|
||||
# This setting enables MPD to create playlists in a format usable by other
|
||||
# music players.
|
||||
#
|
||||
#save_absolute_paths_in_playlists "no"
|
||||
#
|
||||
# This setting defines a list of tag types that will be extracted during the
|
||||
# audio file discovery process. The complete list of possible values can be
|
||||
# found in the user manual.
|
||||
#metadata_to_use "artist,album,title,track,name,genre,date,composer,performer,disc"
|
||||
#
|
||||
# This example just enables the "comment" tag without disabling all
|
||||
# the other supported tags:
|
||||
#metadata_to_use "+comment"
|
||||
#
|
||||
# This setting enables automatic update of MPD's database when files in
|
||||
# music_directory are changed.
|
||||
#
|
||||
#auto_update "yes"
|
||||
#
|
||||
# Limit the depth of the directories being watched, 0 means only watch
|
||||
# the music directory itself. There is no limit by default.
|
||||
#
|
||||
#auto_update_depth "3"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# Symbolic link behavior ######################################################
|
||||
#
|
||||
# If this setting is set to "yes", MPD will discover audio files by following
|
||||
# symbolic links outside of the configured music_directory.
|
||||
#
|
||||
#follow_outside_symlinks "yes"
|
||||
#
|
||||
# If this setting is set to "yes", MPD will discover audio files by following
|
||||
# symbolic links inside of the configured music_directory.
|
||||
#
|
||||
#follow_inside_symlinks "yes"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# Zeroconf / Avahi Service Discovery ##########################################
|
||||
#
|
||||
# If this setting is set to "yes", service information will be published with
|
||||
# Zeroconf / Avahi.
|
||||
#
|
||||
#zeroconf_enabled "yes"
|
||||
#
|
||||
# The argument to this setting will be the Zeroconf / Avahi unique name for
|
||||
# this MPD server on the network. %h will be replaced with the hostname.
|
||||
#
|
||||
#zeroconf_name "Music Player @ %h"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# Permissions #################################################################
|
||||
#
|
||||
# If this setting is set, MPD will require password authorization. The password
|
||||
# setting can be specified multiple times for different password profiles.
|
||||
#
|
||||
#password "password@read,add,control,admin"
|
||||
#
|
||||
# This setting specifies the permissions a user has who has not yet logged in.
|
||||
#
|
||||
#default_permissions "read,add,control,admin"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# Database #######################################################################
|
||||
#
|
||||
|
||||
#database {
|
||||
# plugin "proxy"
|
||||
# host "other.mpd.host"
|
||||
# port "6600"
|
||||
#}
|
||||
|
||||
# Input #######################################################################
|
||||
#
|
||||
|
||||
input {
|
||||
plugin "curl"
|
||||
# proxy "proxy.isp.com:8080"
|
||||
# proxy_user "user"
|
||||
# proxy_password "password"
|
||||
}
|
||||
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
# Audio Output ################################################################
|
||||
#
|
||||
# MPD supports various audio output types, as well as playing through multiple
|
||||
# audio outputs at the same time, through multiple audio_output settings
|
||||
# blocks. Setting this block is optional, though the server will only attempt
|
||||
# autodetection for one sound card.
|
||||
#
|
||||
# An example of an ALSA output:
|
||||
#
|
||||
audio_output {
|
||||
type "alsa"
|
||||
name "My ALSA Device"
|
||||
## device "hw:0,0" # optional
|
||||
## mixer_type "hardware" # optional
|
||||
## mixer_device "default" # optional
|
||||
## mixer_control "PCM" # optional
|
||||
## mixer_index "0" # optional
|
||||
}
|
||||
#
|
||||
# An example of an OSS output:
|
||||
#
|
||||
#audio_output {
|
||||
# type "oss"
|
||||
# name "My OSS Device"
|
||||
## device "/dev/dsp" # optional
|
||||
## mixer_type "hardware" # optional
|
||||
## mixer_device "/dev/mixer" # optional
|
||||
## mixer_control "PCM" # optional
|
||||
#}
|
||||
#
|
||||
# An example of a shout output (for streaming to Icecast):
|
||||
#
|
||||
#audio_output {
|
||||
# type "shout"
|
||||
# encoder "vorbis" # optional
|
||||
# name "My Shout Stream"
|
||||
# host "localhost"
|
||||
# port "8000"
|
||||
# mount "/mpd.ogg"
|
||||
# password "hackme"
|
||||
# quality "5.0"
|
||||
# bitrate "128"
|
||||
# format "44100:16:1"
|
||||
## protocol "icecast2" # optional
|
||||
## user "source" # optional
|
||||
## description "My Stream Description" # optional
|
||||
## url "http://example.com" # optional
|
||||
## genre "jazz" # optional
|
||||
## public "no" # optional
|
||||
## timeout "2" # optional
|
||||
## mixer_type "software" # optional
|
||||
#}
|
||||
#
|
||||
# An example of a recorder output:
|
||||
#
|
||||
#audio_output {
|
||||
# type "recorder"
|
||||
# name "My recorder"
|
||||
# encoder "vorbis" # optional, vorbis or lame
|
||||
# path "/var/lib/mpd/recorder/mpd.ogg"
|
||||
## quality "5.0" # do not define if bitrate is defined
|
||||
# bitrate "128" # do not define if quality is defined
|
||||
# format "44100:16:1"
|
||||
#}
|
||||
#
|
||||
# An example of a httpd output (built-in HTTP streaming server):
|
||||
#
|
||||
audio_output {
|
||||
type "httpd"
|
||||
name "My HTTP Stream"
|
||||
encoder "vorbis" # optional, vorbis or lame
|
||||
port "6680"
|
||||
bind_to_address "0.0.0.0" # optional, IPv4 or IPv6
|
||||
quality "5.0" # do not define if bitrate is defined
|
||||
# bitrate "128" # do not define if quality is defined
|
||||
format "44100:16:1"
|
||||
max_clients "0" # optional 0=no limit
|
||||
}
|
||||
#
|
||||
# An example of a pulseaudio output (streaming to a remote pulseaudio server)
|
||||
#
|
||||
#audio_output {
|
||||
# type "pulse"
|
||||
# name "My Pulse Output"
|
||||
## server "remote_server" # optional
|
||||
## sink "remote_server_sink" # optional
|
||||
#}
|
||||
#
|
||||
# An example of a winmm output (Windows multimedia API).
|
||||
#
|
||||
#audio_output {
|
||||
# type "winmm"
|
||||
# name "My WinMM output"
|
||||
## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
|
||||
# or
|
||||
## device "0" # optional
|
||||
## mixer_type "hardware" # optional
|
||||
#}
|
||||
#
|
||||
# An example of an openal output.
|
||||
#
|
||||
#audio_output {
|
||||
# type "openal"
|
||||
# name "My OpenAL output"
|
||||
## device "Digital Audio (S/PDIF) (High Definition Audio Device)" # optional
|
||||
#}
|
||||
#
|
||||
# An example of an sndio output.
|
||||
#
|
||||
#audio_output {
|
||||
# type "sndio"
|
||||
# name "sndio output"
|
||||
# mixer_type "hardware"
|
||||
#}
|
||||
#
|
||||
# An example of an OS X output:
|
||||
#
|
||||
#audio_output {
|
||||
# type "osx"
|
||||
# name "My OS X Device"
|
||||
## device "Built-in Output" # optional
|
||||
## channel_map "-1,-1,0,1" # optional
|
||||
#}
|
||||
#
|
||||
## Example "pipe" output:
|
||||
#
|
||||
#audio_output {
|
||||
# type "pipe"
|
||||
# name "my pipe"
|
||||
# command "aplay -f cd 2>/dev/null"
|
||||
## Or if you're want to use AudioCompress
|
||||
# command "AudioCompress -m | aplay -f cd 2>/dev/null"
|
||||
## Or to send raw PCM stream through PCM:
|
||||
# command "nc example.org 8765"
|
||||
# format "44100:16:2"
|
||||
#}
|
||||
#
|
||||
## An example of a null output (for no audio output):
|
||||
#
|
||||
#audio_output {
|
||||
# type "null"
|
||||
# name "My Null Output"
|
||||
# mixer_type "none" # optional
|
||||
#}
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
|
||||
# Normalization automatic volume adjustments ##################################
|
||||
#
|
||||
# This setting specifies the type of ReplayGain to use. This setting can have
|
||||
# the argument "off", "album", "track" or "auto". "auto" is a special mode that
|
||||
# chooses between "track" and "album" depending on the current state of
|
||||
# random playback. If random playback is enabled then "track" mode is used.
|
||||
# See <http://www.replaygain.org> for more details about ReplayGain.
|
||||
# This setting is off by default.
|
||||
#
|
||||
#replaygain "album"
|
||||
#
|
||||
# This setting sets the pre-amp used for files that have ReplayGain tags. By
|
||||
# default this setting is disabled.
|
||||
#
|
||||
#replaygain_preamp "0"
|
||||
#
|
||||
# This setting sets the pre-amp used for files that do NOT have ReplayGain tags.
|
||||
# By default this setting is disabled.
|
||||
#
|
||||
#replaygain_missing_preamp "0"
|
||||
#
|
||||
# This setting enables or disables ReplayGain limiting.
|
||||
# MPD calculates actual amplification based on the ReplayGain tags
|
||||
# and replaygain_preamp / replaygain_missing_preamp setting.
|
||||
# If replaygain_limit is enabled MPD will never amplify audio signal
|
||||
# above its original level. If replaygain_limit is disabled such amplification
|
||||
# might occur. By default this setting is enabled.
|
||||
#
|
||||
#replaygain_limit "yes"
|
||||
#
|
||||
# This setting enables on-the-fly normalization volume adjustment. This will
|
||||
# result in the volume of all playing audio to be adjusted so the output has
|
||||
# equal "loudness". This setting is disabled by default.
|
||||
#
|
||||
#volume_normalization "no"
|
||||
#
|
||||
###############################################################################
|
||||
|
||||
# Character Encoding ##########################################################
|
||||
#
|
||||
# If file or directory names do not display correctly for your locale then you
|
||||
# may need to modify this setting.
|
||||
#
|
||||
#filesystem_charset "UTF-8"
|
||||
#
|
||||
###############################################################################
|
|
@ -1,2 +0,0 @@
|
|||
experimental-features = nix-command flakes
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
let g:airline_powerline_fonts = 1
|
||||
let g:airline#extensions#tabline#buffer_nr_show = 1
|
||||
let g:airline#extensions#tabline#enabled = 1
|
|
@ -1,37 +0,0 @@
|
|||
{
|
||||
"python.jediEnabled": false,
|
||||
"python.venvFolders": ["~/.local/share/virtualenvs"],
|
||||
"rust-analyzer.diagnostics.disabled": ["unresolved-proc-macro"],
|
||||
"languageserver": {
|
||||
"ocaml-lsp": {
|
||||
"command": "opam",
|
||||
"args": ["config", "exec", "--", "ocamllsp"],
|
||||
"filetypes": ["ocaml", "reason"]
|
||||
},
|
||||
"haskell": {
|
||||
"command": "ghcide",
|
||||
"args": [
|
||||
"--lsp"
|
||||
],
|
||||
"rootPatterns": [
|
||||
".stack.yaml",
|
||||
".hie-bios",
|
||||
"BUILD.bazel",
|
||||
"cabal.config",
|
||||
"package.yaml"
|
||||
],
|
||||
"filetypes": [
|
||||
"hs",
|
||||
"lhs",
|
||||
"haskell"
|
||||
]
|
||||
},
|
||||
"fstar": {
|
||||
"command": "fstar.exe",
|
||||
"args": ["--lsp"],
|
||||
"rootPatterns": [],
|
||||
"trace.server": "verbose",
|
||||
"filetypes": ["fst", "fsti"]
|
||||
}
|
||||
}
|
||||
}
|
|
@ -1,53 +0,0 @@
|
|||
set hidden
|
||||
set nobackup
|
||||
set nowritebackup
|
||||
|
||||
set cmdheight=2
|
||||
set shortmess+=c
|
||||
set signcolumn=yes
|
||||
|
||||
set statusline^=%{coc#status()}%{get(b:,'coc_current_function','')}
|
||||
|
||||
function! s:show_documentation()
|
||||
if (index(['vim','help'], &filetype) >= 0)
|
||||
execute 'h '.expand('<cword>')
|
||||
else
|
||||
call CocAction('doHover')
|
||||
endif
|
||||
endfunction
|
||||
|
||||
command! -nargs=0 Format :call CocAction('format')
|
||||
|
||||
" Binds
|
||||
nnoremap <silent> K :call <SID>show_documentation()<CR>
|
||||
nnoremap <silent> <space>a :<C-u>CocList diagnostics<cr>
|
||||
nnoremap <silent> <space>e :<C-u>CocList extensions<cr>
|
||||
nnoremap <silent> <space>c :<C-u>CocList commands<cr>
|
||||
nnoremap <silent> <space>o :<C-u>CocList outline<cr>
|
||||
nnoremap <silent> <space>s :<C-u>CocList -I symbols<cr>
|
||||
nnoremap <silent> <space>j :<C-u>CocNext<CR>
|
||||
nnoremap <silent> <space>k :<C-u>CocPrev<CR>
|
||||
nnoremap <silent> <space>p :<C-u>CocListResume<CR>
|
||||
nnoremap <silent> <space>. <Plug>(coc-codeaction-selected)
|
||||
|
||||
nmap <silent> [g <Plug>(coc-diagnostic-prev)
|
||||
nmap <silent> ]g <Plug>(coc-diagnostic-next)
|
||||
nmap <silent> gd <Plug>(coc-definition)
|
||||
nmap <silent> gy <Plug>(coc-type-definition)
|
||||
nmap <silent> gi <Plug>(coc-implementation)
|
||||
nmap <silent> gr <Plug>(coc-references)
|
||||
nmap <leader>rn <Plug>(coc-rename)
|
||||
nmap <leader>f <Plug>(coc-format-selected)
|
||||
|
||||
xmap <leader>f <Plug>(coc-format-selected)
|
||||
|
||||
inoremap <silent><expr> <c-space> coc#refresh()
|
||||
|
||||
function! s:cocActionsOpenFromSelected(type) abort
|
||||
execute 'CocCommand actions.open ' . a:type
|
||||
endfunction
|
||||
xmap <silent> <leader>a :<C-u>execute 'CocCommand actions.open ' . visualmode()<CR>
|
||||
nmap <silent> <leader>a :<C-u>set operatorfunc=<SID>cocActionsOpenFromSelected<CR>g@
|
||||
|
||||
nmap <leader>ac <Plug>(coc-codeaction)
|
||||
nmap <leader>qf <Plug>(coc-fix-current)
|
|
@ -1,143 +0,0 @@
|
|||
call plug#begin(stdpath('data') . '/plugged')
|
||||
|
||||
Plug 'vim-airline/vim-airline'
|
||||
exe 'source' (stdpath('config') . '/airline.vim')
|
||||
|
||||
" Plug 'neoclide/coc.nvim', {'branch': 'release'}
|
||||
" exe 'source' (stdpath('config') . '/coc.vim')
|
||||
|
||||
Plug 'preservim/nerdtree'
|
||||
exe 'source' (stdpath('config') . '/nerdtree.vim')
|
||||
|
||||
" Plug 'ctrlpvim/ctrlp.vim'
|
||||
let g:ctrlp_user_command = 'rg %s --files --color=never --glob ""'
|
||||
|
||||
Plug 'neovim/nvim-lspconfig'
|
||||
Plug 'hrsh7th/nvim-compe'
|
||||
|
||||
Plug 'FStarLang/VimFStar', {'for': 'fstar'}
|
||||
Plug 'LnL7/vim-nix'
|
||||
" Plug 'ashinkarov/nvim-agda'
|
||||
Plug 'derekelkins/agda-vim'
|
||||
Plug 'evanleck/vim-svelte', {'branch': 'main'}
|
||||
Plug 'prettier/vim-prettier', { 'do': 'yarn install' }
|
||||
Plug 'sheerun/vim-polyglot'
|
||||
Plug 'tomasiser/vim-code-dark'
|
||||
Plug 'editorconfig/editorconfig-vim'
|
||||
Plug 'ctrlpvim/ctrlp.vim'
|
||||
Plug 'wakatime/vim-wakatime'
|
||||
Plug 'andweeb/presence.nvim'
|
||||
|
||||
call plug#end()
|
||||
|
||||
let g:go_fmt_command = 'goimports'
|
||||
|
||||
let g:vim_markdown_new_list_item_indent = 2
|
||||
let g:vim_markdown_folding_disabled = 1
|
||||
let g:vim_markdown_toml_frontmatter = 1
|
||||
|
||||
" General config
|
||||
|
||||
colorscheme codedark
|
||||
|
||||
set splitright
|
||||
set number relativenumber
|
||||
set cursorline
|
||||
set hidden
|
||||
set modeline
|
||||
set modelines=5
|
||||
set tabstop=4
|
||||
set shiftwidth=4
|
||||
set expandtab
|
||||
set formatoptions+=t
|
||||
set colorcolumn=80
|
||||
set textwidth=80
|
||||
|
||||
syntax on
|
||||
filetype on
|
||||
filetype plugin indent on
|
||||
|
||||
augroup numbertoggle
|
||||
autocmd!
|
||||
autocmd BufEnter,FocusGained,InsertLeave,WinEnter * if &nu && mode() != "i" | set rnu | endif
|
||||
autocmd BufLeave,FocusLost,InsertEnter,WinLeave * if &nu | set nornu | endif
|
||||
augroup END
|
||||
|
||||
" Binds
|
||||
|
||||
let mapleader = ";"
|
||||
let maplocalleader = ";"
|
||||
|
||||
nnoremap T :vsplit<BAR>vertical resize 54<BAR>terminal<CR>i
|
||||
|
||||
imap kj <Esc>
|
||||
|
||||
nmap <F8> :TagbarToggle<CR>
|
||||
|
||||
" Plugin-related configs
|
||||
|
||||
let g:go_fmt_command = "goimports"
|
||||
|
||||
" LSP
|
||||
|
||||
nnoremap <silent> gd <cmd>lua vim.lsp.buf.definition()<CR>
|
||||
nnoremap <silent> gD <cmd>lua vim.lsp.buf.declaration()<CR>
|
||||
nnoremap <silent> gr <cmd>lua vim.lsp.buf.references()<CR>
|
||||
nnoremap <silent> gi <cmd>lua vim.lsp.buf.implementation()<CR>
|
||||
nnoremap <silent> K <cmd>lua vim.lsp.buf.hover()<CR>
|
||||
nnoremap <silent> <C-k> <cmd>lua vim.lsp.buf.signature_help()<CR>
|
||||
nnoremap <silent> <space>k <cmd>lua vim.lsp.diagnostic.goto_prev()<CR>
|
||||
nnoremap <silent> <space>j <cmd>lua vim.lsp.diagnostic.goto_next()<CR>
|
||||
nnoremap <silent> <space>a <cmd>lua vim.lsp.buf.code_action()<CR>
|
||||
|
||||
lua << EOF
|
||||
vim.o.completeopt = "menuone,noselect"
|
||||
|
||||
require'compe'.setup {
|
||||
enabled = true;
|
||||
autocomplete = true;
|
||||
debug = false;
|
||||
min_length = 1;
|
||||
preselect = 'enable';
|
||||
throttle_time = 80;
|
||||
source_timeout = 200;
|
||||
incomplete_delay = 400;
|
||||
max_abbr_width = 100;
|
||||
max_kind_width = 100;
|
||||
max_menu_width = 100;
|
||||
documentation = false;
|
||||
|
||||
source = {
|
||||
path = true;
|
||||
buffer = true;
|
||||
calc = true;
|
||||
vsnip = true;
|
||||
nvim_lsp = true;
|
||||
nvim_lua = true;
|
||||
spell = true;
|
||||
tags = true;
|
||||
snippets_nvim = true;
|
||||
treesitter = true;
|
||||
};
|
||||
}
|
||||
local t = function(str)
|
||||
return vim.api.nvim_replace_termcodes(str, true, true, true)
|
||||
end
|
||||
|
||||
local check_back_space = function()
|
||||
local col = vim.fn.col('.') - 1
|
||||
if col == 0 or vim.fn.getline('.'):sub(col, col):match('%s') then
|
||||
return true
|
||||
else
|
||||
return false
|
||||
end
|
||||
end
|
||||
|
||||
require'lspconfig'.rust_analyzer.setup{}
|
||||
require'lspconfig'.pyright.setup{}
|
||||
require'lspconfig'.tsserver.setup{}
|
||||
require'lspconfig'.vuels.setup{}
|
||||
require'lspconfig'.clangd.setup{}
|
||||
EOF
|
||||
|
||||
" vim: set sw=2 :
|
|
@ -1,2 +0,0 @@
|
|||
map <C-n> :NERDTreeToggle<CR>
|
||||
let g:NERDTreeShowHidden=1
|
|
@ -1,5 +0,0 @@
|
|||
opacity-rule = [
|
||||
"90:class_g = 'alacritty' && focused",
|
||||
"80:class_g = 'alacritty' && !focused"
|
||||
];
|
||||
|
|
@ -1,425 +0,0 @@
|
|||
;==========================================================
|
||||
;
|
||||
;
|
||||
; ██████╗ ██████╗ ██╗ ██╗ ██╗██████╗ █████╗ ██████╗
|
||||
; ██╔══██╗██╔═══██╗██║ ╚██╗ ██╔╝██╔══██╗██╔══██╗██╔══██╗
|
||||
; ██████╔╝██║ ██║██║ ╚████╔╝ ██████╔╝███████║██████╔╝
|
||||
; ██╔═══╝ ██║ ██║██║ ╚██╔╝ ██╔══██╗██╔══██║██╔══██╗
|
||||
; ██║ ╚██████╔╝███████╗██║ ██████╔╝██║ ██║██║ ██║
|
||||
; ╚═╝ ╚═════╝ ╚══════╝╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝
|
||||
;
|
||||
;
|
||||
; To learn more about how to configure Polybar
|
||||
; go to https://github.com/polybar/polybar
|
||||
;
|
||||
; The README contains a lot of information
|
||||
;
|
||||
;==========================================================
|
||||
|
||||
[colors]
|
||||
;background = ${xrdb:color0:#222}
|
||||
background = #222
|
||||
background-alt = #444
|
||||
;foreground = ${xrdb:color7:#222}
|
||||
foreground = #dfdfdf
|
||||
foreground-alt = #555
|
||||
primary = #ffb52a
|
||||
secondary = #e60053
|
||||
alert = #bd2c40
|
||||
|
||||
[bar/michael]
|
||||
;monitor = ${env:MONITOR:HDMI-1}
|
||||
width = 100%
|
||||
height = 27
|
||||
;offset-x = 1%
|
||||
;offset-y = 1%
|
||||
radius = 0.0
|
||||
fixed-center = false
|
||||
bottom = true
|
||||
|
||||
background = ${colors.background}
|
||||
foreground = ${colors.foreground}
|
||||
|
||||
line-size = 3
|
||||
line-color = #f00
|
||||
|
||||
border-size = 0
|
||||
border-color = #00000000
|
||||
|
||||
padding-left = 0
|
||||
padding-right = 2
|
||||
|
||||
module-margin-left = 1
|
||||
module-margin-right = 2
|
||||
|
||||
font-0 = fixed:pixelsize=10;1
|
||||
font-1 = unifont:fontformat=truetype:size=8:antialias=false;0
|
||||
font-2 = siji:pixelsize=10;1
|
||||
font-3 = Noto Sans CJK JP:size=10:antialias=true;0
|
||||
|
||||
modules-left = bspwm i3
|
||||
modules-center = mpd
|
||||
modules-right = filesystem xbacklight pulseaudio xkeyboard memory cpu wlan eth temperature battery date powermenu
|
||||
|
||||
tray-position = right
|
||||
tray-padding = 2
|
||||
;tray-background = #0063ff
|
||||
|
||||
;wm-restack = bspwm
|
||||
;wm-restack = i3
|
||||
|
||||
;override-redirect = true
|
||||
|
||||
;scroll-up = bspwm-desknext
|
||||
;scroll-down = bspwm-deskprev
|
||||
|
||||
scroll-up = i3wm-wsnext
|
||||
scroll-down = i3wm-wsprev
|
||||
|
||||
cursor-click = pointer
|
||||
cursor-scroll = ns-resize
|
||||
|
||||
[module/xwindow]
|
||||
type = internal/xwindow
|
||||
label = %title:0:30:...%
|
||||
|
||||
[module/xkeyboard]
|
||||
type = internal/xkeyboard
|
||||
blacklist-0 = num lock
|
||||
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-prefix-underline = ${colors.secondary}
|
||||
|
||||
label-layout = %layout%
|
||||
label-layout-underline = ${colors.secondary}
|
||||
|
||||
label-indicator-padding = 2
|
||||
label-indicator-margin = 1
|
||||
label-indicator-background = ${colors.secondary}
|
||||
label-indicator-underline = ${colors.secondary}
|
||||
|
||||
[module/filesystem]
|
||||
type = internal/fs
|
||||
interval = 25
|
||||
|
||||
mount-0 = /
|
||||
|
||||
label-mounted = %{F#0a81f5}%mountpoint%%{F-}: %percentage_used%%
|
||||
label-unmounted = %mountpoint% not mounted
|
||||
label-unmounted-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/bspwm]
|
||||
type = internal/bspwm
|
||||
|
||||
label-focused = %index%
|
||||
label-focused-background = ${colors.background-alt}
|
||||
label-focused-underline= ${colors.primary}
|
||||
label-focused-padding = 2
|
||||
|
||||
label-occupied = %index%
|
||||
label-occupied-padding = 2
|
||||
|
||||
label-urgent = %index%!
|
||||
label-urgent-background = ${colors.alert}
|
||||
label-urgent-padding = 2
|
||||
|
||||
label-empty = %index%
|
||||
label-empty-foreground = ${colors.foreground-alt}
|
||||
label-empty-padding = 2
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
[module/i3]
|
||||
type = internal/i3
|
||||
format = <label-state> <label-mode>
|
||||
index-sort = true
|
||||
wrapping-scroll = false
|
||||
|
||||
; Only show workspaces on the same output as the bar
|
||||
;pin-workspaces = true
|
||||
|
||||
label-mode-padding = 2
|
||||
label-mode-foreground = #000
|
||||
label-mode-background = ${colors.primary}
|
||||
|
||||
; focused = Active workspace on focused monitor
|
||||
label-focused = %index%
|
||||
label-focused-background = ${colors.background-alt}
|
||||
label-focused-underline= ${colors.primary}
|
||||
label-focused-padding = 2
|
||||
|
||||
; unfocused = Inactive workspace on any monitor
|
||||
label-unfocused = %index%
|
||||
label-unfocused-padding = 2
|
||||
|
||||
; visible = Active workspace on unfocused monitor
|
||||
label-visible = %index%
|
||||
label-visible-background = ${self.label-focused-background}
|
||||
label-visible-underline = ${self.label-focused-underline}
|
||||
label-visible-padding = ${self.label-focused-padding}
|
||||
|
||||
; urgent = Workspace with urgency hint set
|
||||
label-urgent = %index%
|
||||
label-urgent-background = ${colors.alert}
|
||||
label-urgent-padding = 2
|
||||
|
||||
; Separator in between workspaces
|
||||
; label-separator = |
|
||||
|
||||
|
||||
[module/mpd]
|
||||
type = internal/mpd
|
||||
format-online = <label-song> <icon-prev> <icon-stop> <toggle> <icon-next>
|
||||
|
||||
icon-prev =
|
||||
icon-stop =
|
||||
icon-play =
|
||||
icon-pause =
|
||||
icon-next =
|
||||
|
||||
label-song-maxlen = 100
|
||||
label-song-ellipsis = true
|
||||
|
||||
[module/xbacklight]
|
||||
type = internal/xbacklight
|
||||
|
||||
format = <label> <bar>
|
||||
label = BL
|
||||
|
||||
bar-width = 10
|
||||
bar-indicator = |
|
||||
bar-indicator-foreground = #fff
|
||||
bar-indicator-font = 2
|
||||
bar-fill = ─
|
||||
bar-fill-font = 2
|
||||
bar-fill-foreground = #9f78e1
|
||||
bar-empty = ─
|
||||
bar-empty-font = 2
|
||||
bar-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/backlight-acpi]
|
||||
inherit = module/xbacklight
|
||||
type = internal/backlight
|
||||
card = intel_backlight
|
||||
|
||||
[module/cpu]
|
||||
type = internal/cpu
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #f90000
|
||||
label = %percentage:2%%
|
||||
|
||||
[module/memory]
|
||||
type = internal/memory
|
||||
interval = 2
|
||||
format-prefix = " "
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #4bffdc
|
||||
label = %percentage_used%%
|
||||
|
||||
[module/wlan]
|
||||
type = internal/network
|
||||
interface = net1
|
||||
interval = 3.0
|
||||
|
||||
format-connected = <ramp-signal> <label-connected>
|
||||
format-connected-underline = #9f78e1
|
||||
label-connected = %essid%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
ramp-signal-0 =
|
||||
ramp-signal-1 =
|
||||
ramp-signal-2 =
|
||||
ramp-signal-3 =
|
||||
ramp-signal-4 =
|
||||
ramp-signal-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/eth]
|
||||
type = internal/network
|
||||
interface = eno1
|
||||
interval = 3.0
|
||||
|
||||
format-connected-underline = #55aa55
|
||||
format-connected-prefix = " "
|
||||
format-connected-prefix-foreground = ${colors.foreground-alt}
|
||||
label-connected = %local_ip%
|
||||
|
||||
format-disconnected =
|
||||
;format-disconnected = <label-disconnected>
|
||||
;format-disconnected-underline = ${self.format-connected-underline}
|
||||
;label-disconnected = %ifname% disconnected
|
||||
;label-disconnected-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/date]
|
||||
type = internal/date
|
||||
interval = 5
|
||||
|
||||
date = " %m-%d"
|
||||
date-alt = " %Y-%m-%d"
|
||||
|
||||
time = %H:%M
|
||||
time-alt = %H:%M:%S
|
||||
|
||||
format-prefix =
|
||||
format-prefix-foreground = ${colors.foreground-alt}
|
||||
format-underline = #0a6cf5
|
||||
|
||||
label = %date% %time%
|
||||
|
||||
[module/pulseaudio]
|
||||
type = internal/pulseaudio
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL %percentage%%
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
label-muted = 🔇 muted
|
||||
label-muted-foreground = #666
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/alsa]
|
||||
type = internal/alsa
|
||||
|
||||
format-volume = <label-volume> <bar-volume>
|
||||
label-volume = VOL
|
||||
label-volume-foreground = ${root.foreground}
|
||||
|
||||
format-muted-prefix = " "
|
||||
format-muted-foreground = ${colors.foreground-alt}
|
||||
label-muted = sound muted
|
||||
|
||||
bar-volume-width = 10
|
||||
bar-volume-foreground-0 = #55aa55
|
||||
bar-volume-foreground-1 = #55aa55
|
||||
bar-volume-foreground-2 = #55aa55
|
||||
bar-volume-foreground-3 = #55aa55
|
||||
bar-volume-foreground-4 = #55aa55
|
||||
bar-volume-foreground-5 = #f5a70a
|
||||
bar-volume-foreground-6 = #ff5555
|
||||
bar-volume-gradient = false
|
||||
bar-volume-indicator = |
|
||||
bar-volume-indicator-font = 2
|
||||
bar-volume-fill = ─
|
||||
bar-volume-fill-font = 2
|
||||
bar-volume-empty = ─
|
||||
bar-volume-empty-font = 2
|
||||
bar-volume-empty-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/battery]
|
||||
type = internal/battery
|
||||
battery = BAT0
|
||||
adapter = ADP1
|
||||
full-at = 98
|
||||
|
||||
format-charging = <animation-charging> <label-charging>
|
||||
format-charging-underline = #ffb52a
|
||||
|
||||
format-discharging = <animation-discharging> <label-discharging>
|
||||
format-discharging-underline = ${self.format-charging-underline}
|
||||
|
||||
format-full-prefix = " "
|
||||
format-full-prefix-foreground = ${colors.foreground-alt}
|
||||
format-full-underline = ${self.format-charging-underline}
|
||||
|
||||
ramp-capacity-0 =
|
||||
ramp-capacity-1 =
|
||||
ramp-capacity-2 =
|
||||
ramp-capacity-foreground = ${colors.foreground-alt}
|
||||
|
||||
animation-charging-0 =
|
||||
animation-charging-1 =
|
||||
animation-charging-2 =
|
||||
animation-charging-foreground = ${colors.foreground-alt}
|
||||
animation-charging-framerate = 750
|
||||
|
||||
animation-discharging-0 =
|
||||
animation-discharging-1 =
|
||||
animation-discharging-2 =
|
||||
animation-discharging-foreground = ${colors.foreground-alt}
|
||||
animation-discharging-framerate = 750
|
||||
|
||||
[module/temperature]
|
||||
type = internal/temperature
|
||||
thermal-zone = 0
|
||||
warn-temperature = 60
|
||||
|
||||
format = <ramp> <label>
|
||||
format-underline = #f50a4d
|
||||
format-warn = <ramp> <label-warn>
|
||||
format-warn-underline = ${self.format-underline}
|
||||
|
||||
label = %temperature-c%
|
||||
label-warn = %temperature-c%
|
||||
label-warn-foreground = ${colors.secondary}
|
||||
|
||||
ramp-0 =
|
||||
ramp-1 =
|
||||
ramp-2 =
|
||||
ramp-foreground = ${colors.foreground-alt}
|
||||
|
||||
[module/powermenu]
|
||||
type = custom/menu
|
||||
|
||||
expand-right = true
|
||||
|
||||
format-spacing = 1
|
||||
|
||||
label-open =
|
||||
label-open-foreground = ${colors.secondary}
|
||||
label-close = cancel
|
||||
label-close-foreground = ${colors.secondary}
|
||||
label-separator = |
|
||||
label-separator-foreground = ${colors.foreground-alt}
|
||||
|
||||
menu-0-0 = reboot
|
||||
menu-0-0-exec = menu-open-1
|
||||
menu-0-1 = power off
|
||||
menu-0-1-exec = menu-open-2
|
||||
|
||||
menu-1-0 = cancel
|
||||
menu-1-0-exec = menu-open-0
|
||||
menu-1-1 = reboot
|
||||
menu-1-1-exec = sudo reboot
|
||||
|
||||
menu-2-0 = power off
|
||||
menu-2-0-exec = sudo poweroff
|
||||
menu-2-1 = cancel
|
||||
menu-2-1-exec = menu-open-0
|
||||
|
||||
[settings]
|
||||
screenchange-reload = true
|
||||
;compositing-background = xor
|
||||
;compositing-background = screen
|
||||
;compositing-foreground = source
|
||||
;compositing-border = over
|
||||
;pseudo-transparency = false
|
||||
|
||||
[global/wm]
|
||||
margin-top = 5
|
||||
margin-bottom = 5
|
||||
|
||||
; vim:ft=dosini
|
|
@ -1,4 +0,0 @@
|
|||
[Settings]
|
||||
gtk-application-prefer-dark-theme = 1
|
||||
gtk-theme-name = Arc
|
||||
|
|
@ -1 +0,0 @@
|
|||
rofi.theme: /usr/share/rofi/themes/Arc-Dark.rasi
|
|
@ -1,3 +0,0 @@
|
|||
configuration {
|
||||
theme: "/usr/share/rofi/themes/Arc-Dark.rasi";
|
||||
}
|
|
@ -1,153 +0,0 @@
|
|||
set $mod Mod4
|
||||
floating_modifier $mod
|
||||
font pango:Roboto Mono for Powerline 11
|
||||
|
||||
set $opacity 0.92
|
||||
for_window [class=".*"] opacity $opacity
|
||||
for_window [app_id=".*"] opacity $opacity
|
||||
|
||||
# STARTUP
|
||||
exec --no-startup-id swaybg --image /home/michael/Pictures/celeste-wallpaper.jpg
|
||||
exec --no-startup-id mpd
|
||||
exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
|
||||
exec --no-startup-id waybar
|
||||
exec --no-startup-id nm-applet
|
||||
exec --no-startup-id feh --bg-fill /home/michael/Pictures/wallpaper.jpg
|
||||
exec --no-startup-id dunst
|
||||
|
||||
# KEY BINDS
|
||||
bindsym $mod+Return exec i3-sensible-terminal
|
||||
bindsym $mod+l exec swaylock
|
||||
bindsym $mod+m exec alacritty -e aerc
|
||||
bindsym $mod+n exec alacritty -e newsboat
|
||||
bindsym $mod+p exec $HOME/.local/scripts/passmenu.sh
|
||||
bindsym $mod+semicolon exec alacritty -e nvim $HOME/todos.md
|
||||
bindsym $mod+space exec bemenu-run
|
||||
bindsym Print exec bash -c 'grim "$HOME/Screenshots/$(date +%Y-%m-%d-%H:%M:%S).png" && wl-copy < "$HOME/Screenshots/$(date +%Y-%m-%d-%H:%M:%S).png"'
|
||||
# bindsym Print exec $HOME/.local/scripts/screenshot.sh select
|
||||
# bindsym ctrl+Print exec $HOME/.local/scripts/screenshot.sh fullscreen
|
||||
|
||||
bindsym $mod+Shift+q kill
|
||||
bindsym $mod+f fullscreen toggle
|
||||
bindsym $mod+h split h
|
||||
bindsym $mod+r mode "resize"
|
||||
bindsym $mod+v split v
|
||||
|
||||
bindsym $mod+equal exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +4% && $refresh_i3status
|
||||
bindsym $mod+minus exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -4% && $refresh_i3status
|
||||
bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status
|
||||
bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status
|
||||
bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
|
||||
bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
|
||||
|
||||
bindsym $mod+F10 exec --no-startup-id mpc prev
|
||||
bindsym $mod+F11 exec --no-startup-id mpc toggle
|
||||
bindsym $mod+F12 exec --no-startup-id mpc next
|
||||
|
||||
bindsym $mod+Shift+c reload
|
||||
bindsym $mod+Shift+r restart
|
||||
bindsym $mod+Shift+e exec "swaynag -t warning -m 'Really exit?' -B 'Yes' 'i3-msg exit'"
|
||||
|
||||
bindsym $mod+Left focus left
|
||||
bindsym $mod+Down focus down
|
||||
bindsym $mod+Up focus up
|
||||
bindsym $mod+Right focus right
|
||||
|
||||
# move focused window
|
||||
bindsym $mod+Shift+j move left
|
||||
bindsym $mod+Shift+k move down
|
||||
bindsym $mod+Shift+l move up
|
||||
bindsym $mod+Shift+semicolon move right
|
||||
|
||||
bindsym $mod+Shift+Left move left
|
||||
bindsym $mod+Shift+Down move down
|
||||
bindsym $mod+Shift+Up move up
|
||||
bindsym $mod+Shift+Right move right
|
||||
|
||||
|
||||
# change container layout (stacked, tabbed, toggle split)
|
||||
bindsym $mod+s layout stacking
|
||||
bindsym $mod+w layout tabbed
|
||||
bindsym $mod+e layout toggle split
|
||||
|
||||
# toggle tiling / floating
|
||||
bindsym $mod+Shift+space floating toggle
|
||||
|
||||
# change focus between tiling / floating windows
|
||||
# bindsym $mod+space focus mode_toggle
|
||||
|
||||
# focus the parent container
|
||||
bindsym $mod+a focus parent
|
||||
|
||||
# focus the child container
|
||||
#bindsym $mod+d focus child
|
||||
|
||||
# Define names for default workspaces for which we configure key bindings later on.
|
||||
# We use variables to avoid repeating the names in multiple places.
|
||||
set $ws1 "1"
|
||||
set $ws2 "2"
|
||||
set $ws3 "3"
|
||||
set $ws4 "4"
|
||||
set $ws5 "5"
|
||||
set $ws6 "6"
|
||||
set $ws7 "7"
|
||||
set $ws8 "8"
|
||||
set $ws9 "9"
|
||||
set $ws10 "10"
|
||||
|
||||
# switch to workspace
|
||||
bindsym $mod+1 workspace number $ws1
|
||||
bindsym $mod+2 workspace number $ws2
|
||||
bindsym $mod+3 workspace number $ws3
|
||||
bindsym $mod+4 workspace number $ws4
|
||||
bindsym $mod+5 workspace number $ws5
|
||||
bindsym $mod+6 workspace number $ws6
|
||||
bindsym $mod+7 workspace number $ws7
|
||||
bindsym $mod+8 workspace number $ws8
|
||||
bindsym $mod+9 workspace number $ws9
|
||||
bindsym $mod+0 workspace number $ws10
|
||||
|
||||
# move focused container to workspace
|
||||
bindsym $mod+Shift+1 move container to workspace number $ws1
|
||||
bindsym $mod+Shift+2 move container to workspace number $ws2
|
||||
bindsym $mod+Shift+3 move container to workspace number $ws3
|
||||
bindsym $mod+Shift+4 move container to workspace number $ws4
|
||||
bindsym $mod+Shift+5 move container to workspace number $ws5
|
||||
bindsym $mod+Shift+6 move container to workspace number $ws6
|
||||
bindsym $mod+Shift+7 move container to workspace number $ws7
|
||||
bindsym $mod+Shift+8 move container to workspace number $ws8
|
||||
bindsym $mod+Shift+9 move container to workspace number $ws9
|
||||
bindsym $mod+Shift+0 move container to workspace number $ws10
|
||||
|
||||
|
||||
# resize window (you can also use the mouse for that)
|
||||
mode "resize" {
|
||||
# These bindings trigger as soon as you enter the resize mode
|
||||
|
||||
# Pressing left will shrink the window’s width.
|
||||
# Pressing right will grow the window’s width.
|
||||
# Pressing up will shrink the window’s height.
|
||||
# Pressing down will grow the window’s height.
|
||||
bindsym j resize shrink width 10 px or 10 ppt
|
||||
bindsym k resize grow height 10 px or 10 ppt
|
||||
bindsym l resize shrink height 10 px or 10 ppt
|
||||
bindsym semicolon resize grow width 10 px or 10 ppt
|
||||
|
||||
# same bindings, but for the arrow keys
|
||||
bindsym Left resize shrink width 10 px or 10 ppt
|
||||
bindsym Down resize grow height 10 px or 10 ppt
|
||||
bindsym Up resize shrink height 10 px or 10 ppt
|
||||
bindsym Right resize grow width 10 px or 10 ppt
|
||||
|
||||
# back to normal: Enter or Escape or $mod+r
|
||||
bindsym Return mode "default"
|
||||
bindsym Escape mode "default"
|
||||
bindsym $mod+r mode "default"
|
||||
}
|
||||
|
||||
|
||||
# Start i3bar to display a workspace bar (plus the system information i3status
|
||||
# finds out, if available)
|
||||
# bar {
|
||||
# status_command i3status
|
||||
# }
|
|
@ -1 +0,0 @@
|
|||
/usr/lib/systemd/user/redshift.service
|
|
@ -1,9 +0,0 @@
|
|||
[Unit]
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Restart=always
|
||||
ExecStart=/home/michael/.local/share/proton-bridge/run-proton-bridge.sh
|
||||
|
||||
[Install]
|
||||
WantedBy=default.target
|
|
@ -1,42 +0,0 @@
|
|||
// https://github.com/Alexays/Waybar/wiki/Configuration
|
||||
|
||||
{
|
||||
"layer": "top",
|
||||
"position": "bottom",
|
||||
"modules-left": ["sway/workspaces", "sway/mode"],
|
||||
"modules-center": ["sway/window"],
|
||||
"modules-right": ["mpd", "disk", "network", "pulseaudio", "clock", "tray"],
|
||||
|
||||
"disk": {
|
||||
"format": "💽{percentage_free}%"
|
||||
},
|
||||
|
||||
"clock": {
|
||||
"format": "📅 <b>{:%m-%d / %H:%M}</b>",
|
||||
"tooltip-format": "<big>{:%Y %B}</big>\n<tt><small>{calendar}</small></tt>"
|
||||
},
|
||||
|
||||
"network": {
|
||||
"format-ethernet": "🖥️ {ifname}: {ipaddr}/{cidr}",
|
||||
"format-wifi": " {essid} ({signalStrength}%)"
|
||||
},
|
||||
|
||||
"pulseaudio": {
|
||||
"format": "{icon} {volume}%",
|
||||
"format-bluetooth": "{icon} {volume}%",
|
||||
"format-muted": "",
|
||||
"format-icons": {
|
||||
"headphones": "",
|
||||
"handsfree": "",
|
||||
"headset": "",
|
||||
"phone": "",
|
||||
"portable": "",
|
||||
"car": "",
|
||||
"default": ["", ""]
|
||||
},
|
||||
"on-click": "pavucontrol"
|
||||
}
|
||||
}
|
||||
|
||||
// vim: set ft=json5 ts=4 sw=4 tw=0 :
|
||||
|
|
@ -1,34 +0,0 @@
|
|||
* {
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
font-family: Roboto, Helvetica, Arial, sans-serif;
|
||||
font-size: 13px;
|
||||
min-height: 0;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
background: -gtk-gradient(
|
||||
linear,
|
||||
left bottom,
|
||||
left top,
|
||||
from(rgba(0, 0, 0, 0.9)),
|
||||
to(rgba(0, 0, 0, 0.0))
|
||||
);
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 2px 5px;
|
||||
border-bottom: 2px solid transparent;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
#workspaces button.focused {
|
||||
border-bottom: 2px solid white;
|
||||
}
|
||||
|
||||
#mpd, #disk, #clock, #battery, #cpu, #memory, #network, #pulseaudio, #tray, #mode {
|
||||
padding: 2px 6px;
|
||||
margin: 0 3px;
|
||||
background-color: rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
|
@ -1,31 +0,0 @@
|
|||
[user]
|
||||
email = mail@mzhang.io
|
||||
name = Michael Zhang
|
||||
signingkey = 925ECC02890D5CDAE26180D4BDA47A31A3C8EE6B
|
||||
|
||||
[alias]
|
||||
lg = log --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
|
||||
lgg = log --graph --all --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
|
||||
pushpr = "!f() { git push origin master;git commit --allow-empty -m 'push to execute post-receive';git push origin master; }; f"
|
||||
|
||||
[init]
|
||||
defaultBranch = "master"
|
||||
|
||||
[pull]
|
||||
rebase = true
|
||||
|
||||
[commit]
|
||||
gpgsign = true
|
||||
|
||||
{{ if .pass }}
|
||||
[sendemail]
|
||||
smtpServer = mzhang.io
|
||||
smtpServerPort = 465
|
||||
smtpUser = mail@mzhang.io
|
||||
smtpPass = {{ pass "email/mail@mzhang.io" }}
|
||||
smtpEncryption = ssl
|
||||
confirm = auto
|
||||
{{ end }}
|
||||
|
||||
# vim: set filetype=gitconfig:
|
||||
|
|
@ -1,52 +0,0 @@
|
|||
source $HOME/.common.sh
|
||||
|
||||
command_exists exa && alias ls="exa"
|
||||
command_exists garbage && alias rm="garbage put"
|
||||
|
||||
alias remind="printf '\a'"
|
||||
alias cm="chezmoi"
|
||||
alias kill-gpg-agent="gpgconf --kill gpg-agent"
|
||||
alias dcompose="docker-compose"
|
||||
alias ytmp3="youtube-dl --extract-audio --audio-format mp3 --embed-thumbnail --add-metadata"
|
||||
|
||||
function nixdev() {
|
||||
DIR=$(pwd)
|
||||
while [ ! -f "$DIR/flake.nix" ]; do
|
||||
DIR=$(dirname $DIR)
|
||||
if [[ "$DIR" == "/" ]]; then break; fi
|
||||
done
|
||||
nix develop "$DIR#$1" -c zsh
|
||||
}
|
||||
|
||||
function ced() {
|
||||
# if the file doesn't exist, prompt to make a new one
|
||||
if [ ! -f "$1" ]; then
|
||||
read "?$1 doesn't exist.. create file? [yN] " yn
|
||||
case $yn in
|
||||
[Yy]* )
|
||||
echo "creating new file"
|
||||
install -D /dev/null $1
|
||||
echo "\n" > $1
|
||||
chezmoi add $1;;
|
||||
* )
|
||||
echo "nah"
|
||||
return;;
|
||||
esac
|
||||
# if the file exists but not in chezmoi
|
||||
else
|
||||
chezmoi source-path $1 > /dev/null
|
||||
result=$?
|
||||
if [ $result -ne 0 ]; then
|
||||
echo "file doesn't exist in chezmoi.. adding"
|
||||
chezmoi add $1
|
||||
fi
|
||||
fi
|
||||
|
||||
chezmoi edit $1
|
||||
echo "applying changes..."
|
||||
chezmoi apply
|
||||
}
|
||||
|
||||
cpush() {
|
||||
chezmoi git add . -- -A && chezmoi git commit -- -m "update" && chezmoi git push
|
||||
}
|
|
@ -1,43 +0,0 @@
|
|||
source $HOME/.common.sh
|
||||
|
||||
export LANG=en_US.UTF-8
|
||||
|
||||
export DOTNET_CLI_TELEMETRY_OPTOUT=1
|
||||
# export RUST_SRC_PATH="$(rustc --print sysroot)/lib/rustlib/src/rust/src"
|
||||
export EDITOR=vim
|
||||
command_exists nvim && export EDITOR=nvim
|
||||
export MAILDIR=$HOME/Mail
|
||||
|
||||
source_if_exists $HOME/.cargo/env
|
||||
source_if_exists "${GHCUP_INSTALL_BASE_PREFIX:=$HOME}/.ghcup/env"
|
||||
|
||||
append_path "$HOME/.local/bin"
|
||||
append_path "$HOME/.local/scripts"
|
||||
append_path "$HOME/.dotnet/tools"
|
||||
append_path "$HOME/go/bin"
|
||||
append_path "$HOME/.idris2/bin"
|
||||
append_path "$HOME/.opam/default/bin"
|
||||
append_path "$HOME/.local/share/prt"
|
||||
|
||||
[[ -s /etc/profile.d/autojump.sh ]] && source /etc/profile.d/autojump.sh
|
||||
eval $(opam env)
|
||||
|
||||
# opam configuration
|
||||
# test -r /home/michael/.opam/opam-init/init.zsh && . /home/michael/.opam/opam-init/init.zsh > /dev/null 2> /dev/null || true
|
||||
|
||||
function rgc() {
|
||||
rg --color always $@ | bat --color always
|
||||
}
|
||||
|
||||
function loadnpm() {
|
||||
export NVM_DIR="$HOME/.nvm"
|
||||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||
}
|
||||
|
||||
# ssh
|
||||
unset SSH_AGENT_PID
|
||||
if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then
|
||||
export SSH_AUTH_SOCK="$(gpgconf --list-dirs agent-ssh-socket)"
|
||||
fi
|
||||
|
||||
# vim: set filetype=sh:
|
|
@ -1,3 +0,0 @@
|
|||
#!/bin/bash
|
||||
exec $HOME/.local/scripts/rofiwrap.sh -show combi -modi combi -combi-modi "window,drun" -levenshtein-sort -icon-theme "Papirus" -show-icons
|
||||
|
|
@ -1,25 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
shopt -s nullglob globstar
|
||||
|
||||
typeit=0
|
||||
if [[ $1 == "--type" ]]; then
|
||||
typeit=1
|
||||
shift
|
||||
fi
|
||||
|
||||
prefix=${PASSWORD_STORE_DIR-~/.password-store}
|
||||
password_files=( "$prefix"/**/*.gpg )
|
||||
password_files=( "${password_files[@]#"$prefix"/}" )
|
||||
password_files=( "${password_files[@]%.gpg}" )
|
||||
|
||||
password=$(printf '%s\n' "${password_files[@]}" | $HOME/.local/scripts/rofiwrap.sh -dmenu -levenshtein-sort -i -p "Password for" "$@")
|
||||
# password=$(printf "%s\n" "${password_files[@]}" | fzf --layout=reverse)
|
||||
|
||||
[[ -n $password ]] || exit
|
||||
|
||||
exec 3< <(pass show -c "$password" 2>&1)
|
||||
read <&3 MSG
|
||||
notify-send "Password copied." "$MSG"
|
||||
wait
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
#!/bin/bash
|
||||
source $HOME/.zshrc >/dev/null 2>/dev/null
|
||||
exec rofi -font "Roboto Mono 11" $@
|
|
@ -1,20 +0,0 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
SCREENSHOT=leanshot
|
||||
# choose some file to save it to
|
||||
FILENAME="$(date +%Y-%m-%d-%H:%M:%S).png"
|
||||
FILE="$HOME/Screenshots/$FILENAME"
|
||||
$SCREENSHOT $1 -o $FILE
|
||||
|
||||
# copy to clipboard
|
||||
XCLIP=/usr/bin/xclip
|
||||
$XCLIP -selection clipboard -t image/png -i $FILE
|
||||
notify-send "captured $FILENAME"
|
||||
|
||||
# upload it
|
||||
# url=$(ssh -vv -i $HOME/.ssh/id_rsa homelab $HOME/.local/bin/file-upload $FILENAME < $FILE 2> log)
|
||||
# url=${url%$'\n'}
|
||||
# $XCLIP -selection clipboard <<< "$url"
|
||||
# notify-send "uploaded $FILENAME"
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
#!/bin/bash
|
||||
# Performs system upgrade using topgrade
|
||||
# Then writes the time of last update into dest
|
||||
|
||||
dest=$HOME/.config/last-system-upgrade
|
||||
|
||||
topgrade --no-retry --verbose --yes
|
||||
echo $(date "+%s") > $dest
|
||||
|
|
@ -1,24 +0,0 @@
|
|||
#!/bin/bash
|
||||
# https://robertbasic.com/blog/toggle-a-vpn-connection/
|
||||
|
||||
VPN=$1
|
||||
|
||||
if [ -z "$VPN" ]
|
||||
then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
ACTIVE=`nmcli con show --active | grep "$VPN"`
|
||||
|
||||
if [ -z "$ACTIVE" ]
|
||||
then
|
||||
nmcli con up id "$VPN"
|
||||
notify-send "VPN $VPN" "Connected."
|
||||
else
|
||||
nmcli con down id "$VPN"
|
||||
notify-send "VPN $VPN" "Disconnected."
|
||||
fi
|
||||
|
||||
exit 0
|
||||
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
function checkUpdate() {
|
||||
lastUpdateFile=$HOME/.config/last-system-upgrade
|
||||
|
||||
if [ ! -f "$lastUpdateFile" ]; then
|
||||
echo "this system hasn't ever been updated using system-upgrade.sh"
|
||||
echo "run system-upgrade.sh now"
|
||||
return
|
||||
fi
|
||||
|
||||
lastUpdate=$(cat $lastUpdateFile)
|
||||
now=$(date "+%s")
|
||||
|
||||
if [[ $(( $now - $lastUpdate > 604800 )) -ne "0" ]]; then
|
||||
echo "this system hasn't been updated for over a week"
|
||||
echo "run system-upgrade.sh asap"
|
||||
return
|
||||
fi
|
||||
}
|
||||
|
||||
checkUpdate
|
||||
|
|
@ -1,2 +0,0 @@
|
|||
source_if_exists() { test -f $1 && source $1 }
|
||||
|
|
@ -1,10 +0,0 @@
|
|||
[Desktop Entry]
|
||||
Version=1.0
|
||||
Type=Application
|
||||
Name=CoqIDE Proof Assistant
|
||||
Comment=Graphical interface for the Coq proof assistant
|
||||
Exec=/usr/bin/env coqide
|
||||
Icon=coqide
|
||||
Terminal=false
|
||||
StartupNotify=false
|
||||
Categories=Development;Science;Math;IDE;GTK;
|
|
@ -1,6 +0,0 @@
|
|||
[Desktop Entry]
|
||||
Name=Onivim2
|
||||
Exec=Oni2
|
||||
Icon=Onivim2
|
||||
Type=Application
|
||||
Categories=Development;
|
|
@ -1,2 +0,0 @@
|
|||
#!/bin/bash
|
||||
exec hydroxide serve
|
|
@ -1,76 +0,0 @@
|
|||
# Contributor Covenant Code of Conduct
|
||||
|
||||
## Our Pledge
|
||||
|
||||
In the interest of fostering an open and welcoming environment, we as
|
||||
contributors and maintainers pledge to making participation in our project and
|
||||
our community a harassment-free experience for everyone, regardless of age, body
|
||||
size, disability, ethnicity, sex characteristics, gender identity and expression,
|
||||
level of experience, education, socio-economic status, nationality, personal
|
||||
appearance, race, religion, or sexual identity and orientation.
|
||||
|
||||
## Our Standards
|
||||
|
||||
Examples of behavior that contributes to creating a positive environment
|
||||
include:
|
||||
|
||||
* Using welcoming and inclusive language
|
||||
* Being respectful of differing viewpoints and experiences
|
||||
* Gracefully accepting constructive criticism
|
||||
* Focusing on what is best for the community
|
||||
* Showing empathy towards other community members
|
||||
|
||||
Examples of unacceptable behavior by participants include:
|
||||
|
||||
* The use of sexualized language or imagery and unwelcome sexual attention or
|
||||
advances
|
||||
* Trolling, insulting/derogatory comments, and personal or political attacks
|
||||
* Public or private harassment
|
||||
* Publishing others' private information, such as a physical or electronic
|
||||
address, without explicit permission
|
||||
* Other conduct which could reasonably be considered inappropriate in a
|
||||
professional setting
|
||||
|
||||
## Our Responsibilities
|
||||
|
||||
Project maintainers are responsible for clarifying the standards of acceptable
|
||||
behavior and are expected to take appropriate and fair corrective action in
|
||||
response to any instances of unacceptable behavior.
|
||||
|
||||
Project maintainers have the right and responsibility to remove, edit, or
|
||||
reject comments, commits, code, wiki edits, issues, and other contributions
|
||||
that are not aligned to this Code of Conduct, or to ban temporarily or
|
||||
permanently any contributor for other behaviors that they deem inappropriate,
|
||||
threatening, offensive, or harmful.
|
||||
|
||||
## Scope
|
||||
|
||||
This Code of Conduct applies within all project spaces, and it also applies when
|
||||
an individual is representing the project or its community in public spaces.
|
||||
Examples of representing a project or community include using an official
|
||||
project e-mail address, posting via an official social media account, or acting
|
||||
as an appointed representative at an online or offline event. Representation of
|
||||
a project may be further defined and clarified by project maintainers.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
||||
reported by contacting the project team at ohmyzsh@planetargon.com. All
|
||||
complaints will be reviewed and investigated and will result in a response that
|
||||
is deemed necessary and appropriate to the circumstances. The project team is
|
||||
obligated to maintain confidentiality with regard to the reporter of an incident.
|
||||
Further details of specific enforcement policies may be posted separately.
|
||||
|
||||
Project maintainers who do not follow or enforce the Code of Conduct in good
|
||||
faith may face temporary or permanent repercussions as determined by other
|
||||
members of the project's leadership.
|
||||
|
||||
## Attribution
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
||||
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html
|
||||
|
||||
[homepage]: https://www.contributor-covenant.org
|
||||
|
||||
For answers to common questions about this code of conduct, see
|
||||
https://www.contributor-covenant.org/faq
|
|
@ -1,125 +0,0 @@
|
|||
# CONTRIBUTING GUIDELINES
|
||||
|
||||
Oh-My-Zsh is a community-driven project. Contribution is welcome, encouraged, and appreciated.
|
||||
It is also essential for the development of the project.
|
||||
|
||||
First, please take a moment to review our [code of conduct](CODE_OF_CONDUCT.md).
|
||||
|
||||
These guidelines are an attempt at better addressing the huge amount of pending
|
||||
issues and pull requests. Please read them closely.
|
||||
|
||||
Foremost, be so kind as to [search](#use-the-search-luke). This ensures any contribution
|
||||
you would make is not already covered.
|
||||
|
||||
* [Issues](#reporting-issues)
|
||||
* [You have a problem](#you-have-a-problem)
|
||||
* [You have a suggestion](#you-have-a-suggestion)
|
||||
* [Pull Requests](#submitting-pull-requests)
|
||||
* [Getting started](#getting-started)
|
||||
* [You have a solution](#you-have-a-solution)
|
||||
* [You have an addition](#you-have-an-addition)
|
||||
* [Information sources (_aka_ search)](#use-the-search-luke)
|
||||
|
||||
**BONUS:** [Volunteering](#you-have-spare-time-to-volunteer)
|
||||
|
||||
## Reporting Issues
|
||||
|
||||
### You have a problem
|
||||
|
||||
Please be so kind as to [search](#use-the-search-luke) for any open issue already covering
|
||||
your problem.
|
||||
|
||||
If you find one, comment on it so we can know there are more people experiencing it.
|
||||
|
||||
If not, look at the [Troubleshooting](https://github.com/ohmyzsh/ohmyzsh/wiki/Troubleshooting)
|
||||
page for instructions on how to gather data to better debug your problem.
|
||||
|
||||
Then, you can go ahead and create an issue with as much detail as you can provide.
|
||||
It should include the data gathered as indicated above, along with:
|
||||
|
||||
1. How to reproduce the problem
|
||||
2. What the correct behavior should be
|
||||
3. What the actual behavior is
|
||||
|
||||
Please copy to anyone relevant (_eg_ plugin maintainers) by mentioning their GitHub handle
|
||||
(starting with `@`) in your message.
|
||||
|
||||
We will do our very best to help you.
|
||||
|
||||
### You have a suggestion
|
||||
|
||||
Please be so kind as to [search](#use-the-search-luke) for any open issue already covering
|
||||
your suggestion.
|
||||
|
||||
If you find one, comment on it so we can know there are more people supporting it.
|
||||
|
||||
If not, you can go ahead and create an issue. Please copy to anyone relevant (_eg_ plugin
|
||||
maintainers) by mentioning their GitHub handle (starting with `@`) in your message.
|
||||
|
||||
## Submitting Pull Requests
|
||||
|
||||
### Getting started
|
||||
|
||||
You should be familiar with the basics of
|
||||
[contributing on GitHub](https://help.github.com/articles/using-pull-requests) and have a fork
|
||||
[properly set up](https://github.com/ohmyzsh/ohmyzsh/wiki/Contribution-Technical-Practices).
|
||||
|
||||
You MUST always create PRs with _a dedicated branch_ based on the latest upstream tree.
|
||||
|
||||
If you create your own PR, please make sure you do it right. Also be so kind as to reference
|
||||
any issue that would be solved in the PR description body,
|
||||
[for instance](https://help.github.com/articles/closing-issues-via-commit-messages/)
|
||||
_"Fixes #XXXX"_ for issue number XXXX.
|
||||
|
||||
### You have a solution
|
||||
|
||||
Please be so kind as to [search](#use-the-search-luke) for any open issue already covering
|
||||
your [problem](#you-have-a-problem), and any pending/merged/rejected PR covering your solution.
|
||||
|
||||
If the solution is already reported, try it out and +1 the pull request if the
|
||||
solution works ok. On the other hand, if you think your solution is better, post
|
||||
it with a reference to the other one so we can have both solutions to compare.
|
||||
|
||||
If not, then go ahead and submit a PR. Please copy to anyone relevant (e.g. plugin
|
||||
maintainers) by mentioning their GitHub handle (starting with `@`) in your message.
|
||||
|
||||
### You have an addition
|
||||
|
||||
Please [do not](https://github.com/ohmyzsh/ohmyzsh/wiki/Themes#dont-send-us-your-theme-for-now)
|
||||
send themes for now.
|
||||
|
||||
Please be so kind as to [search](#use-the-search-luke) for any pending, merged or rejected Pull Requests
|
||||
covering or related to what you want to add.
|
||||
|
||||
If you find one, try it out and work with the author on a common solution.
|
||||
|
||||
If not, then go ahead and submit a PR. Please copy to anyone relevant (_eg_ plugin
|
||||
maintainers) by mentioning their GitHub handle (starting with `@`) in your message.
|
||||
|
||||
For any extensive change, _eg_ a new plugin, you will have to find testers to +1 your PR.
|
||||
|
||||
----
|
||||
|
||||
## Use the Search, Luke
|
||||
|
||||
_May the Force (of past experiences) be with you_
|
||||
|
||||
GitHub offers [many search features](https://help.github.com/articles/searching-github/)
|
||||
to help you check whether a similar contribution to yours already exists. Please search
|
||||
before making any contribution, it avoids duplicates and eases maintenance. Trust me,
|
||||
that works 90% of the time.
|
||||
|
||||
You can also take a look at the [FAQ](https://github.com/ohmyzsh/ohmyzsh/wiki/FAQ)
|
||||
to be sure your contribution has not already come up.
|
||||
|
||||
If all fails, your thing has probably not been reported yet, so you can go ahead
|
||||
and [create an issue](#reporting-issues) or [submit a PR](#submitting-pull-requests).
|
||||
|
||||
----
|
||||
|
||||
### You have spare time to volunteer
|
||||
|
||||
Very nice!! :)
|
||||
|
||||
Please have a look at the [Volunteer](https://github.com/ohmyzsh/ohmyzsh/wiki/Volunteers)
|
||||
page for instructions on where to start and more.
|
|
@ -1,21 +0,0 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2009-2020 Robby Russell and contributors (https://github.com/ohmyzsh/ohmyzsh/contributors)
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
|
@ -1,314 +0,0 @@
|
|||
<p align="center"><img src="https://s3.amazonaws.com/ohmyzsh/oh-my-zsh-logo.png" alt="Oh My Zsh"></p>
|
||||
|
||||
Oh My Zsh is an open source, community-driven framework for managing your [zsh](https://www.zsh.org/) configuration.
|
||||
|
||||
Sounds boring. Let's try again.
|
||||
|
||||
**Oh My Zsh will not make you a 10x developer...but you may feel like one.**
|
||||
|
||||
Once installed, your terminal shell will become the talk of the town _or your money back!_ With each keystroke in your command prompt, you'll take advantage of the hundreds of powerful plugins and beautiful themes. Strangers will come up to you in cafés and ask you, _"that is amazing! are you some sort of genius?"_
|
||||
|
||||
Finally, you'll begin to get the sort of attention that you have always felt you deserved. ...or maybe you'll use the time that you're saving to start flossing more often. 😬
|
||||
|
||||
To learn more, visit [ohmyz.sh](https://ohmyz.sh), follow [@ohmyzsh](https://twitter.com/ohmyzsh) on Twitter, and join us on [Discord](https://discord.gg/ohmyzsh).
|
||||
|
||||
[![CI](https://github.com/ohmyzsh/ohmyzsh/workflows/CI/badge.svg)](https://github.com/ohmyzsh/ohmyzsh/actions?query=workflow%3ACI)
|
||||
[![Follow @ohmyzsh](https://img.shields.io/twitter/follow/ohmyzsh?label=Follow+@ohmyzsh&style=flat)](https://twitter.com/intent/follow?screen_name=ohmyzsh)
|
||||
[![Discord server](https://img.shields.io/discord/642496866407284746)](https://discord.gg/ohmyzsh)
|
||||
[![Gitpod ready](https://img.shields.io/badge/Gitpod-ready-blue?logo=gitpod)](https://gitpod.io/#https://github.com/ohmyzsh/ohmyzsh)
|
||||
|
||||
## Getting Started
|
||||
|
||||
### Prerequisites
|
||||
|
||||
- A Unix-like operating system: macOS, Linux, BSD. On Windows: WSL2 is preferred, but cygwin or msys also mostly work.
|
||||
- [Zsh](https://www.zsh.org) should be installed (v4.3.9 or more recent is fine but we prefer 5.0.8 and newer). If not pre-installed (run `zsh --version` to confirm), check the following wiki instructions here: [Installing ZSH](https://github.com/ohmyzsh/ohmyzsh/wiki/Installing-ZSH)
|
||||
- `curl` or `wget` should be installed
|
||||
- `git` should be installed (recommended v2.4.11 or higher)
|
||||
|
||||
### Basic Installation
|
||||
|
||||
Oh My Zsh is installed by running one of the following commands in your terminal. You can install this via the command-line with either `curl`, `wget` or another similar tool.
|
||||
|
||||
| Method | Command |
|
||||
|:----------|:--------------------------------------------------------------------------------------------------|
|
||||
| **curl** | `sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"` |
|
||||
| **wget** | `sh -c "$(wget -O- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"` |
|
||||
| **fetch** | `sh -c "$(fetch -o - https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"` |
|
||||
|
||||
#### Manual inspection
|
||||
|
||||
It's a good idea to inspect the install script from projects you don't yet know. You can do
|
||||
that by downloading the install script first, looking through it so everything looks normal,
|
||||
then running it:
|
||||
|
||||
```shell
|
||||
wget https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh
|
||||
sh install.sh
|
||||
```
|
||||
|
||||
## Using Oh My Zsh
|
||||
|
||||
### Plugins
|
||||
|
||||
Oh My Zsh comes with a shitload of plugins for you to take advantage of. You can take a look in the [plugins](https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins) directory and/or the [wiki](https://github.com/ohmyzsh/ohmyzsh/wiki/Plugins) to see what's currently available.
|
||||
|
||||
#### Enabling Plugins
|
||||
|
||||
Once you spot a plugin (or several) that you'd like to use with Oh My Zsh, you'll need to enable them in the `.zshrc` file. You'll find the zshrc file in your `$HOME` directory. Open it with your favorite text editor and you'll see a spot to list all the plugins you want to load.
|
||||
|
||||
```shell
|
||||
vi ~/.zshrc
|
||||
```
|
||||
|
||||
For example, this might begin to look like this:
|
||||
|
||||
```shell
|
||||
plugins=(
|
||||
git
|
||||
bundler
|
||||
dotenv
|
||||
osx
|
||||
rake
|
||||
rbenv
|
||||
ruby
|
||||
)
|
||||
```
|
||||
|
||||
_Note that the plugins are separated by whitespace (spaces, tabs, new lines...). **Do not** use commas between them or it will break._
|
||||
|
||||
#### Using Plugins
|
||||
|
||||
Each plugin includes a __README__, documenting it. This README should show the aliases (if the plugin adds any) and extra goodies that are included in that particular plugin.
|
||||
|
||||
### Themes
|
||||
|
||||
We'll admit it. Early in the Oh My Zsh world, we may have gotten a bit too theme happy. We have over one hundred and fifty themes now bundled. Most of them have [screenshots](https://github.com/ohmyzsh/ohmyzsh/wiki/Themes) on the wiki (We are working on updating this!). Check them out!
|
||||
|
||||
#### Selecting a Theme
|
||||
|
||||
_Robby's theme is the default one. It's not the fanciest one. It's not the simplest one. It's just the right one (for him)._
|
||||
|
||||
Once you find a theme that you'd like to use, you will need to edit the `~/.zshrc` file. You'll see an environment variable (all caps) in there that looks like:
|
||||
|
||||
```shell
|
||||
ZSH_THEME="robbyrussell"
|
||||
```
|
||||
|
||||
To use a different theme, simply change the value to match the name of your desired theme. For example:
|
||||
|
||||
```shell
|
||||
ZSH_THEME="agnoster" # (this is one of the fancy ones)
|
||||
# see https://github.com/ohmyzsh/ohmyzsh/wiki/Themes#agnoster
|
||||
```
|
||||
|
||||
_Note: many themes require installing the [Powerline Fonts](https://github.com/powerline/fonts) in order to render properly._
|
||||
|
||||
Open up a new terminal window and your prompt should look something like this:
|
||||
|
||||
![Agnoster theme](https://cloud.githubusercontent.com/assets/2618447/6316862/70f58fb6-ba03-11e4-82c9-c083bf9a6574.png)
|
||||
|
||||
In case you did not find a suitable theme for your needs, please have a look at the wiki for [more of them](https://github.com/ohmyzsh/ohmyzsh/wiki/External-themes).
|
||||
|
||||
If you're feeling feisty, you can let the computer select one randomly for you each time you open a new terminal window.
|
||||
|
||||
```shell
|
||||
ZSH_THEME="random" # (...please let it be pie... please be some pie..)
|
||||
```
|
||||
|
||||
And if you want to pick random theme from a list of your favorite themes:
|
||||
|
||||
```shell
|
||||
ZSH_THEME_RANDOM_CANDIDATES=(
|
||||
"robbyrussell"
|
||||
"agnoster"
|
||||
)
|
||||
```
|
||||
|
||||
If you only know which themes you don't like, you can add them similarly to an ignored list:
|
||||
|
||||
```shell
|
||||
ZSH_THEME_RANDOM_IGNORED=(pygmalion tjkirch_mod)
|
||||
```
|
||||
|
||||
### FAQ
|
||||
|
||||
If you have some more questions or issues, you might find a solution in our [FAQ](https://github.com/ohmyzsh/ohmyzsh/wiki/FAQ).
|
||||
|
||||
## Advanced Topics
|
||||
|
||||
If you're the type that likes to get their hands dirty, these sections might resonate.
|
||||
|
||||
### Advanced Installation
|
||||
|
||||
Some users may want to manually install Oh My Zsh, or change the default path or other settings that
|
||||
the installer accepts (these settings are also documented at the top of the install script).
|
||||
|
||||
#### Custom Directory
|
||||
|
||||
The default location is `~/.oh-my-zsh` (hidden in your home directory, you can access it with `cd ~/.oh-my-zsh`)
|
||||
|
||||
If you'd like to change the install directory with the `ZSH` environment variable, either by running
|
||||
`export ZSH=/your/path` before installing, or by setting it before the end of the install pipeline
|
||||
like this:
|
||||
|
||||
```shell
|
||||
ZSH="$HOME/.dotfiles/oh-my-zsh" sh install.sh
|
||||
```
|
||||
|
||||
#### Unattended install
|
||||
|
||||
If you're running the Oh My Zsh install script as part of an automated install, you can pass the
|
||||
flag `--unattended` to the `install.sh` script. This will have the effect of not trying to change
|
||||
the default shell, and also won't run `zsh` when the installation has finished.
|
||||
|
||||
```shell
|
||||
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" "" --unattended
|
||||
```
|
||||
|
||||
#### Installing from a forked repository
|
||||
|
||||
The install script also accepts these variables to allow installation of a different repository:
|
||||
|
||||
- `REPO` (default: `ohmyzsh/ohmyzsh`): this takes the form of `owner/repository`. If you set
|
||||
this variable, the installer will look for a repository at `https://github.com/{owner}/{repository}`.
|
||||
|
||||
- `REMOTE` (default: `https://github.com/${REPO}.git`): this is the full URL of the git repository
|
||||
clone. You can use this setting if you want to install from a fork that is not on GitHub (GitLab,
|
||||
Bitbucket...) or if you want to clone with SSH instead of HTTPS (`git@github.com:user/project.git`).
|
||||
|
||||
_NOTE: it's incompatible with setting the `REPO` variable. This setting will take precedence._
|
||||
|
||||
- `BRANCH` (default: `master`): you can use this setting if you want to change the default branch to be
|
||||
checked out when cloning the repository. This might be useful for testing a Pull Request, or if you
|
||||
want to use a branch other than `master`.
|
||||
|
||||
For example:
|
||||
|
||||
```shell
|
||||
REPO=apjanke/oh-my-zsh BRANCH=edge sh install.sh
|
||||
```
|
||||
|
||||
#### Manual Installation
|
||||
|
||||
##### 1. Clone the repository
|
||||
|
||||
```shell
|
||||
git clone https://github.com/ohmyzsh/ohmyzsh.git ~/.oh-my-zsh
|
||||
```
|
||||
|
||||
##### 2. *Optionally*, backup your existing `~/.zshrc` file
|
||||
|
||||
```shell
|
||||
cp ~/.zshrc ~/.zshrc.orig
|
||||
```
|
||||
|
||||
##### 3. Create a new zsh configuration file
|
||||
|
||||
You can create a new zsh config file by copying the template that we have included for you.
|
||||
|
||||
```shell
|
||||
cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc
|
||||
```
|
||||
|
||||
##### 4. Change your default shell
|
||||
|
||||
```shell
|
||||
chsh -s $(which zsh)
|
||||
```
|
||||
|
||||
You must log out from your user session and log back in to see this change.
|
||||
|
||||
##### 5. Initialize your new zsh configuration
|
||||
|
||||
Once you open up a new terminal window, it should load zsh with Oh My Zsh's configuration.
|
||||
|
||||
### Installation Problems
|
||||
|
||||
If you have any hiccups installing, here are a few common fixes.
|
||||
|
||||
- You _might_ need to modify your `PATH` in `~/.zshrc` if you're not able to find some commands after
|
||||
switching to `oh-my-zsh`.
|
||||
- If you installed manually or changed the install location, check the `ZSH` environment variable in
|
||||
`~/.zshrc`.
|
||||
|
||||
### Custom Plugins and Themes
|
||||
|
||||
If you want to override any of the default behaviors, just add a new file (ending in `.zsh`) in the `custom/` directory.
|
||||
|
||||
If you have many functions that go well together, you can put them as a `XYZ.plugin.zsh` file in the `custom/plugins/` directory and then enable this plugin.
|
||||
|
||||
If you would like to override the functionality of a plugin distributed with Oh My Zsh, create a plugin of the same name in the `custom/plugins/` directory and it will be loaded instead of the one in `plugins/`.
|
||||
|
||||
## Getting Updates
|
||||
|
||||
By default, you will be prompted to check for upgrades every few weeks. If you would like `oh-my-zsh` to automatically upgrade itself without prompting you, set the following in your `~/.zshrc`:
|
||||
|
||||
```shell
|
||||
DISABLE_UPDATE_PROMPT=true
|
||||
```
|
||||
|
||||
To disable automatic upgrades, set the following in your `~/.zshrc`:
|
||||
|
||||
```shell
|
||||
DISABLE_AUTO_UPDATE=true
|
||||
```
|
||||
|
||||
### Manual Updates
|
||||
|
||||
If you'd like to upgrade at any point in time (maybe someone just released a new plugin and you don't want to wait a week?) you just need to run:
|
||||
|
||||
```shell
|
||||
omz update
|
||||
```
|
||||
|
||||
Magic! 🎉
|
||||
|
||||
## Uninstalling Oh My Zsh
|
||||
|
||||
Oh My Zsh isn't for everyone. We'll miss you, but we want to make this an easy breakup.
|
||||
|
||||
If you want to uninstall `oh-my-zsh`, just run `uninstall_oh_my_zsh` from the command-line. It will remove itself and revert your previous `bash` or `zsh` configuration.
|
||||
|
||||
## How do I contribute to Oh My Zsh?
|
||||
|
||||
Before you participate in our delightful community, please read the [code of conduct](CODE_OF_CONDUCT.md).
|
||||
|
||||
I'm far from being a [Zsh](https://www.zsh.org/) expert and suspect there are many ways to improve – if you have ideas on how to make the configuration easier to maintain (and faster), don't hesitate to fork and send pull requests!
|
||||
|
||||
We also need people to test out pull-requests. So take a look through [the open issues](https://github.com/ohmyzsh/ohmyzsh/issues) and help where you can.
|
||||
|
||||
See [Contributing](CONTRIBUTING.md) for more details.
|
||||
|
||||
### Do NOT send us themes
|
||||
|
||||
We have (more than) enough themes for the time being. Please add your theme to the [external themes](https://github.com/ohmyzsh/ohmyzsh/wiki/External-themes) wiki page.
|
||||
|
||||
## Contributors
|
||||
|
||||
Oh My Zsh has a vibrant community of happy users and delightful contributors. Without all the time and help from our contributors, it wouldn't be so awesome.
|
||||
|
||||
Thank you so much!
|
||||
|
||||
## Follow Us
|
||||
|
||||
We're on social media:
|
||||
|
||||
- [@ohmyzsh](https://twitter.com/ohmyzsh) on Twitter. You should follow it.
|
||||
- [FaceBook](https://www.facebook.com/Oh-My-Zsh-296616263819290/) poke us.
|
||||
- [Instagram](https://www.instagram.com/_ohmyzsh/) tag us in your post showing Oh My Zsh!
|
||||
- [Discord](https://discord.gg/ohmyzsh) to chat with us!
|
||||
|
||||
## Merchandise
|
||||
|
||||
We have [stickers, shirts, and coffee mugs available](https://shop.planetargon.com/collections/oh-my-zsh?utm_source=github) for you to show off your love of Oh My Zsh. Again, you will become the talk of the town!
|
||||
|
||||
## License
|
||||
|
||||
Oh My Zsh is released under the [MIT license](LICENSE.txt).
|
||||
|
||||
## About Planet Argon
|
||||
|
||||
![Planet Argon](https://pa-github-assets.s3.amazonaws.com/PARGON_logo_digital_COL-small.jpg)
|
||||
|
||||
Oh My Zsh was started by the team at [Planet Argon](https://www.planetargon.com/?utm_source=github), a [Ruby on Rails development agency](https://www.planetargon.com/skills/ruby-on-rails-development?utm_source=github). Check out our [other open source projects](https://www.planetargon.com/open-source?utm_source=github).
|
0
dot_oh-my-zsh/cache/empty_dot_gitkeep
vendored
0
dot_oh-my-zsh/cache/empty_dot_gitkeep
vendored
|
@ -1,10 +0,0 @@
|
|||
# You can put files here to add functionality separated per file, which
|
||||
# will be ignored by git.
|
||||
# Files on the custom/ directory will be automatically loaded by the init
|
||||
# script, in alphabetical order.
|
||||
|
||||
# For example: add yourself some shortcuts to projects you often work on.
|
||||
#
|
||||
# brainstormr=~/Projects/development/planetargon/brainstormr
|
||||
# cd $brainstormr
|
||||
#
|
|
@ -1,2 +0,0 @@
|
|||
# Add your own custom plugins in the custom/plugins directory. Plugins placed
|
||||
# here will override ones with the same name in the main plugins directory.
|
|
@ -1,23 +0,0 @@
|
|||
Copyright (c) 2010-2020 zsh-syntax-highlighting contributors
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
and the following disclaimer.
|
||||
* Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
with the distribution.
|
||||
* Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
may be used to endorse or promote products derived from this software without specific prior
|
||||
written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
@ -1,99 +0,0 @@
|
|||
Hacking on zsh-syntax-highlighting itself
|
||||
=========================================
|
||||
|
||||
This document includes information for people working on z-sy-h itself: on the
|
||||
core driver (`zsh-syntax-highlighting.zsh`), on the highlighters in the
|
||||
distribution, and on the test suite. It does not target third-party
|
||||
highlighter authors (although they may find it an interesting read).
|
||||
|
||||
The `main` highlighter
|
||||
----------------------
|
||||
|
||||
The following function `pz` is useful when working on the `main` highlighting:
|
||||
|
||||
```zsh
|
||||
pq() {
|
||||
(( $#argv )) || return 0
|
||||
print -r -l -- ${(qqqq)argv}
|
||||
}
|
||||
pz() {
|
||||
local arg
|
||||
for arg; do
|
||||
pq ${(z)arg}
|
||||
done
|
||||
}
|
||||
```
|
||||
|
||||
It prints, for each argument, its token breakdown, similar to how the main
|
||||
loop of the `main` highlighter sees it.
|
||||
|
||||
Testing the `brackets` highlighter
|
||||
----------------------------------
|
||||
|
||||
Since the test harness empties `ZSH_HIGHLIGHT_STYLES` and the `brackets`
|
||||
highlighter interrogates `ZSH_HIGHLIGHT_STYLES` to determine how to highlight,
|
||||
tests must set the `bracket-level-#` keys themselves. For example:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
|
||||
BUFFER='echo ({x})'
|
||||
|
||||
expected_region_highlight=(
|
||||
"6 6 bracket-level-1" # (
|
||||
"7 7 bracket-level-2" # {
|
||||
"9 9 bracket-level-2" # }
|
||||
"10 10 bracket-level-1" # )
|
||||
)
|
||||
```
|
||||
|
||||
Testing the `pattern` and `regexp` highlighters
|
||||
-----------------------------------------------
|
||||
|
||||
Because the `pattern` and `regexp` highlighters modifies `region_highlight`
|
||||
directly instead of using `_zsh_highlight_add_highlight`, the test harness
|
||||
cannot get the `ZSH_HIGHLIGHT_STYLES` keys. Therefore, when writing tests, use
|
||||
the style itself as third word (cf. the
|
||||
[documentation for `expected_region_highlight`](docs/highlighters.md)). For example:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_PATTERNS+=('rm -rf *' 'fg=white,bold,bg=red')
|
||||
|
||||
BUFFER='rm -rf /'
|
||||
|
||||
expected_region_highlight=(
|
||||
"1 8 fg=white,bold,bg=red" # rm -rf /
|
||||
)
|
||||
```
|
||||
|
||||
Memos and commas
|
||||
----------------
|
||||
|
||||
We append to `region_highlight` as follows:
|
||||
|
||||
|
||||
```zsh
|
||||
region_highlight+=("$start $end $spec, memo=zsh-syntax-highlighting")
|
||||
```
|
||||
|
||||
That comma is required to cause zsh 5.8 and older to ignore the memo without
|
||||
ignoring the `$spec`. It's a hack, but given that no further 5.8.x patch
|
||||
releases are planned, it's been deemed acceptable. See issue #418 and the
|
||||
cross-referenced issues.
|
||||
|
||||
|
||||
Miscellany
|
||||
----------
|
||||
|
||||
If you work on the driver (`zsh-syntax-highlighting.zsh`), you may find the following zstyle useful:
|
||||
|
||||
```zsh
|
||||
zstyle ':completion:*:*:*:*:globbed-files' ignored-patterns {'*/',}zsh-syntax-highlighting.plugin.zsh
|
||||
```
|
||||
|
||||
IRC channel
|
||||
-----------
|
||||
|
||||
We're on #zsh-syntax-highlighting on freenode.
|
||||
|
|
@ -1,131 +0,0 @@
|
|||
How to install
|
||||
--------------
|
||||
|
||||
### Using packages
|
||||
|
||||
* Arch Linux: [community/zsh-syntax-highlighting][arch-package] / [AUR/zsh-syntax-highlighting-git][AUR-package]
|
||||
* Debian: `zsh-syntax-highlighting` package [in `stretch`][debian-package] (or in [OBS repository][obs-repository])
|
||||
* Fedora: [zsh-syntax-highlighting package][fedora-package-alt] in Fedora 24+ (or in [OBS repository][obs-repository])
|
||||
* FreeBSD: `pkg install zsh-syntax-highlighting` (port name: [`shells/zsh-syntax-highlighting`][freebsd-port])
|
||||
* Gentoo: [app-shells/zsh-syntax-highlighting][gentoo-repository]
|
||||
* Mac OS X / Homebrew: [brew install zsh-syntax-highlighting][brew-package]
|
||||
* NetBSD: `pkg_add zsh-syntax-highlighting` (port name: [`shells/zsh-syntax-highlighting`][netbsd-port])
|
||||
* OpenBSD: `pkg_add zsh-syntax-highlighting` (port name: [`shells/zsh-syntax-highlighting`][openbsd-port])
|
||||
* openSUSE / SLE: `zsh-syntax-highlighting` package in [OBS repository][obs-repository]
|
||||
* RHEL / CentOS / Scientific Linux: `zsh-syntax-highlighting` package in [OBS repository][obs-repository]
|
||||
* Ubuntu: `zsh-syntax-highlighting` package [in Xenial][ubuntu-package] (or in [OBS repository][obs-repository])
|
||||
* Void Linux: `zsh-syntax-highlighting package` [in XBPS][void-package]
|
||||
|
||||
[arch-package]: https://www.archlinux.org/packages/zsh-syntax-highlighting
|
||||
[AUR-package]: https://aur.archlinux.org/packages/zsh-syntax-highlighting-git
|
||||
[brew-package]: https://github.com/Homebrew/homebrew-core/blob/master/Formula/zsh-syntax-highlighting.rb
|
||||
[debian-package]: https://packages.debian.org/zsh-syntax-highlighting
|
||||
[fedora-package]: https://apps.fedoraproject.org/packages/zsh-syntax-highlighting
|
||||
[fedora-package-alt]: https://bodhi.fedoraproject.org/updates/?packages=zsh-syntax-highlighting
|
||||
[freebsd-port]: http://www.freshports.org/textproc/zsh-syntax-highlighting/
|
||||
[gentoo-repository]: https://packages.gentoo.org/packages/app-shells/zsh-syntax-highlighting
|
||||
[netbsd-port]: http://cvsweb.netbsd.org/bsdweb.cgi/pkgsrc/shells/zsh-syntax-highlighting/
|
||||
[obs-repository]: https://software.opensuse.org/download.html?project=shells%3Azsh-users%3Azsh-syntax-highlighting&package=zsh-syntax-highlighting
|
||||
[openbsd-port]: https://cvsweb.openbsd.org/ports/shells/zsh-syntax-highlighting/
|
||||
[ubuntu-package]: https://launchpad.net/ubuntu/+source/zsh-syntax-highlighting
|
||||
[void-package]: https://github.com/void-linux/void-packages/tree/master/srcpkgs/zsh-syntax-highlighting
|
||||
|
||||
See also [repology's cross-distro index](https://repology.org/metapackage/zsh-syntax-highlighting/versions)
|
||||
|
||||
|
||||
### In your ~/.zshrc
|
||||
|
||||
Simply clone this repository and source the script:
|
||||
|
||||
```zsh
|
||||
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git
|
||||
echo "source ${(q-)PWD}/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" >> ${ZDOTDIR:-$HOME}/.zshrc
|
||||
```
|
||||
|
||||
Then, enable syntax highlighting in the current interactive shell:
|
||||
|
||||
```zsh
|
||||
source ./zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
||||
```
|
||||
|
||||
If `git` is not installed, download and extract a snapshot of the latest
|
||||
development tree from:
|
||||
|
||||
```
|
||||
https://github.com/zsh-users/zsh-syntax-highlighting/archive/master.tar.gz
|
||||
```
|
||||
|
||||
Note the `source` command must be **at the end** of `~/.zshrc`.
|
||||
|
||||
|
||||
### With a plugin manager
|
||||
|
||||
Note that `zsh-syntax-highlighting` must be the last plugin sourced.
|
||||
|
||||
The zsh-syntax-highlighting authors recommend manual installation over the use
|
||||
of a framework or plugin manager.
|
||||
|
||||
This list is incomplete as there are too many
|
||||
[frameworks / plugin managers][framework-list] to list them all here.
|
||||
|
||||
[framework-list]: https://github.com/unixorn/awesome-zsh-plugins#frameworks
|
||||
|
||||
#### [Antigen](https://github.com/zsh-users/antigen)
|
||||
|
||||
Add `antigen bundle zsh-users/zsh-syntax-highlighting` as the last bundle in
|
||||
your `.zshrc`.
|
||||
|
||||
#### [Oh-my-zsh](https://github.com/robbyrussell/oh-my-zsh)
|
||||
|
||||
1. Clone this repository in oh-my-zsh's plugins directory:
|
||||
|
||||
```zsh
|
||||
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
|
||||
```
|
||||
|
||||
2. Activate the plugin in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
plugins=( [plugins...] zsh-syntax-highlighting)
|
||||
```
|
||||
|
||||
3. Restart zsh (such as by opening a new instance of your terminal emulator).
|
||||
|
||||
#### [Prezto](https://github.com/sorin-ionescu/prezto)
|
||||
|
||||
Zsh-syntax-highlighting is included with Prezto. See the
|
||||
[Prezto documentation][prezto-docs] to enable and configure highlighters.
|
||||
|
||||
[prezto-docs]: https://github.com/sorin-ionescu/prezto/tree/master/modules/syntax-highlighting
|
||||
|
||||
#### [zgen](https://github.com/tarjoilija/zgen)
|
||||
|
||||
Add `zgen load zsh-users/zsh-syntax-highlighting` to the end of your `.zshrc`.
|
||||
|
||||
#### [zplug](https://github.com/zplug/zplug)
|
||||
|
||||
Add `zplug "zsh-users/zsh-syntax-highlighting", defer:2` to your `.zshrc`.
|
||||
|
||||
#### [zplugin](https://github.com/psprint/zplugin)
|
||||
|
||||
Add `zplugin load zsh-users/zsh-syntax-highlighting` to the end of your
|
||||
`.zshrc`.
|
||||
|
||||
|
||||
### System-wide installation
|
||||
|
||||
Any of the above methods is suitable for a single-user installation,
|
||||
which requires no special privileges. If, however, you desire to install
|
||||
zsh-syntax-highlighting system-wide, you may do so by running
|
||||
|
||||
```zsh
|
||||
make install
|
||||
```
|
||||
|
||||
and directing your users to add
|
||||
|
||||
```zsh
|
||||
source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
|
||||
```
|
||||
|
||||
to their `.zshrc`s.
|
|
@ -1,64 +0,0 @@
|
|||
NAME=zsh-syntax-highlighting
|
||||
|
||||
INSTALL?=install -c
|
||||
PREFIX?=/usr/local
|
||||
SHARE_DIR?=$(DESTDIR)$(PREFIX)/share/$(NAME)
|
||||
DOC_DIR?=$(DESTDIR)$(PREFIX)/share/doc/$(NAME)
|
||||
ZSH?=zsh # zsh binary to run tests with
|
||||
|
||||
all:
|
||||
cd docs && \
|
||||
cp highlighters.md all.md && \
|
||||
printf '\n\nIndividual highlighters documentation\n=====================================' >> all.md && \
|
||||
for doc in highlighters/*.md; do printf '\n\n'; cat "$$doc"; done >> all.md
|
||||
|
||||
install: all
|
||||
$(INSTALL) -d $(SHARE_DIR)
|
||||
$(INSTALL) -d $(DOC_DIR)
|
||||
cp .version zsh-syntax-highlighting.zsh $(SHARE_DIR)
|
||||
cp COPYING.md README.md changelog.md $(DOC_DIR)
|
||||
sed -e '1s/ .*//' -e '/^\[build-status-[a-z]*\]: /d' < README.md > $(DOC_DIR)/README.md
|
||||
if [ x"true" = x"`git rev-parse --is-inside-work-tree 2>/dev/null`" ]; then \
|
||||
git rev-parse HEAD; \
|
||||
else \
|
||||
cat .revision-hash; \
|
||||
fi > $(SHARE_DIR)/.revision-hash
|
||||
:
|
||||
# The [ -e ] check below is to because sh evaluates this with (the moral
|
||||
# equivalent of) NONOMATCH in effect, and highlighters/*.zsh has no matches.
|
||||
for dirname in highlighters highlighters/*/ ; do \
|
||||
$(INSTALL) -d $(SHARE_DIR)/"$$dirname"; \
|
||||
for fname in "$$dirname"/*.zsh ; do [ -e "$$fname" ] && cp "$$fname" $(SHARE_DIR)"/$$dirname"; done; \
|
||||
done
|
||||
cp -R docs/* $(DOC_DIR)
|
||||
|
||||
clean:
|
||||
rm -f docs/all.md
|
||||
|
||||
test:
|
||||
@$(ZSH) -fc 'echo ZSH_PATCHLEVEL=$$ZSH_PATCHLEVEL'
|
||||
@result=0; \
|
||||
for test in highlighters/*; do \
|
||||
if [ -d $$test/test-data ]; then \
|
||||
echo "Running test $${test##*/}"; \
|
||||
env -i QUIET=$$QUIET $${TERM:+"TERM=$$TERM"} $(ZSH) -f tests/test-highlighting.zsh "$${test##*/}"; \
|
||||
: $$(( result |= $$? )); \
|
||||
fi \
|
||||
done; \
|
||||
exit $$result
|
||||
|
||||
quiet-test:
|
||||
$(MAKE) test QUIET=y
|
||||
|
||||
perf:
|
||||
@result=0; \
|
||||
for test in highlighters/*; do \
|
||||
if [ -d $$test/test-data ]; then \
|
||||
echo "Running test $${test##*/}"; \
|
||||
$(ZSH) -f tests/test-perfs.zsh "$${test##*/}"; \
|
||||
: $$(( result |= $$? )); \
|
||||
fi \
|
||||
done; \
|
||||
exit $$result
|
||||
|
||||
.PHONY: all install clean test perf
|
|
@ -1,97 +0,0 @@
|
|||
zsh-syntax-highlighting [![Build Status][build-status-image]][build-status-travis]
|
||||
=======================
|
||||
|
||||
**[Fish shell][fish]-like syntax highlighting for [Zsh][zsh].**
|
||||
|
||||
*Requirements: zsh 4.3.11+.*
|
||||
|
||||
[fish]: http://www.fishshell.com/
|
||||
[zsh]: http://www.zsh.org/
|
||||
|
||||
This package provides syntax highlighting for the shell zsh. It enables
|
||||
highlighting of commands whilst they are typed at a zsh prompt into an
|
||||
interactive terminal. This helps in reviewing commands before running
|
||||
them, particularly in catching syntax errors.
|
||||
|
||||
Some examples:
|
||||
|
||||
Before: [![Screenshot #1.1](images/before1-smaller.png)](images/before1.png)
|
||||
<br/>
|
||||
After: [![Screenshot #1.2](images/after1-smaller.png)](images/after1.png)
|
||||
|
||||
Before: [![Screenshot #2.1](images/before2-smaller.png)](images/before2.png)
|
||||
<br/>
|
||||
After: [![Screenshot #2.2](images/after2-smaller.png)](images/after2.png)
|
||||
|
||||
Before: [![Screenshot #3.1](images/before3-smaller.png)](images/before3.png)
|
||||
<br/>
|
||||
After: [![Screenshot #3.2](images/after3-smaller.png)](images/after3.png)
|
||||
|
||||
Before: [![Screenshot #4.1](images/before4-smaller.png)](images/before4-smaller.png)
|
||||
<br/>
|
||||
After: [![Screenshot #4.2](images/after4-smaller.png)](images/after4-smaller.png)
|
||||
|
||||
|
||||
|
||||
How to install
|
||||
--------------
|
||||
|
||||
See [INSTALL.md](INSTALL.md).
|
||||
|
||||
|
||||
FAQ
|
||||
---
|
||||
|
||||
### Why must `zsh-syntax-highlighting.zsh` be sourced at the end of the `.zshrc` file?
|
||||
|
||||
zsh-syntax-highlighting works by hooking into the Zsh Line Editor (ZLE) and
|
||||
computing syntax highlighting for the command-line buffer as it stands at the
|
||||
time z-sy-h's hook is invoked.
|
||||
|
||||
In zsh 5.2 and older,
|
||||
`zsh-syntax-highlighting.zsh` hooks into ZLE by wrapping ZLE widgets. It must
|
||||
be sourced after all custom widgets have been created (i.e., after all `zle -N`
|
||||
calls and after running `compinit`) in order to be able to wrap all of them.
|
||||
Widgets created after z-sy-h is sourced will work, but will not update the
|
||||
syntax highlighting.
|
||||
|
||||
In zsh newer than 5.8 (not including 5.8 itself),
|
||||
zsh-syntax-highlighting uses the `add-zle-hook-widget` facility to install
|
||||
a `zle-line-pre-redraw` hook. Hooks are run in order of registration,
|
||||
therefore, z-sy-h must be sourced (and register its hook) after anything else
|
||||
that adds hooks that modify the command-line buffer.
|
||||
|
||||
### Does syntax highlighting work during incremental history search?
|
||||
|
||||
Highlighting the command line during an incremental history search (by default bound to
|
||||
to <kbd>Ctrl+R</kbd> in zsh's emacs keymap) requires zsh 5.4 or newer.
|
||||
|
||||
Under zsh versions older than 5.4, the zsh-default [underlining][zshzle-Character-Highlighting]
|
||||
of the matched portion of the buffer remains available, but zsh-syntax-highlighting's
|
||||
additional highlighting is unavailable. (Those versions of zsh do not provide
|
||||
enough information to allow computing the highlighting correctly.)
|
||||
|
||||
See issues [#288][i288] and [#415][i415] for details.
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
||||
[i288]: https://github.com/zsh-users/zsh-syntax-highlighting/pull/288
|
||||
[i415]: https://github.com/zsh-users/zsh-syntax-highlighting/pull/415
|
||||
|
||||
### How are new releases announced?
|
||||
|
||||
There is currently no "push" announcements channel. However, the following
|
||||
alternatives exist:
|
||||
|
||||
- GitHub's RSS feed of releases: https://github.com/zsh-users/zsh-syntax-highlighting/releases.atom
|
||||
- An anitya entry: https://release-monitoring.org/project/7552/
|
||||
|
||||
|
||||
How to tweak
|
||||
------------
|
||||
|
||||
Syntax highlighting is done by pluggable highlighter scripts. See the
|
||||
[documentation on highlighters](docs/highlighters.md) for details and
|
||||
configuration settings.
|
||||
|
||||
[build-status-image]: https://travis-ci.org/zsh-users/zsh-syntax-highlighting.svg?branch=master
|
||||
[build-status-travis]: https://travis-ci.org/zsh-users/zsh-syntax-highlighting
|
|
@ -1,884 +0,0 @@
|
|||
# Changes in HEAD
|
||||
|
||||
|
||||
## Changes fixed as part of the switch to zle-line-pre-redraw
|
||||
|
||||
The changes in this section were fixed by switching to a `zle-line-pre-redraw`-based
|
||||
implementation.
|
||||
|
||||
Note: The new implementation will only be used on future zsh releases,
|
||||
numbered 5.8.0.3 and newer, due to interoperability issues with other plugins
|
||||
(issues #418 and #579). The underlying zsh feature has been available since
|
||||
zsh 5.2.
|
||||
|
||||
Whilst under development, the new implementation was known as the
|
||||
"feature/redrawhook" topic branch.
|
||||
|
||||
- Fixed: Highlighting not triggered after popping a buffer from the buffer stack
|
||||
(using the `push-line` widget, default binding: `M-q`)
|
||||
[#40]
|
||||
|
||||
- Fixed: Invoking completion when there were no matches removed highlighting
|
||||
[#90, #470]
|
||||
|
||||
- Fixed: Two successive deletes followed by a yank only yanked the latest
|
||||
delete, rather than both of them
|
||||
[#150, #151, #160; cf. #183]
|
||||
|
||||
- Presumed fixed: Completing `$(xsel)` results in an error message from `xsel`,
|
||||
with pre-2017 versions of `xsel`. (For 2017 vintage and newer, see the issue
|
||||
for details.)
|
||||
[#154]
|
||||
|
||||
- Fixed: When the standard `bracketed-paste-magic` widget is in use, pastes were slow
|
||||
[#295]
|
||||
|
||||
- Fixed: No way to prevent a widget from being wrapped
|
||||
[#324]
|
||||
|
||||
- Fixed: No highlighting while cycling menu completion
|
||||
[#375]
|
||||
|
||||
- Fixed: Does not coexist with the `IGNORE_EOF` option
|
||||
[#377]
|
||||
|
||||
- Fixed: The `undefined-key` widget was wrapped
|
||||
[#421]
|
||||
|
||||
- Fixed: Does not coexist with the standard `surround` family of widgets
|
||||
[#520]
|
||||
|
||||
- Fixed: First completed filename doesn't get `path` highlighting
|
||||
[#632]
|
||||
|
||||
|
||||
## Other changes
|
||||
|
||||
- Add issue #712 to the previous release's changelog (hereinafter).
|
||||
|
||||
|
||||
# Changes in 0.8.0-alpha1-pre-redrawhook
|
||||
|
||||
## Notice about an improbable-but-not-impossible forward incompatibility
|
||||
|
||||
Everyone can probably skip this section.
|
||||
|
||||
The `master` branch of zsh-syntax-highlighting uses a zsh feature that has not
|
||||
yet appeared in a zsh release: the `memo=` feature, added to zsh in commit
|
||||
zsh-5.8-172-gdd6e702ee (after zsh 5.8, before zsh 5.9). In the unlikely event
|
||||
that this zsh feature should change in an incompatible way before the next
|
||||
stable zsh release, set `zsh_highlight__memo_feature=0` in your .zshrc files to
|
||||
disable use of the new feature.
|
||||
|
||||
z-sy-h dogfoods the new, unreleased zsh feature because that feature was
|
||||
added to zsh at z-sy-h's initiative. The new feature is used in the fix
|
||||
to issue #418.
|
||||
|
||||
|
||||
## Incompatible changes:
|
||||
|
||||
- An unsuccessful completion (a <kbd>⮀ Tab</kbd> press that doesn't change the
|
||||
command line) no longer causes highlighting to be lost. Visual feedback can
|
||||
alternatively be achieved by setting the `format` zstyle under the `warnings`
|
||||
tag, for example,
|
||||
|
||||
zstyle ':completion:*:warnings' format '%F{red}No matches%f'
|
||||
|
||||
Refer to the [description of the `format` style in `zshcompsys(1)`]
|
||||
[zshcompsys-Standard-Styles-format].
|
||||
|
||||
(#90, part of #245 (feature/redrawhook))
|
||||
|
||||
[zshcompsys-Standard-Styles]: http://zsh.sourceforge.net/Doc/Release/Completion-System.html#Standard-Styles
|
||||
[zshcompsys-Standard-Styles-format]: http://zsh.sourceforge.net/Doc/Release/Completion-System.html#index-format_002c-completion-style
|
||||
|
||||
|
||||
|
||||
## Other changes:
|
||||
|
||||
- Document `$ZSH_HIGHLIGHT_MAXLENGTH`.
|
||||
[#698]
|
||||
|
||||
- Optimize highlighting unquoted words (words that are not in single quotes, double quotes, backticks, or dollar-single-quotes)
|
||||
[#730]
|
||||
|
||||
- Redirection operators (e.g., `<` and `>`) are now highlighted by default
|
||||
[#646]
|
||||
|
||||
- Propertly terminate `noglob` scope in try/always blocks
|
||||
[#577]
|
||||
|
||||
- Don't error out when `KSH_ARRAYS` is set in the calling scope
|
||||
[#622, #689]
|
||||
|
||||
- Literal semicolons in array assignments (`foo=( bar ; baz )`) are now
|
||||
highlighted as errors.
|
||||
[3ca93f864fb6]
|
||||
|
||||
- Command separators in array assignments (`foo=( bar | baz )`) are now
|
||||
highlighted as errors.
|
||||
[#651, 81267ca3130c]
|
||||
|
||||
- Support parameter elision in command position (e.g., `$foo ls` where `$foo` is unset or empty)
|
||||
[#667]
|
||||
|
||||
- Don't consider the filename in `sudo -e /path/to/file` to be a command position
|
||||
[#678]
|
||||
|
||||
- Don't look up absolute directory names in $cdpath
|
||||
[2cc2583f8f12, part of #669]
|
||||
|
||||
- Fix `exec 2>&1;` being highlighted as an error.
|
||||
[#676]
|
||||
|
||||
- Fix `: $(<*)` being highlighted as globbing.
|
||||
[#582]
|
||||
|
||||
- Fix `cat < *` being highlighting as globbing when the `MULTIOS` option is unset.
|
||||
[#583]
|
||||
|
||||
- Fix `echo >&2` highlighting the `2` as a filename if a file by that name happened to exist
|
||||
[#694, part of #645]
|
||||
|
||||
- Fix `echo >&-` highlighting the `-` as a filename if a file by that name happened to exist
|
||||
[part of #645]
|
||||
|
||||
- Fix `echo >&p` highlighting the `p` as a filename if a file by that name happened to exist
|
||||
[part of #645]
|
||||
|
||||
- Fix wrong highlighting of unquoted parameter expansions under zsh 5.2 and older
|
||||
[e165f18c758e]
|
||||
|
||||
- Highlight global aliases
|
||||
[#700]
|
||||
|
||||
- Highlight `: =nosuchcommand' as an error (when the `EQUALS` option hasn't been unset).
|
||||
[#430]
|
||||
|
||||
- Highlight reserved word after assignments as errors (e.g., `foo=bar (ls;)`)
|
||||
[#461]
|
||||
|
||||
- Correctly highlight `[[ foo && bar || baz ]]`.
|
||||
|
||||
- Highlight non-executable files in command position correctly (e.g., `% /etc/passwd`)
|
||||
[#202, #669]
|
||||
|
||||
- Highlight directories in command position correctly, including `AUTO_CD` support
|
||||
[#669]
|
||||
|
||||
- Recognize `env` as a precommand (e.g., `env FOO=bar ls`)
|
||||
|
||||
- Recognize `strace` as a precommand
|
||||
|
||||
- Fix an error message on stderr before every prompt when the `WARN_NESTED_VAR` zsh option is set:
|
||||
`_zsh_highlight_main__precmd_hook:1: array parameter _zsh_highlight_main__command_type_cache set in enclosing scope in function _zsh_highlight_main__precmd_hook`
|
||||
[#727, #731, #732, #733]
|
||||
|
||||
- Fix highlighting of alias whose definitions use a simple command terminator
|
||||
(such as `;`, `|`, `&&`) before a newline
|
||||
[#677; had regressed in 0.7.0]
|
||||
|
||||
- Highlight arithmetic expansions (e.g., `$(( 42 ))`)
|
||||
[#607 #649 #704]
|
||||
|
||||
- Highlight the parentheses of array assignments as reserved words (`foo=( bar )`).
|
||||
The `assign` style remains supported and has precedence.
|
||||
[#585]
|
||||
|
||||
- Fix interoperability issue with other plugins that use highlighting. The fix
|
||||
requires zsh 5.8.0.3 or newer. (zsh 5.8.0.2-dev from the `master` branch,
|
||||
revision zsh-5.8-172-gdd6e702ee or newer is also fine.)
|
||||
[#418, https://github.com/okapia/zsh-viexchange/issues/1]
|
||||
|
||||
- Improve performance of the `brackets` highlighter.
|
||||
|
||||
- Fix highlighting of pre-command redirections (e.g., the `$fn` in `<$fn cat`)
|
||||
[#712]
|
||||
|
||||
|
||||
# Changes in version 0.7.1
|
||||
|
||||
- Remove out-of-date information from the 0.7.0 changelog.
|
||||
|
||||
|
||||
# Changes in version 0.7.0
|
||||
|
||||
This is a stable bugfix and feature release. Major new features and changes include:
|
||||
|
||||
- Add `ZSH_HIGHLIGHT_DIRS_BLACKLIST` to disable "path" and "path prefix"
|
||||
highlighting for specific directories
|
||||
[#379]
|
||||
|
||||
- Add the "regexp" highlighter, modelled after the pattern highlighter
|
||||
[4e6f60063f1c]
|
||||
|
||||
- When a word uses globbing, only the globbing metacharacters will be highlighted as globbing:
|
||||
in `: foo*bar`, only the `*` will be blue.
|
||||
[e48af357532c]
|
||||
|
||||
- Highlight pasted quotes (e.g., `: foo"bar"`)
|
||||
[dc1b2f6fa4bb]
|
||||
|
||||
- Highlight command substitutions (`` : `ls` ``, `: $(ls)`)
|
||||
[c0e64fe13178 and parents, e86f75a840e7, et al]
|
||||
|
||||
- Highlight process substitutions (`: >(nl)`, `: <(pwd)`, `: =(git diff)`)
|
||||
[c0e64fe13178 and parents, e86f75a840e7, et al]
|
||||
|
||||
- Highlight command substitutions inside double quotes (``: "`foo`"``)
|
||||
[f16e858f0c83]
|
||||
|
||||
- Highlight many precommands (e.g., `nice`, `stdbuf`, `eatmydata`;
|
||||
see `$precommand_options` in the source)
|
||||
|
||||
- Highlight numeric globs (e.g., `echo /lib<->`)
|
||||
|
||||
- Assorted improvements to aliases highlighting
|
||||
(e.g.,
|
||||
`alias sudo_u='sudo -u'; sudo_u jrandom ls`,
|
||||
`alias x=y y=z z=nosuchcommand; x`,
|
||||
`alias ls='ls -l'; \ls`)
|
||||
[f3410c5862fc, 57386f30aec8, #544, and many others]
|
||||
|
||||
- Highlight some more syntax errors
|
||||
[dea05e44e671, 298ef6a2fa30]
|
||||
|
||||
- New styles: named file descriptors, `RC_QUOTES`, and unclosed quotes (e.g., `echo "foo<CURSOR>`)
|
||||
[38c794a978cd, 25ae1c01216c, 967335dfc5fd]
|
||||
|
||||
- The 'brackets' highlighting no longer treats quotes specially.
|
||||
[ecdda36ef56f]
|
||||
|
||||
|
||||
Selected bugfixes include:
|
||||
|
||||
- Highlight `sudo` correctly when it's not installed
|
||||
[26a82113b08b]
|
||||
|
||||
- Handle some non-default options being set in zshrc
|
||||
[b07ada1255b7, a2a899b41b8, 972ad197c13d, b3f66fc8748f]
|
||||
|
||||
- Fix off-by-one highlighting in vi "visual" mode (vicmd keymap)
|
||||
[be3882aeb054]
|
||||
|
||||
- The 'yank-pop' widget is not wrapped
|
||||
[#183]
|
||||
|
||||
|
||||
Known issues include:
|
||||
|
||||
- A multiline alias that uses a simple command terminator (such as `;`, `|`, `&&`)
|
||||
before a newline will incorrectly be highlighted as an error. See issue #677
|
||||
for examples and workarounds.
|
||||
[#677]
|
||||
[UPDATE: Fixed in 0.8.0]
|
||||
|
||||
|
||||
# Changes in version 0.6.0
|
||||
|
||||
This is a stable release, featuring bugfixes and minor improvements.
|
||||
|
||||
|
||||
## Performance improvements:
|
||||
|
||||
(none)
|
||||
|
||||
|
||||
## Added highlighting of:
|
||||
|
||||
- The `isearch` and `suffix` [`$zle_highlight` settings][zshzle-Character-Highlighting].
|
||||
(79e4d3d12405, 15db71abd0cc, b56ee542d619; requires zsh 5.3 for `$ISEARCHMATCH_ACTIVE` / `$SUFFIX_ACTIVE` support)
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
||||
|
||||
- Possible history expansions in double-quoted strings.
|
||||
(76ea9e1df316)
|
||||
|
||||
- Mismatched `if`/`then`/`elif`/`else`/`fi`.
|
||||
(73cb83270262)
|
||||
|
||||
|
||||
## Fixed highlighting of:
|
||||
|
||||
- A comment line followed by a non-comment line.
|
||||
(#385, 9396ad5c5f9c)
|
||||
|
||||
- An unquoted `$*` (expands to the positional parameters).
|
||||
(237f89ad629f)
|
||||
|
||||
- history-incremental-pattern-search-backward under zsh 5.3.1.
|
||||
(#407, #415, 462779629a0c)
|
||||
|
||||
|
||||
## API changes (for highlighter authors):
|
||||
|
||||
(none)
|
||||
|
||||
|
||||
## Developer-visible changes:
|
||||
|
||||
- tests: Set the `ALIAS_FUNC_DEF` option for zsh 5.4 compatibility.
|
||||
(9523d6d49cb3)
|
||||
|
||||
|
||||
## Other changes:
|
||||
|
||||
- docs: Added before/after screenshots.
|
||||
(cd9ec14a65ec..b7e277106b49)
|
||||
|
||||
- docs: Link Fedora package.
|
||||
(3d74aa47e4a7, 5feed23962df)
|
||||
|
||||
- docs: Link FreeBSD port.
|
||||
(626c034c68d7)
|
||||
|
||||
- docs: Link OpenSUSE Build Service packages
|
||||
(#419, dea1fedc7358)
|
||||
|
||||
- Prevent user-defined aliases from taking effect in z-sy-h's own code.
|
||||
(#390, 2dce602727d7, 8d5afe47f774; and #392, #395, b8fa1b9dc954)
|
||||
|
||||
- docs: Update zplug installation instructions.
|
||||
(#399, 4f49c4a35f17)
|
||||
|
||||
- Improve "unhandled ZLE widget 'foo'" error message.
|
||||
(#409, be083d7f3710)
|
||||
|
||||
- Fix printing of "failed loading highlighters" error message.
|
||||
(#426, ad522a091429)
|
||||
|
||||
|
||||
# Changes in version 0.5.0
|
||||
|
||||
|
||||
## Performance improvements:
|
||||
|
||||
We thank Sebastian Gniazdowski and "m0viefreak" for significant contributions
|
||||
in this area.
|
||||
|
||||
- Optimize string operations in the `main` (default) highlighter.
|
||||
(#372/3cb58fd7d7b9, 02229ebd6328, ef4bfe5bcc14, #372/c6b6513ac0d6, #374/15461e7d21c3)
|
||||
|
||||
- Command word highlighting: Use the `zsh/parameter` module to avoid forks.
|
||||
Memoize (cache) the results.
|
||||
(#298, 3ce01076b521, 2f18ba64e397, 12b879caf7a6; #320, 3b67e656bff5)
|
||||
|
||||
- Avoid forks in the driver and in the `root` highlighter.
|
||||
(b9112aec798a, 38c8fbea2dd2)
|
||||
|
||||
|
||||
## Added highlighting of:
|
||||
|
||||
- `pkexec` (a precommand).
|
||||
(#248, 4f3910cbbaa5)
|
||||
|
||||
- Aliases that cannot be defined normally nor invoked normally (highlighted as an error).
|
||||
(#263 (in part), 28932316cca6)
|
||||
|
||||
- Path separators (`/`) — the default behaviour remains to highlight path separators
|
||||
and path components the same way.
|
||||
(#136, #260, 6cd39e7c70d3, 9a934d291e7c, f3d3aaa00cc4)
|
||||
|
||||
- Assignments to individual positional arguments (`42=foo` to assign to `$42`).
|
||||
(f4036a09cee3)
|
||||
|
||||
- Linewise region (the `visual-line-mode` widget, bound to `V` in zsh's `vi` keymap).
|
||||
(#267, a7a7f8b42280, ee07588cfd9b)
|
||||
|
||||
- Command-lines recalled by `isearch` mode; requires zsh≥5.3.
|
||||
(#261 (in part); #257; 4ad311ec0a68)
|
||||
|
||||
- Command-lines whilst the `IGNORE_BRACES` or `IGNORE_CLOSE_BRACES` option is in effect.
|
||||
(a8a6384356af, 02807f1826a5)
|
||||
|
||||
- Mismatched parentheses and braces (in the `main` highlighter).
|
||||
(51b9d79c3bb6, 2fabf7ca64b7, a4196eda5e6f, and others)
|
||||
|
||||
- Mismatched `do`/`done` keywords.
|
||||
(b2733a64da93)
|
||||
|
||||
- Mismatched `foreach`/`end` keywords.
|
||||
(#96, 2bb8f0703d8f)
|
||||
|
||||
- In Bourne-style function definitions, when the `MULTI_FUNC_DEF` option is set
|
||||
(which is the default), highlight the first word in the function body as
|
||||
a command word: `f() { g "$@" }`.
|
||||
(6f91850a01e1)
|
||||
|
||||
- `always` blocks.
|
||||
(#335, e5782e4ddfb6)
|
||||
|
||||
- Command substitutions inside double quotes, `"$(echo foo)"`.
|
||||
(#139 (in part), c3913e0d8ead)
|
||||
|
||||
- Non-alphabetic parameters inside double quotes (`"$$"`, `"$#"`, `"$*"`, `"$@"`, `"$?"`, `"$-"`).
|
||||
(4afe670f7a1b, 44ef6e38e5a7)
|
||||
|
||||
- Command words from future versions of zsh (forward compatibly).
|
||||
This also adds an `arg0` style that all other command word styles fall back to.
|
||||
(b4537a972eed, bccc3dc26943)
|
||||
|
||||
- Escaped history expansions inside double quotes: `: "\!"`
|
||||
(28d7056a7a06, et seq)
|
||||
|
||||
|
||||
## Fixed highlighting of:
|
||||
|
||||
- Command separator tokens in syntactically-invalid positions.
|
||||
(09c4114eb980)
|
||||
|
||||
- Redirections with a file descriptor number at command word.
|
||||
(#238 (in part), 73ee7c1f6c4a)
|
||||
|
||||
- The `select` prompt, `$PS3`.
|
||||
(#268, 451665cb2a8b)
|
||||
|
||||
- Values of variables in `vared`.
|
||||
(e500ca246286)
|
||||
|
||||
- `!` as an argument (neither a history expansion nor a reserved word).
|
||||
(4c23a2fd1b90)
|
||||
|
||||
- "division by zero" error under the `brackets` highlighter when `$ZSH_HIGHLIGHT_STYLES` is empty.
|
||||
(f73f3d53d3a6)
|
||||
|
||||
- Process substitutions, `<(pwd)` and `>(wc -l)`.
|
||||
(#302, 6889ff6bd2ad, bfabffbf975c, fc9c892a3f15)
|
||||
|
||||
- The non-`SHORT_LOOPS` form of `repeat` loops: `repeat 42; do true; done`.
|
||||
(#290, 4832f18c50a5, ef68f50c048f, 6362c757b6f7)
|
||||
|
||||
- Broken symlinks (are now highlighted as files).
|
||||
(#342, 95f7206a9373, 53083da8215e)
|
||||
|
||||
- Lines accepted from `isearch` mode.
|
||||
(#284; #257, #259, #288; 5bae6219008b, a8fe22d42251)
|
||||
|
||||
- Work around upstream bug that triggered when the command word was a relative
|
||||
path, that when interpreted relative to a $PATH directory denoted a command;
|
||||
the effect of that upstream bug was that the relative path was cached as
|
||||
a "valid external command name".
|
||||
(#354, #355, 51614ca2c994, fdaeec45146b, 7d38d07255e4;
|
||||
upstream fix slated to be released in 5.3 (workers/39104))
|
||||
|
||||
- After accepting a line with the cursor on a bracket, the matching bracket
|
||||
of the bracket under the cursor no longer remains highlighted (with the
|
||||
`brackets` highlighter).
|
||||
(4c4baede519a)
|
||||
|
||||
- The first word on a new line within an array assignment or initialization is no
|
||||
longer considered a command position.
|
||||
(8bf423d16d46)
|
||||
|
||||
- Subshells that end at command position, `(A=42)`, `(true;)`.
|
||||
(#231, 7fb6f9979121; #344, 4fc35362ee5a)
|
||||
|
||||
- Command word after array assignment, `a=(lorem ipsum) pwd`.
|
||||
(#330, 7fb6f9979121)
|
||||
|
||||
|
||||
## API changes (for highlighter authors):
|
||||
|
||||
- New interface `_zsh_highlight_add_highlight`.
|
||||
(341a3ae1f015, c346f6eb6fb6)
|
||||
|
||||
- tests: Specify the style key, not its value, in test expectations.
|
||||
(a830613467af, fd061b5730bf, eaa4335c3441, among others)
|
||||
|
||||
- Module author documentation improvements.
|
||||
(#306 (in part), 217669270418, 0ff354b44b6e, 80148f6c8402, 364f206a547f, and others)
|
||||
|
||||
- The driver no longer defines a `_zsh_highlight_${highlighter}_highlighter_cache`
|
||||
variable, which is in the highlighters' namespace.
|
||||
(3e59ab41b6b8, 80148f6c8402, f91a7b885e7d)
|
||||
|
||||
- Rename highlighter entry points. The old names remain supported for
|
||||
backwards compatibility.
|
||||
(a3d5dfcbdae9, c793e0dceab1)
|
||||
|
||||
- tests: Add the "NONE" expectation.
|
||||
(4da9889d1545, 13018f3dd735, d37c55c788cd)
|
||||
|
||||
- tests: consider a test that writes to stderr to have failed.
|
||||
(#291, 1082067f9315)
|
||||
|
||||
|
||||
## Developer-visible changes:
|
||||
|
||||
- Add `make quiet-test`.
|
||||
(9b64ad750f35)
|
||||
|
||||
- test harness: Better quote replaceables in error messages.
|
||||
(30d8f92df225)
|
||||
|
||||
- test harness: Fix exit code for XPASS.
|
||||
(bb8d325c0cbd)
|
||||
|
||||
- Create [HACKING.md](HACKING.md).
|
||||
(cef49752fd0e)
|
||||
|
||||
- tests: Emit a description for PASS test points.
|
||||
(6aa57d60aa64, f0bae44b76dd)
|
||||
|
||||
- tests: Create a script that generates a test file.
|
||||
(8013dc3b8db6, et seq; `tests/generate.zsh`)
|
||||
|
||||
|
||||
## Other changes:
|
||||
|
||||
- Under zsh≤5.2, widgets whose names start with a `_` are no longer excluded
|
||||
from highlighting.
|
||||
(ed33d2cb1388; reverts part of 186d80054a40 which was for #65)
|
||||
|
||||
- Under zsh≤5.2, widgets implemented by a function named after the widget are
|
||||
no longer excluded from highlighting.
|
||||
(487b122c480d; reverts part of 776453cb5b69)
|
||||
|
||||
- Under zsh≤5.2, shell-unsafe widget names can now be wrapped.
|
||||
(#278, 6a634fac9fb9, et seq)
|
||||
|
||||
- Correct some test expectations.
|
||||
(78290e043bc5)
|
||||
|
||||
- `zsh-syntax-highlighting.plugin.zsh`: Convert from symlink to plain file
|
||||
for msys2 compatibility.
|
||||
(#292, d4f8edc9f3ad)
|
||||
|
||||
- Document installation under some plugin managers.
|
||||
(e635f766bef9, 9cab566f539b)
|
||||
|
||||
- Don't leak the `PATH_DIRS` option.
|
||||
(7b82b88a7166)
|
||||
|
||||
- Don't require the `FUNCTION_ARGZERO` option to be set.
|
||||
(#338, 750aebc553f2)
|
||||
|
||||
- Under zsh≤5.2, support binding incomplete/nonexistent widgets.
|
||||
(9e569bb0fe04, part of #288)
|
||||
|
||||
- Make the driver reentrant, fixing possibility of infinite recursion
|
||||
under zsh≤5.2 under interaction with theoretical third-party code.
|
||||
(#305, d711563fe1bf, 295d62ec888d, f3242cbd6aba)
|
||||
|
||||
- Fix warnings when `WARN_CREATE_GLOBAL` is set prior to sourcing zsh-syntax-highlighting.
|
||||
(z-sy-h already sets `WARN_CREATE_GLOBAL` internally.)
|
||||
(da60234fb236)
|
||||
|
||||
- Warn only once, rather than once per keypress, when a highlighter is unavailable.
|
||||
(0a9b347483ae)
|
||||
|
||||
|
||||
# Changes in version 0.4.1
|
||||
|
||||
## Fixes:
|
||||
|
||||
- Arguments to widgets were not properly dash-escaped. Only matters for widgets
|
||||
that take arguments (i.e., that are invoked as `zle ${widget} -- ${args}`).
|
||||
(282c7134e8ac, reverts c808d2187a73)
|
||||
|
||||
|
||||
# Changes in version 0.4.0
|
||||
|
||||
|
||||
## Added highlighting of:
|
||||
|
||||
- incomplete sudo commands
|
||||
(a3047a912100, 2f05620b19ae)
|
||||
|
||||
```zsh
|
||||
sudo;
|
||||
sudo -u;
|
||||
```
|
||||
|
||||
- command words following reserved words
|
||||
(#207, #222, b397b12ac139 et seq, 6fbd2aa9579b et seq, 8b4adbd991b0)
|
||||
|
||||
```zsh
|
||||
if ls; then ls; else ls; fi
|
||||
repeat 10 do ls; done
|
||||
```
|
||||
|
||||
(The `ls` are now highlighted as a command.)
|
||||
|
||||
- comments (when `INTERACTIVE_COMMENTS` is set)
|
||||
(#163, #167, 693de99a9030)
|
||||
|
||||
```zsh
|
||||
echo Hello # comment
|
||||
```
|
||||
|
||||
- closing brackets of arithmetic expansion, subshells, and blocks
|
||||
(#226, a59f442d2d34, et seq)
|
||||
|
||||
```zsh
|
||||
(( foo ))
|
||||
( foo )
|
||||
{ foo }
|
||||
```
|
||||
|
||||
- command names enabled by the `PATH_DIRS` option
|
||||
(#228, 96ee5116b182)
|
||||
|
||||
```zsh
|
||||
# When ~/bin/foo/bar exists, is executable, ~/bin is in $PATH,
|
||||
# and 'setopt PATH_DIRS' is in effect
|
||||
foo/bar
|
||||
```
|
||||
|
||||
- parameter expansions with braces inside double quotes
|
||||
(#186, 6e3720f39d84)
|
||||
|
||||
```zsh
|
||||
echo "${foo}"
|
||||
```
|
||||
|
||||
- parameter expansions in command word
|
||||
(#101, 4fcfb15913a2)
|
||||
|
||||
```zsh
|
||||
x=/bin/ls
|
||||
$x -l
|
||||
```
|
||||
|
||||
- the command separators '\|&', '&!', '&\|'
|
||||
|
||||
```zsh
|
||||
view file.pdf &! ls
|
||||
```
|
||||
|
||||
|
||||
## Fixed highlighting of:
|
||||
|
||||
- precommand modifiers at non-command-word position
|
||||
(#209, 2c9f8c8c95fa)
|
||||
|
||||
```zsh
|
||||
ls command foo
|
||||
```
|
||||
|
||||
- sudo commands with infix redirections
|
||||
(#221, be006aded590, 86e924970911)
|
||||
|
||||
```zsh
|
||||
sudo -u >/tmp/foo.out user ls
|
||||
```
|
||||
|
||||
- subshells; anonymous functions
|
||||
(#166, #194, 0d1bfbcbfa67, 9e178f9f3948)
|
||||
|
||||
```zsh
|
||||
(true)
|
||||
() { true }
|
||||
```
|
||||
|
||||
- parameter assignment statements with no command
|
||||
(#205, 01d7eeb3c713)
|
||||
|
||||
```zsh
|
||||
A=1;
|
||||
```
|
||||
|
||||
(The semicolon used to be highlighted as a mistake)
|
||||
|
||||
- cursor highlighter: Remove the cursor highlighting when accepting a line.
|
||||
(#109, 4f0c293fdef0)
|
||||
|
||||
|
||||
## Removed features:
|
||||
|
||||
- Removed highlighting of approximate paths (`path_approx`).
|
||||
(#187, 98aee7f8b9a3)
|
||||
|
||||
|
||||
## Other changes:
|
||||
|
||||
- main highlighter refactored to use states rather than booleans.
|
||||
(2080a441ac49, et seq)
|
||||
|
||||
- Fix initialization when sourcing `zsh-syntax-highlighting.zsh` via a symlink
|
||||
(083c47b00707)
|
||||
|
||||
- docs: Add screenshot.
|
||||
(57624bb9f64b)
|
||||
|
||||
- widgets wrapping: Don't add '--' when invoking widgets.
|
||||
(c808d2187a73) [_reverted in 0.4.1_]
|
||||
|
||||
- Refresh highlighting upon `accept-*` widgets (`accept-line` et al).
|
||||
(59fbdda64c21)
|
||||
|
||||
- Stop leaking match/mbegin/mend to global scope (thanks to upstream
|
||||
`WARN_CREATE_GLOBAL` improvements).
|
||||
(d3deffbf46a4)
|
||||
|
||||
- 'make install': Permit setting `$(SHARE_DIR)` from the environment.
|
||||
(e1078a8b4cf1)
|
||||
|
||||
- driver: Tolerate KSH_ARRAYS being set in the calling context.
|
||||
(#162, 8f19af6b319d)
|
||||
|
||||
- 'make install': Install documentation fully and properly.
|
||||
(#219, b1619c001390, et seq)
|
||||
|
||||
- docs: Improve 'main' highlighter's documentation.
|
||||
(00de155063f5, 7d4252f5f596)
|
||||
|
||||
- docs: Moved to a new docs/ tree; assorted minor updates
|
||||
(c575f8f37567, 5b34c23cfad5, et seq)
|
||||
|
||||
- docs: Split README.md into INSTALL.md
|
||||
(0b3183f6cb9a)
|
||||
|
||||
- driver: Report `$ZSH_HIGHLIGHT_REVISION` when running from git
|
||||
(84734ba95026)
|
||||
|
||||
|
||||
## Developer-visible changes:
|
||||
|
||||
- Test harness converted to [TAP](http://testanything.org/tap-specification.html) format
|
||||
(d99aa58aaaef, et seq)
|
||||
|
||||
- Run each test in a separate subprocess, isolating them from each other
|
||||
(d99aa58aaaef, et seq)
|
||||
|
||||
- Fix test failure with nonexisting $HOME
|
||||
(#216, b2ac98b98150)
|
||||
|
||||
- Test output is now colorized.
|
||||
(4d3da30f8b72, 6fe07c096109)
|
||||
|
||||
- Document `make install`
|
||||
(a18a7427fd2c)
|
||||
|
||||
- tests: Allow specifying the zsh binary to use.
|
||||
(557bb7e0c6a0)
|
||||
|
||||
- tests: Add 'make perf' target
|
||||
(4513eaea71d7)
|
||||
|
||||
- tests: Run each test in a sandbox directory
|
||||
(c01533920245)
|
||||
|
||||
|
||||
# Changes in version 0.3.0
|
||||
|
||||
|
||||
## Added highlighting of:
|
||||
|
||||
- suffix aliases (requires zsh 5.1.1 or newer):
|
||||
|
||||
```zsh
|
||||
alias -s png=display
|
||||
foo.png
|
||||
```
|
||||
|
||||
- prefix redirections:
|
||||
|
||||
```zsh
|
||||
<foo.txt cat
|
||||
```
|
||||
|
||||
- redirection operators:
|
||||
|
||||
```zsh
|
||||
echo > foo.txt
|
||||
```
|
||||
|
||||
- arithmetic evaluations:
|
||||
|
||||
```zsh
|
||||
(( 42 ))
|
||||
```
|
||||
|
||||
- $'' strings, including \x/\octal/\u/\U escapes
|
||||
|
||||
```zsh
|
||||
: $'foo\u0040bar'
|
||||
```
|
||||
|
||||
- multiline strings:
|
||||
|
||||
```zsh
|
||||
% echo "line 1
|
||||
line 2"
|
||||
```
|
||||
|
||||
- string literals that haven't been finished:
|
||||
|
||||
```zsh
|
||||
% echo "Hello, world
|
||||
```
|
||||
- command words that involve tilde expansion:
|
||||
|
||||
```zsh
|
||||
% ~/bin/foo
|
||||
```
|
||||
|
||||
## Fixed highlighting of:
|
||||
|
||||
- quoted command words:
|
||||
|
||||
```zsh
|
||||
% \ls
|
||||
```
|
||||
|
||||
- backslash escapes in "" strings:
|
||||
|
||||
```zsh
|
||||
% echo "\x41"
|
||||
```
|
||||
|
||||
- noglob after command separator:
|
||||
|
||||
```zsh
|
||||
% :; noglob echo *
|
||||
```
|
||||
|
||||
- glob after command separator, when the first command starts with 'noglob':
|
||||
|
||||
```zsh
|
||||
% noglob true; echo *
|
||||
```
|
||||
|
||||
- the region (vi visual mode / set-mark-command) (issue #165)
|
||||
|
||||
- redirection and command separators that would be highlighted as `path_approx`
|
||||
|
||||
```zsh
|
||||
% echo foo;‸
|
||||
% echo <‸
|
||||
```
|
||||
|
||||
(where `‸` represents the cursor location)
|
||||
|
||||
- escaped globbing (outside quotes)
|
||||
|
||||
```zsh
|
||||
% echo \*
|
||||
```
|
||||
|
||||
|
||||
## Other changes:
|
||||
|
||||
- implemented compatibility with zsh's paste highlighting (issue #175)
|
||||
|
||||
- `$?` propagated correctly to wrapped widgets
|
||||
|
||||
- don't leak $REPLY into global scope
|
||||
|
||||
|
||||
## Developer-visible changes:
|
||||
|
||||
- added makefile with `install` and `test` targets
|
||||
|
||||
- set `warn_create_global` internally
|
||||
|
||||
- document release process
|
||||
|
||||
|
||||
|
||||
|
||||
# Version 0.2.1
|
||||
|
||||
(Start of changelog.)
|
||||
|
|
@ -1,132 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters
|
||||
======================================
|
||||
|
||||
Syntax highlighting is done by pluggable highlighters:
|
||||
|
||||
* `main` - the base highlighter, and the only one [active by default][1].
|
||||
* `brackets` - [matches brackets][2] and parenthesis.
|
||||
* `pattern` - matches [user-defined patterns][3].
|
||||
* `cursor` - matches [the cursor position][4].
|
||||
* `root` - highlights the whole command line [if the current user is root][5].
|
||||
* `line` - applied to [the whole command line][6].
|
||||
|
||||
[1]: highlighters/main.md
|
||||
[2]: highlighters/brackets.md
|
||||
[3]: highlighters/pattern.md
|
||||
[4]: highlighters/cursor.md
|
||||
[5]: highlighters/root.md
|
||||
[6]: highlighters/line.md
|
||||
|
||||
|
||||
Highlighter-independent settings
|
||||
--------------------------------
|
||||
|
||||
By default, all command lines are highlighted. However, it is possible to
|
||||
prevent command lines longer than a fixed number of characters from being
|
||||
highlighted by setting the variable `${ZSH_HIGHLIGHT_MAXLENGTH}` to the maximum
|
||||
length (in characters) of command lines to be highlighter. This is useful when
|
||||
editing very long comand lines (for example, with the [`fned`][fned] utility
|
||||
function). Example:
|
||||
|
||||
[fned]: http://zsh.sourceforge.net/Doc/Release/User-Contributions.html#index-zed
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_MAXLENGTH=512
|
||||
```
|
||||
|
||||
|
||||
How to activate highlighters
|
||||
----------------------------
|
||||
|
||||
To activate an highlighter, add it to the `ZSH_HIGHLIGHT_HIGHLIGHTERS` array in
|
||||
`~/.zshrc`, for example:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern cursor)
|
||||
```
|
||||
|
||||
By default, `$ZSH_HIGHLIGHT_HIGHLIGHTERS` is unset and only the `main`
|
||||
highlighter is active.
|
||||
|
||||
|
||||
How to tweak highlighters
|
||||
-------------------------
|
||||
|
||||
Highlighters look up styles from the `ZSH_HIGHLIGHT_STYLES` associative array.
|
||||
Navigate into the [individual highlighters' documentation](highlighters/) to
|
||||
see what styles (keys) each highlighter defines; the syntax for values is the
|
||||
same as the syntax of "types of highlighting" of the zsh builtin
|
||||
`$zle_highlight` array, which is documented in [the `zshzle(1)` manual
|
||||
page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
||||
|
||||
Some highlighters support additional configuration parameters; see each
|
||||
highlighter's documentation for details and examples.
|
||||
|
||||
|
||||
How to implement a new highlighter
|
||||
----------------------------------
|
||||
|
||||
To create your own `acme` highlighter:
|
||||
|
||||
* Create your script at
|
||||
`highlighters/acme/acme-highlighter.zsh`.
|
||||
|
||||
* Implement the `_zsh_highlight_highlighter_acme_predicate` function.
|
||||
This function must return 0 when the highlighter needs to be called and
|
||||
non-zero otherwise, for example:
|
||||
|
||||
```zsh
|
||||
_zsh_highlight_highlighter_acme_predicate() {
|
||||
# Call this highlighter in SVN working copies
|
||||
[[ -d .svn ]]
|
||||
}
|
||||
```
|
||||
|
||||
* Implement the `_zsh_highlight_highlighter_acme_paint` function.
|
||||
This function does the actual syntax highlighting, by calling
|
||||
`_zsh_highlight_add_highlight` with the start and end of the region to
|
||||
be highlighted and the `ZSH_HIGHLIGHT_STYLES` key to use. Define the default
|
||||
style for that key in the highlighter script outside of any function with
|
||||
`: ${ZSH_HIGHLIGHT_STYLES[key]:=value}`, being sure to prefix
|
||||
the key with your highlighter name and a colon. For example:
|
||||
|
||||
```zsh
|
||||
: ${ZSH_HIGHLIGHT_STYLES[acme:aurora]:=fg=green}
|
||||
|
||||
_zsh_highlight_highlighter_acme_paint() {
|
||||
# Colorize the whole buffer with the 'aurora' style
|
||||
_zsh_highlight_add_highlight 0 $#BUFFER acme:aurora
|
||||
}
|
||||
```
|
||||
|
||||
If you need to test which options the user has set, test `zsyh_user_options`
|
||||
with a sensible default if the option is not present in supported zsh
|
||||
versions. For example:
|
||||
|
||||
```zsh
|
||||
[[ ${zsyh_user_options[ignoreclosebraces]:-off} == on ]]
|
||||
```
|
||||
|
||||
The option name must be all lowercase with no underscores and not an alias.
|
||||
|
||||
* Name your own functions and global variables `_zsh_highlight_acme_*`.
|
||||
|
||||
- In zsh-syntax-highlighting 0.4.0 and earlier, the entrypoints
|
||||
`_zsh_highlight_highlighter_acme_predicate` and
|
||||
`_zsh_highlight_highlighter_acme_paint`
|
||||
were named
|
||||
`_zsh_highlight_acme_highlighter_predicate` and
|
||||
`_zsh_highlight_highlighter_acme_paint` respectively.
|
||||
|
||||
These names are still supported for backwards compatibility;
|
||||
however, support for them will be removed in a future major or minor release (v0.x.0 or v1.0.0).
|
||||
|
||||
* Activate your highlighter in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_HIGHLIGHTERS+=(acme)
|
||||
```
|
||||
|
||||
* [Write tests](../tests/README.md).
|
|
@ -1,31 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / brackets
|
||||
-------------------------------------------------
|
||||
|
||||
This is the `brackets` highlighter, that highlights brackets and parentheses, and
|
||||
matches them.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
This highlighter defines the following styles:
|
||||
|
||||
* `bracket-error` - unmatched brackets
|
||||
* `bracket-level-N` - brackets with nest level N
|
||||
* `cursor-matchingbracket` - the matching bracket, if cursor is on a bracket
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
# To define styles for nested brackets up to level 4
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]='fg=blue,bold'
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]='fg=red,bold'
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-3]='fg=yellow,bold'
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-4]='fg=magenta,bold'
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,24 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / cursor
|
||||
-----------------------------------------------
|
||||
|
||||
This is the `cursor` highlighter, that highlights the cursor.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
This highlighter defines the following styles:
|
||||
|
||||
* `cursor` - the style for the current cursor position
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_STYLES[cursor]='bg=blue'
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,24 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / line
|
||||
---------------------------------------------
|
||||
|
||||
This is the `line` highlighter, that highlights the whole line.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
This highlighter defines the following styles:
|
||||
|
||||
* `line` - the style for the whole line
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_STYLES[line]='bold'
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,121 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / main
|
||||
---------------------------------------------
|
||||
|
||||
This is the `main` highlighter, that highlights:
|
||||
|
||||
* Commands
|
||||
* Options
|
||||
* Arguments
|
||||
* Paths
|
||||
* Strings
|
||||
|
||||
This highlighter is active by default.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
This highlighter defines the following styles:
|
||||
|
||||
* `unknown-token` - unknown tokens / errors
|
||||
* `reserved-word` - shell reserved words (`if`, `for`)
|
||||
* `alias` - aliases
|
||||
* `suffix-alias` - suffix aliases (requires zsh 5.1.1 or newer)
|
||||
* `global-alias` - global aliases
|
||||
* `builtin` - shell builtin commands (`shift`, `pwd`, `zstyle`)
|
||||
* `function` - function names
|
||||
* `command` - command names
|
||||
* `precommand` - precommand modifiers (e.g., `noglob`, `builtin`)
|
||||
* `commandseparator` - command separation tokens (`;`, `&&`)
|
||||
* `hashed-command` - hashed commands
|
||||
* `autodirectory` - a directory name in command position when the `AUTO_CD` option is set
|
||||
* `path` - existing filenames
|
||||
* `path_pathseparator` - path separators in filenames (`/`); if unset, `path` is used (default)
|
||||
* `path_prefix` - prefixes of existing filenames
|
||||
* `path_prefix_pathseparator` - path separators in prefixes of existing filenames (`/`); if unset, `path_prefix` is used (default)
|
||||
* `globbing` - globbing expressions (`*.txt`)
|
||||
* `history-expansion` - history expansion expressions (`!foo` and `^foo^bar`)
|
||||
* `command-substitution` - command substitutions (`$(echo foo)`)
|
||||
* `command-substitution-unquoted` - an unquoted command substitution (`$(echo foo)`)
|
||||
* `command-substitution-quoted` - a quoted command substitution (`"$(echo foo)"`)
|
||||
* `command-substitution-delimiter` - command substitution delimiters (`$(` and `)`)
|
||||
* `command-substitution-delimiter-unquoted` - an unquoted command substitution delimiters (`$(` and `)`)
|
||||
* `command-substitution-delimiter-quoted` - a quoted command substitution delimiters (`"$(` and `)"`)
|
||||
* `process-substitution` - process substitutions (`<(echo foo)`)
|
||||
* `process-substitution-delimiter` - process substitution delimiters (`<(` and `)`)
|
||||
* `arithmetic-expansion` - arithmetic expansion `$(( 42 ))`)
|
||||
* `single-hyphen-option` - single-hyphen options (`-o`)
|
||||
* `double-hyphen-option` - double-hyphen options (`--option`)
|
||||
* `back-quoted-argument` - backtick command substitution (`` `foo` ``)
|
||||
* `back-quoted-argument-unclosed` - unclosed backtick command substitution (`` `foo ``)
|
||||
* `back-quoted-argument-delimiter` - backtick command substitution delimiters (`` ` ``)
|
||||
* `single-quoted-argument` - single-quoted arguments (`` 'foo' ``)
|
||||
* `single-quoted-argument-unclosed` - unclosed single-quoted arguments (`` 'foo ``)
|
||||
* `double-quoted-argument` - double-quoted arguments (`` "foo" ``)
|
||||
* `double-quoted-argument-unclosed` - unclosed double-quoted arguments (`` "foo ``)
|
||||
* `dollar-quoted-argument` - dollar-quoted arguments (`` $'foo' ``)
|
||||
* `dollar-quoted-argument-unclosed` - unclosed dollar-quoted arguments (`` $'foo ``)
|
||||
* `rc-quote` - two single quotes inside single quotes when the `RC_QUOTES` option is set (`` 'foo''bar' ``)
|
||||
* `dollar-double-quoted-argument` - parameter expansion inside double quotes (`$foo` inside `""`)
|
||||
* `back-double-quoted-argument` - backslash escape sequences inside double-quoted arguments (`\"` in `"foo\"bar"`)
|
||||
* `back-dollar-quoted-argument` - backslash escape sequences inside dollar-quoted arguments (`\x` in `$'\x48'`)
|
||||
* `assign` - parameter assignments (`x=foo` and `x=( )`)
|
||||
* `redirection` - redirection operators (`<`, `>`, etc)
|
||||
* `comment` - comments, when `setopt INTERACTIVE_COMMENTS` is in effect (`echo # foo`)
|
||||
* `comment` - elided parameters in command position (`$x ls` when `$x` is unset or empty)
|
||||
* `named-fd` - named file descriptor (the `fd` in `echo foo {fd}>&2`)
|
||||
* `numeric-fd` - numeric file descriptor (the `2` in `echo foo {fd}>&2`)
|
||||
* `arg0` - a command word other than one of those enumerated above (other than a command, precommand, alias, function, or shell builtin command).
|
||||
* `default` - everything else
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
# Declare the variable
|
||||
typeset -A ZSH_HIGHLIGHT_STYLES
|
||||
|
||||
# To differentiate aliases from other command types
|
||||
ZSH_HIGHLIGHT_STYLES[alias]='fg=magenta,bold'
|
||||
|
||||
# To have paths colored instead of underlined
|
||||
ZSH_HIGHLIGHT_STYLES[path]='fg=cyan'
|
||||
|
||||
# To disable highlighting of globbing expressions
|
||||
ZSH_HIGHLIGHT_STYLES[globbing]='none'
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
#### Parameters
|
||||
|
||||
To avoid partial path lookups on a path, add the path to the `ZSH_HIGHLIGHT_DIRS_BLACKLIST` array.
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_DIRS_BLACKLIST+=(/mnt/slow_share)
|
||||
```
|
||||
|
||||
### Useless trivia
|
||||
|
||||
#### Forward compatibility.
|
||||
|
||||
zsh-syntax-highlighting attempts to be forward-compatible with zsh.
|
||||
Specifically, we attempt to facilitate highlighting _command word_ types that
|
||||
had not yet been invented when this version of zsh-syntax-highlighting was
|
||||
released.
|
||||
|
||||
A _command word_ is something like a function name, external command name, et
|
||||
cetera. (See
|
||||
[Simple Commands & Pipelines in `zshmisc(1)`][zshmisc-Simple-Commands-And-Pipelines]
|
||||
for a formal definition.)
|
||||
|
||||
If a new _kind_ of command word is ever added to zsh — something conceptually
|
||||
different than "function" and "alias" and "external command" — then command words
|
||||
of that (new) kind will be highlighted by the style `arg0_$kind`,
|
||||
where `$kind` is the output of `type -w` on the new kind of command word. If that
|
||||
style is not defined, then the style `arg0` will be used instead.
|
||||
|
||||
[zshmisc-Simple-Commands-And-Pipelines]: http://zsh.sourceforge.net/Doc/Release/Shell-Grammar.html#Simple-Commands-_0026-Pipelines
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,24 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / pattern
|
||||
------------------------------------------------
|
||||
|
||||
This is the `pattern` highlighter, that highlights user-defined patterns.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
To use this highlighter, associate patterns with styles in the
|
||||
`ZSH_HIGHLIGHT_PATTERNS` associative array, for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
# Declare the variable
|
||||
typeset -A ZSH_HIGHLIGHT_PATTERNS
|
||||
|
||||
# To have commands starting with `rm -rf` in red:
|
||||
ZSH_HIGHLIGHT_PATTERNS+=('rm -rf *' 'fg=white,bold,bg=red')
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,30 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / regexp
|
||||
------------------------------------------------
|
||||
|
||||
This is the `regexp` highlighter, that highlights user-defined regular
|
||||
expressions. It's similar to the `pattern` highlighter, but allows more complex
|
||||
patterns.
|
||||
|
||||
### How to tweak it
|
||||
|
||||
To use this highlighter, associate regular expressions with styles in the
|
||||
`ZSH_HIGHLIGHT_REGEXP` associative array, for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
typeset -A ZSH_HIGHLIGHT_REGEXP
|
||||
ZSH_HIGHLIGHT_REGEXP+=('\bsudo\b' fg=123,bold)
|
||||
```
|
||||
|
||||
This will highlight "sudo" only as a complete word, i.e., "sudo cmd", but not
|
||||
"sudoedit"
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
See also: [regular expressions tutorial][perlretut], zsh regexp operator `=~`
|
||||
in [the `zshmisc(1)` manual page][zshmisc-Conditional-Expressions]
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
||||
[perlretut]: http://perldoc.perl.org/perlretut.html
|
||||
[zshmisc-Conditional-Expressions]: http://zsh.sourceforge.net/Doc/Release/Conditional-Expressions.html#Conditional-Expressions
|
|
@ -1,25 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters / root
|
||||
---------------------------------------------
|
||||
|
||||
This is the `root` highlighter, that highlights the whole line if the current
|
||||
user is root.
|
||||
|
||||
|
||||
### How to tweak it
|
||||
|
||||
This highlighter defines the following styles:
|
||||
|
||||
* `root` - the style for the whole line if the current user is root.
|
||||
|
||||
To override one of those styles, change its entry in `ZSH_HIGHLIGHT_STYLES`,
|
||||
for example in `~/.zshrc`:
|
||||
|
||||
```zsh
|
||||
ZSH_HIGHLIGHT_STYLES[root]='bg=red'
|
||||
```
|
||||
|
||||
The syntax for values is the same as the syntax of "types of highlighting" of
|
||||
the zsh builtin `$zle_highlight` array, which is documented in [the `zshzle(1)`
|
||||
manual page][zshzle-Character-Highlighting].
|
||||
|
||||
[zshzle-Character-Highlighting]: http://zsh.sourceforge.net/Doc/Release/Zsh-Line-Editor.html#Character-Highlighting
|
|
@ -1,15 +0,0 @@
|
|||
# Top-most editorconfig file
|
||||
|
||||
root = true
|
||||
|
||||
[*]
|
||||
end_of_line = lf
|
||||
tab_width = 2
|
||||
indent_size = 2
|
||||
indent_style = space
|
||||
|
||||
[Makefile]
|
||||
tab_width = 8
|
||||
indent_size = 8
|
||||
indent_style = tab
|
||||
|
|
@ -1 +0,0 @@
|
|||
.revision-hash export-subst
|
|
@ -1,3 +0,0 @@
|
|||
*.zwc*
|
||||
.pc/
|
||||
docs/all.md
|
|
@ -1 +0,0 @@
|
|||
$Format:%H$
|
|
@ -1,56 +0,0 @@
|
|||
language: generic
|
||||
sudo: required
|
||||
|
||||
env:
|
||||
- ZSH=master
|
||||
- ZSH=5.8
|
||||
- ZSH=5.7.1
|
||||
- ZSH=5.7
|
||||
- ZSH=5.6.2
|
||||
- ZSH=5.6.1
|
||||
- ZSH=5.6
|
||||
- ZSH=5.5.1
|
||||
- ZSH=5.5
|
||||
- ZSH=5.4.2
|
||||
- ZSH=5.4.1
|
||||
- ZSH=5.4
|
||||
- ZSH=5.3.1
|
||||
- ZSH=5.3
|
||||
- ZSH=5.2
|
||||
- ZSH=5.1.1
|
||||
- ZSH=5.1
|
||||
- ZSH=5.0.8
|
||||
- ZSH=5.0.7
|
||||
- ZSH=5.0.6
|
||||
- ZSH=5.0.5
|
||||
- ZSH=5.0.4
|
||||
- ZSH=5.0.3
|
||||
- ZSH=5.0.2
|
||||
- ZSH=5.0.1
|
||||
- ZSH=5.0.0
|
||||
- ZSH=4.3.17
|
||||
- ZSH=4.3.16
|
||||
- ZSH=4.3.15
|
||||
- ZSH=4.3.14
|
||||
- ZSH=4.3.13
|
||||
- ZSH=4.3.12
|
||||
- ZSH=4.3.11
|
||||
|
||||
script: docker run -v $PWD:/work -w /work zshusers/zsh:${ZSH} /bin/sh -c 'install_packages make procps bsdmainutils && make test'
|
||||
|
||||
notifications:
|
||||
webhooks:
|
||||
urls:
|
||||
- https://webhooks.gitter.im/e/367e241cdea60cb2070b
|
||||
on_success: change
|
||||
on_failure: always
|
||||
on_start: never
|
||||
irc:
|
||||
channels:
|
||||
- "chat.freenode.net#zsh-syntax-highlighting"
|
||||
on_success: change
|
||||
on_failure: always
|
||||
on_start: never
|
||||
use_notice: true
|
||||
template:
|
||||
- "%{repository}/%{branch}#%{build_number}: %{message} Changes : %{compare_url} | Build : %{build_url}"
|
|
@ -1 +0,0 @@
|
|||
0.8.0-alpha2-dev
|
|
@ -1,8 +0,0 @@
|
|||
zsh-syntax-highlighting / highlighters
|
||||
======================================
|
||||
|
||||
Navigate into the individual highlighters' documentation to see
|
||||
what styles (`$ZSH_HIGHLIGHT_STYLES` keys) each highlighter defines.
|
||||
|
||||
Refer to the [documentation on highlighters](../docs/highlighters.md) for further
|
||||
information.
|
|
@ -1,107 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2010-2017 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
# Define default styles.
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-error]:=fg=red,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-level-1]:=fg=blue,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-level-2]:=fg=green,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-level-3]:=fg=magenta,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-level-4]:=fg=yellow,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[bracket-level-5]:=fg=cyan,bold}
|
||||
: ${ZSH_HIGHLIGHT_STYLES[cursor-matchingbracket]:=standout}
|
||||
|
||||
# Whether the brackets highlighter should be called or not.
|
||||
_zsh_highlight_highlighter_brackets_predicate()
|
||||
{
|
||||
[[ $WIDGET == zle-line-finish ]] || _zsh_highlight_cursor_moved || _zsh_highlight_buffer_modified
|
||||
}
|
||||
|
||||
# Brackets highlighting function.
|
||||
_zsh_highlight_highlighter_brackets_paint()
|
||||
{
|
||||
local char style
|
||||
local -i bracket_color_size=${#ZSH_HIGHLIGHT_STYLES[(I)bracket-level-*]} buflen=${#BUFFER} level=0 matchingpos pos
|
||||
local -A levelpos lastoflevel matching
|
||||
|
||||
# Find all brackets and remember which one is matching
|
||||
pos=0
|
||||
for char in ${(s..)BUFFER} ; do
|
||||
(( ++pos ))
|
||||
case $char in
|
||||
["([{"])
|
||||
levelpos[$pos]=$((++level))
|
||||
lastoflevel[$level]=$pos
|
||||
;;
|
||||
[")]}"])
|
||||
if (( level > 0 )); then
|
||||
matchingpos=$lastoflevel[$level]
|
||||
levelpos[$pos]=$((level--))
|
||||
if _zsh_highlight_brackets_match $matchingpos $pos; then
|
||||
matching[$matchingpos]=$pos
|
||||
matching[$pos]=$matchingpos
|
||||
fi
|
||||
else
|
||||
levelpos[$pos]=-1
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
# Now highlight all found brackets
|
||||
for pos in ${(k)levelpos}; do
|
||||
if (( $+matching[$pos] )); then
|
||||
if (( bracket_color_size )); then
|
||||
_zsh_highlight_add_highlight $((pos - 1)) $pos bracket-level-$(( (levelpos[$pos] - 1) % bracket_color_size + 1 ))
|
||||
fi
|
||||
else
|
||||
_zsh_highlight_add_highlight $((pos - 1)) $pos bracket-error
|
||||
fi
|
||||
done
|
||||
|
||||
# If cursor is on a bracket, then highlight corresponding bracket, if any.
|
||||
if [[ $WIDGET != zle-line-finish ]]; then
|
||||
pos=$((CURSOR + 1))
|
||||
if (( $+levelpos[$pos] )) && (( $+matching[$pos] )); then
|
||||
local -i otherpos=$matching[$pos]
|
||||
_zsh_highlight_add_highlight $((otherpos - 1)) $otherpos cursor-matchingbracket
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
# Helper function to differentiate type
|
||||
_zsh_highlight_brackets_match()
|
||||
{
|
||||
case $BUFFER[$1] in
|
||||
\() [[ $BUFFER[$2] == \) ]];;
|
||||
\[) [[ $BUFFER[$2] == \] ]];;
|
||||
\{) [[ $BUFFER[$2] == \} ]];;
|
||||
*) false;;
|
||||
esac
|
||||
}
|
|
@ -1 +0,0 @@
|
|||
../../docs/highlighters/brackets.md
|
|
@ -1,36 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2016 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
WIDGET=zle-line-finish
|
||||
|
||||
BUFFER=': $foo[bar]'
|
||||
CURSOR=6 # cursor is zero-based
|
||||
|
||||
expected_region_highlight=(
|
||||
)
|
|
@ -1,47 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2016 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
unsorted=1
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-3]=
|
||||
|
||||
BUFFER=': ((( )))'
|
||||
CURSOR=2 # cursor is zero-based
|
||||
|
||||
expected_region_highlight=(
|
||||
"3 3 bracket-level-1"
|
||||
"4 4 bracket-level-2"
|
||||
"5 5 bracket-level-3"
|
||||
"7 7 bracket-level-3"
|
||||
"8 8 bracket-level-2"
|
||||
"9 9 bracket-level-1"
|
||||
"9 9 cursor-matchingbracket"
|
||||
)
|
|
@ -1,33 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2016 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
BUFFER=': (x)'
|
||||
|
||||
expected_region_highlight=(
|
||||
)
|
|
@ -1,53 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2016 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
unsorted=1
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-3]=
|
||||
|
||||
BUFFER=': ({[({[(x)]})]})'
|
||||
|
||||
expected_region_highlight=(
|
||||
"3 3 bracket-level-1"
|
||||
"4 4 bracket-level-2"
|
||||
"5 5 bracket-level-3"
|
||||
"6 6 bracket-level-1"
|
||||
"7 7 bracket-level-2"
|
||||
"8 8 bracket-level-3"
|
||||
"9 9 bracket-level-1"
|
||||
"11 11 bracket-level-1"
|
||||
"12 12 bracket-level-3"
|
||||
"13 13 bracket-level-2"
|
||||
"14 14 bracket-level-1"
|
||||
"15 15 bracket-level-3"
|
||||
"16 16 bracket-level-2"
|
||||
"17 17 bracket-level-1"
|
||||
)
|
|
@ -1,42 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2015 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
unsorted=1
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
|
||||
BUFFER='echo ({x}]'
|
||||
|
||||
expected_region_highlight=(
|
||||
"6 6 bracket-error" # (
|
||||
"7 7 bracket-level-2" # {
|
||||
"9 9 bracket-level-2" # }
|
||||
"10 10 bracket-error" # )
|
||||
)
|
|
@ -1,42 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2016 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
unsorted=1
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
|
||||
BUFFER=': {"{x}"}'
|
||||
|
||||
expected_region_highlight=(
|
||||
"3 3 bracket-level-1"
|
||||
"5 5 bracket-level-2"
|
||||
"7 7 bracket-level-2"
|
||||
"9 9 bracket-level-1"
|
||||
)
|
|
@ -1,45 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2015 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
unsorted=1
|
||||
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-1]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-2]=
|
||||
ZSH_HIGHLIGHT_STYLES[bracket-level-3]=
|
||||
|
||||
BUFFER='echo $(echo ${(z)array})'
|
||||
|
||||
expected_region_highlight=(
|
||||
"7 7 bracket-level-1" # (
|
||||
"14 14 bracket-level-2" # {
|
||||
"15 15 bracket-level-3" # (
|
||||
"17 17 bracket-level-3" # )
|
||||
"23 23 bracket-level-2" # }
|
||||
"24 24 bracket-level-1" # )
|
||||
)
|
|
@ -1,34 +0,0 @@
|
|||
# -------------------------------------------------------------------------------------------------
|
||||
# Copyright (c) 2017 zsh-syntax-highlighting contributors
|
||||
# All rights reserved.
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without modification, are permitted
|
||||
# provided that the following conditions are met:
|
||||
#
|
||||
# * Redistributions of source code must retain the above copyright notice, this list of conditions
|
||||
# and the following disclaimer.
|
||||
# * Redistributions in binary form must reproduce the above copyright notice, this list of
|
||||
# conditions and the following disclaimer in the documentation and/or other materials provided
|
||||
# with the distribution.
|
||||
# * Neither the name of the zsh-syntax-highlighting contributors nor the names of its contributors
|
||||
# may be used to endorse or promote products derived from this software without specific prior
|
||||
# written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
|
||||
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
|
||||
# FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
||||
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
|
||||
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
||||
# OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
# -*- mode: zsh; sh-indentation: 2; indent-tabs-mode: nil; sh-basic-offset: 2; -*-
|
||||
# vim: ft=zsh sw=2 ts=2 et
|
||||
# -------------------------------------------------------------------------------------------------
|
||||
|
||||
BUFFER=': x)'
|
||||
|
||||
expected_region_highlight=(
|
||||
"4 4 bracket-error" # )
|
||||
)
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue