Initial Commit

This commit is contained in:
Matthew McKinnon 2024-03-17 14:39:54 +10:00
commit 8143be717c
92 changed files with 6040 additions and 0 deletions

5
.gitignore vendored Normal file
View File

@ -0,0 +1,5 @@
vim/.netrwhist
mutt/oauth2

9
.gitmodules vendored Normal file
View File

@ -0,0 +1,9 @@
[submodule "config/awesome/awesome-wm-widgets"]
path = config/awesome/awesome-wm-widgets
url = https://github.com/streetturtle/awesome-wm-widgets.git
[submodule "vim/pack/themes/start/dracula"]
path = vim/pack/themes/start/dracula
url = https://github.com/dracula/vim.git
[submodule "zsh/dracula"]
path = zsh/dracula
url = https://github.com/dracula/zsh.git

9
README.md Normal file
View File

@ -0,0 +1,9 @@
dotfiles
========
* mutt - Setup for use with mutt that has sidebar patch applied. Multiple Accounts.
* nano - nanorc configuration with various syntax themes.
* vim - vimrc configuration various themes.
* bash - bashrc, bash_colors and bash_liases for use with bash shell.
* zsh - zshrc and zshrc_aliases config files
* oh-my-zsh - Persoanl oh-my-zsh theme

95
bash/bash_aliases Normal file
View File

@ -0,0 +1,95 @@
DISTRO=$(lsb_release -si)
if [[ $DISTRO = 'Debian' ]]; then
alias archey='screenfetch'
fi
# Fun / Games
alias aquarium='asciiquarium'
alias sudoku='nsudoku'
alias tetris='bastet'
alias mario='mupen64plus --windowed ~/ROMs/N64/SuperMario64.v64'
alias kart='mupen64plus --windowed ~/ROMs/N64/MarioKart64.v64'
alias zelda='mupen64plus --windowed ~/ROMs/N64/Zelda64.rom'
alias zeldamajora='mupen64plus --windowed ~/ROMs/N64/ZeldaMajorasMask.z'
alias ps2='pcsx2'
#System
alias shutdown='sudo shutdown -P now'
alias Stat='uname -a;systemd-analyze time;wc -l /lib/modules/$(uname -r)/modules.order; lsinitcpio -a /boot/initramfs-linux.img'
## Packages
alias rarx='unrar x'
alias zipx='unzip x'
alias gzx='tar -xzvf'
alias xzx='tar -xJvf'
alias bzx='tar -xvjf'
# Pacman
alias P='pacaur'
alias PY='pacaur -Syy'
alias PU='pacaur -Syu'
alias PAY='sudo pacman -Syy'
alias PAU='sudo pacman -Syu'
# Default to human readable figures
alias df='df -h'
alias du='du -h'
# Interactive operation...
# alias rm='rm -i'
# alias cp='cp -i'
# alias mv='mv -i'
# Misc :)
alias less='less -r' # raw control characters
alias grep='grep --color' # show differences in colour
alias egrep='egrep --color=auto' # show differences in colour
alias fgrep='fgrep --color=auto' # show differences in colour
alias nemo='nemo --no-desktop'
# Some shortcuts for different directory listings
alias ls='ls -hF --color=auto' # classify files in colour
alias dir='ls --color=auto --format=vertical'
alias vdir='ls --color=auto --format=long'
alias ll='ls -l' # long list
alias la='ls -A' # all but . and ..
alias l='ls -CF'
alias ..='cd ..'
alias ...='cd ...'
alias ....='cd ....'
alias .....='cd .....'
alias k='exit'
alias D='cd ~/Downloads'
## Vim Stuff
alias eV='vim ~/.vimrc'
alias e='vim'
## YouTube
alias yt='cd ~/Downloads/YouTube'
alias cleanYT='rm ~/Downloads/YouTube/*.*'
alias DL='cd ~/Downloads/YouTube && youtube-dl -ic'
#Bash Stuff
alias eB='vim ~/.bashrc'
alias eBG='leafpad ~/.bashrc'
alias B='source ~/.bashrc'
## News and Music
alias news='newsbeuter'
alias nix='cortex linux'
alias pods='podbeuter'
alias twit='turses'
alias Pods='cd ~/Music/Podcasts && ranger'
## Net
alias irc='weechat-curses'
alias hogs='sudo nethogs enp2s0'
alias ST='speedtest-cli'
alias ssh='TERM=xterm ssh'

79
bash/bash_colors Normal file
View File

@ -0,0 +1,79 @@
# Customize BASH PS1 prompt to show current GIT repository and branch.
# by Mike Stewart - http://MediaDoneRight.com
# SETUP CONSTANTS
# Bunch-o-predefined colors. Makes reading code easier than escape sequences.
# I don't remember where I found this. o_O
# Reset
Color_Off="\[\033[0m\]" # Text Reset
# Regular Colors
Black="\[\033[0;30m\]" # Black
Red="\[\033[0;31m\]" # Red
Green="\[\033[0;32m\]" # Green
Yellow="\[\033[0;33m\]" # Yellow
Blue="\[\033[0;34m\]" # Blue
Purple="\[\033[0;35m\]" # Purple
Cyan="\[\033[0;36m\]" # Cyan
White="\[\033[0;37m\]" # White
# Bold
BBlack="\[\033[1;30m\]" # Black
BRed="\[\033[1;31m\]" # Red
BGreen="\[\033[1;32m\]" # Green
BYellow="\[\033[1;33m\]" # Yellow
BBlue="\[\033[1;34m\]" # Blue
BPurple="\[\033[1;35m\]" # Purple
BCyan="\[\033[1;36m\]" # Cyan
BWhite="\[\033[1;37m\]" # White
# Underline
UBlack="\[\033[4;30m\]" # Black
URed="\[\033[4;31m\]" # Red
UGreen="\[\033[4;32m\]" # Green
UYellow="\[\033[4;33m\]" # Yellow
UBlue="\[\033[4;34m\]" # Blue
UPurple="\[\033[4;35m\]" # Purple
UCyan="\[\033[4;36m\]" # Cyan
UWhite="\[\033[4;37m\]" # White
# Background
On_Black="\[\033[40m\]" # Black
On_Red="\[\033[41m\]" # Red
On_Green="\[\033[42m\]" # Green
On_Yellow="\[\033[43m\]" # Yellow
On_Blue="\[\033[44m\]" # Blue
On_Purple="\[\033[45m\]" # Purple
On_Cyan="\[\033[46m\]" # Cyan
On_White="\[\033[47m\]" # White
# High Intensty
IBlack="\[\033[0;90m\]" # Black
IRed="\[\033[0;91m\]" # Red
IGreen="\[\033[0;92m\]" # Green
IYellow="\[\033[0;93m\]" # Yellow
IBlue="\[\033[0;94m\]" # Blue
IPurple="\[\033[0;95m\]" # Purple
ICyan="\[\033[0;96m\]" # Cyan
IWhite="\[\033[0;97m\]" # White
# Bold High Intensty
BIBlack="\[\033[1;90m\]" # Black
BIRed="\[\033[1;91m\]" # Red
BIGreen="\[\033[1;92m\]" # Green
BIYellow="\[\033[1;93m\]" # Yellow
BIBlue="\[\033[1;94m\]" # Blue
BIPurple="\[\033[1;95m\]" # Purple
BICyan="\[\033[1;96m\]" # Cyan
BIWhite="\[\033[1;97m\]" # White
# High Intensty backgrounds
On_IBlack="\[\033[0;100m\]" # Black
On_IRed="\[\033[0;101m\]" # Red
On_IGreen="\[\033[0;102m\]" # Green
On_IYellow="\[\033[0;103m\]" # Yellow
On_IBlue="\[\033[0;104m\]" # Blue
On_IPurple="\[\033[10;95m\]" # Purple
On_ICyan="\[\033[0;106m\]" # Cyan
On_IWhite="\[\033[0;107m\]" # White

53
bash/bashrc Normal file
View File

@ -0,0 +1,53 @@
# User dependent .bashrc file
# If not running interactively, don't do anything
[[ "$-" != *i* ]] && return
# Various variables you might want for your PS1 prompt instead
Time12h="\T"
Time12a="\@"
PathShort="\w"
PathFull="\W"
NewLine="\n"
Jobs="\j"
# Shell Options
set -o notify
set -o ignoreeof
shopt -s nocaseglob
shopt -s histappend
shopt -s cdspell
# Completion options
COMP_CVS_REMOTE=1
COMP_CONFIGURE_HINTS=1
COMP_TAR_INTERNAL_PATHS=1
[[ -f /etc/bash_completion ]] && . /etc/bash_completion
# Aliases
if [ -f "${HOME}/.bash_aliases" ]; then
source "${HOME}/.bash_aliases"
fi
if [ -f "${HOME}/.bash_colors" ]; then
source "${HOME}/.bash_colors"
fi
# Display the current git branch in the command prompt
if [ "$EUID" -ne 0 ]; then
export PS1="$BWhite[$BGreen\u$BWhite@$BBlue\h $BYellow\w $BWhite]\$ "
else
export PS1="$BWhite[$BRed\u$BWhite@$BBlue\h $BYellow\w $BWhite]\$ "
fi
if [ -e /usr/share/terminfo/x/xterm-256color ] && [ "$COLORTERM" == "xfce4-terminal" ]; then
export TERM=xterm-256color
fi
if [[ -n "$DISPLAY" && "$TERM" = "xterm" ]]; then
export TERM=xterm-256color
fi

View File

@ -0,0 +1 @@
import = ["~/.config/alacritty/gnome_terminal.toml"]

View File

@ -0,0 +1,76 @@
# Dracula theme for Alacritty
# https://draculatheme.com/alacritty
#
# Color palette
# https://spec.draculatheme.com
#
# Instructions
# https://github.com/alacritty/alacritty/blob/master/extra/man/alacritty.5.scd
[colors.primary]
background = "#282a36"
foreground = "#f8f8f2"
bright_foreground = "#ffffff"
[colors.cursor]
text = "#282a36"
cursor = "#f8f8f2"
[colors.vi_mode_cursor]
text = "CellBackground"
cursor = "CellForeground"
[colors.selection]
text = "CellForeground"
background = "#44475a"
[colors.normal]
black = "#21222c"
red = "#ff5555"
green = "#50fa7b"
yellow = "#f1fa8c"
blue = "#bd93f9"
magenta = "#ff79c6"
cyan = "#8be9fd"
white = "#f8f8f2"
[colors.bright]
black = "#6272a4"
red = "#ff6e6e"
green = "#69ff94"
yellow = "#ffffa5"
blue = "#d6acff"
magenta = "#ff92df"
cyan = "#a4ffff"
white = "#ffffff"
[colors.search.matches]
foreground = "#44475a"
background = "#50fa7b"
[colors.search.focused_match]
foreground = "#44475a"
background = "#ffb86c"
[colors.footer_bar]
background = "#282a36"
foreground = "#f8f8f2"
[colors.hints.start]
foreground = "#282a36"
background = "#f1fa8c"
[colors.hints.end]
foreground = "#f1fa8c"
background = "#282a36"

View File

@ -0,0 +1,28 @@
# Gnome (Gnome Terminal Default)
# Default colors
[colors.primary]
background = '#1e1e1e'
foreground = '#ffffff'
# Normal colors
[colors.normal]
black = '#171421'
red = '#c01c28'
green = '#26a269'
yellow = '#a2734c'
blue = '#12488b'
magenta = '#a347ba'
cyan = '#2aa1b3'
white = '#d0cfcc'
# Bright colors
[colors.bright]
black = '#5e5c64'
red = '#f66151'
green = '#33d17a'
yellow = '#e9ad0c'
blue = '#2a7bde'
magenta = '#c061cb'
cyan = '#33c7de'
white = '#ffffff'

View File

@ -0,0 +1,32 @@
# Colors (Hyper)
# Default colors
[colors.primary]
background = '#000000'
foreground = '#ffffff'
[colors.cursor]
text = '#F81CE5'
cursor = '#ffffff'
# Normal colors
[colors.normal]
black = '#000000'
red = '#fe0100'
green = '#33ff00'
yellow = '#feff00'
blue = '#0066ff'
magenta = '#cc00ff'
cyan = '#00ffff'
white = '#d0d0d0'
# Bright colors
[colors.bright]
black = '#808080'
red = '#fe0100'
green = '#33ff00'
yellow = '#feff00'
blue = '#0066ff'
magenta = '#cc00ff'
cyan = '#00ffff'
white = '#FFFFFF'

13
config/awesome/autostart.sh Executable file
View File

@ -0,0 +1,13 @@
#!/usr/bin/env bash
function run {
if ! pgrep -f $1 ;
then
$@&
fi
}
run /usr/lib/polkit-gnome/polkit-gnome-authentication-agent-1
run nm-applet
run parcellite
#run picom --config $HOME/.config/picom/picom.conf

646
config/awesome/rc.lua Normal file
View File

@ -0,0 +1,646 @@
-- If LuaRocks is installed, make sure that packages installed through it are
-- found (e.g. lgi). If LuaRocks is not installed, do nothing.
pcall(require, "luarocks.loader")
-- Standard awesome library
local gears = require("gears")
local awful = require("awful")
require("awful.autofocus")
-- Widget and layout library
local wibox = require("wibox")
-- Theme handling library
local beautiful = require("beautiful")
-- Notification library
local naughty = require("naughty")
local menubar = require("menubar")
local hotkeys_popup = require("awful.hotkeys_popup")
-- Enable hotkeys help widget for VIM and other apps
-- when client with a matching name is opened:
require("awful.hotkeys_popup.keys")
local volume_widget = require('awesome-wm-widgets.pactl-widget.volume')
local blacklisted_snid = setmetatable({}, {__mode = "v" })
-- {{{ Error handling
-- Check if awesome encountered an error during startup and fell back to
-- another config (This code will only ever execute for the fallback config)
if awesome.startup_errors then
naughty.notify({ preset = naughty.config.presets.critical,
title = "Oops, there were errors during startup!",
text = awesome.startup_errors })
end
-- Handle runtime errors after startup
do
local in_error = false
awesome.connect_signal("debug::error", function (err)
-- Make sure we don't go into an endless error loop
if in_error then return end
in_error = true
naughty.notify({ preset = naughty.config.presets.critical,
title = "Oops, an error happened!",
text = tostring(err) })
in_error = false
end)
end
-- }}}
-- {{{ Variable definitions
-- Themes define colours, icons, font and wallpapers.
-- beautiful.init(gears.filesystem.get_themes_dir() .. "default/theme.lua")
beautiful.init("~/.config/awesome/theme.lua")
-- This is used later as the default terminal and editor to run.
terminal = "lxterminal"
editor = os.getenv("EDITOR") or "vim"
editor_cmd = terminal .. " -e " .. editor
-- Default modkey.
-- Usually, Mod4 is the key with a logo between Control and Alt.
-- If you do not like this or do not have such a key,
-- I suggest you to remap Mod4 to another key using xmodmap or other tools.
-- However, you can use another modifier like Mod1, but it may interact with others.
modkey = "Mod4"
local l = awful.layout.suit
awful.layout.layouts = {
awful.layout.suit.floating,
awful.layout.suit.tile,
awful.layout.suit.tile.left,
awful.layout.suit.tile.bottom,
awful.layout.suit.tile.top,
awful.layout.suit.fair,
awful.layout.suit.fair.horizontal,
awful.layout.suit.spiral,
awful.layout.suit.spiral.dwindle,
awful.layout.suit.max,
awful.layout.suit.max.fullscreen,
awful.layout.suit.magnifier,
awful.layout.suit.corner.nw,
-- awful.layout.suit.corner.ne,
-- awful.layout.suit.corner.sw,
-- awful.layout.suit.corner.se,
}
-- }}}
-- {{{ Menu
-- Create a launcher widget and a main menu
myawesomemenu = {
{ "hotkeys", function() hotkeys_popup.show_help(nil, awful.screen.focused()) end },
{ "manual", terminal .. " -e man awesome" },
{ "edit config", editor_cmd .. " " .. awesome.conffile },
{ "restart", awesome.restart },
{ "quit", function() awesome.quit() end },
}
mymainmenu = awful.menu({ items = { { "awesome", myawesomemenu, beautiful.awesome_icon },
{ "open terminal", terminal }
}
})
mylauncher = awful.widget.launcher({ image = beautiful.awesome_icon,
menu = mymainmenu })
-- Menubar configuration
menubar.utils.terminal = terminal -- Set the terminal for applications that require it
-- }}}
-- Keyboard map indicator and switcher
-- mykeyboardlayout = awful.widget.keyboardlayout()
-- This is for my current year calendar. I did not feel like setting a reminder to update this every Jan. 1. In 2023, this caused some confusion because it did not roll over automatically.
yr = os.date("%Y")
-- My popup calendar, source adapted from: https://pavelmakhov.com/2017/03/calendar-widget-for-awesome
function cal_notify(cal_pref, pref_screen)
if cal_notification == nil then
awful.spawn.easy_async([[bash -c "]]..cal_pref..[[ | sed 's/_.\(.\)/+\1-/g;s/$//g;/]]..yr..[[$/d'"]],
function(stdout, stderr, reason, exit_code)
cal_notification = naughty.notify {
text = string.gsub(string.gsub(stdout, "+", "<span background='#85492e'>"), "-", "</span>"),
timeout = 0,
margin = 20,
font = "Hack Nerd Font",
screen = pref_screen,
width = auto,
destroy = function() cal_notification = nil end
}
end)
else
naughty.destroy(cal_notification)
-- naughty.destroy_all_notifications()
end
end
-- Create a textclock widget and attach calendar to it on click.
local mytextclock = wibox.widget.textclock (" %d %b %I:%M %p ")
mytextclock:connect_signal("button::release", function() cal_notify("cal "..yr) end)
-- Create a wibox for each screen and add it
local taglist_buttons = gears.table.join(
awful.button({ }, 1, function(t) t:view_only() end),
awful.button({ modkey }, 1, function(t)
if client.focus then
client.focus:move_to_tag(t)
end
end),
awful.button({ }, 3, awful.tag.viewtoggle),
awful.button({ modkey }, 3, function(t)
if client.focus then
client.focus:toggle_tag(t)
end
end),
awful.button({ }, 4, function(t) awful.tag.viewnext(t.screen) end),
awful.button({ }, 5, function(t) awful.tag.viewprev(t.screen) end)
)
local tasklist_buttons = gears.table.join(
awful.button({ }, 1, function (c)
if c == client.focus then
c.minimized = true
else
c:emit_signal(
"request::activate",
"tasklist",
{raise = true}
)
end
end),
awful.button({ }, 3, function()
awful.menu.client_list({ theme = { width = 250 } })
end),
awful.button({ }, 4, function ()
awful.client.focus.byidx(1)
end),
awful.button({ }, 5, function ()
awful.client.focus.byidx(-1)
end))
local function set_wallpaper(s)
-- Wallpaper
if beautiful.wallpaper then
local wallpaper = beautiful.wallpaper
-- If wallpaper is a function, call it with the screen
if type(wallpaper) == "function" then
wallpaper = wallpaper(s)
end
gears.wallpaper.maximized(wallpaper, s, true)
end
end
-- Re-set wallpaper when a screen's geometry changes (e.g. different resolution)
screen.connect_signal("property::geometry", set_wallpaper)
-- These are my tag names.
web="WEB"
term="TERM"
mis="MIS"
news="NEWS"
irc="IRC"
mus="MUS"
pir="PIR"
mov="MOV"
gam="GAM"
awful.screen.connect_for_each_screen(function(s)
set_wallpaper(s)
-- Set my tags for each screen with their own preferred layouts.
awful.tag.add(web, { layout = l.spiral, screen = s, selected = true, })
awful.tag.add(term, { layout = l.spiral, screen = s, })
awful.tag.add(mis, { layout = l.spiral, screen = s, })
if s.index == 1 then
awful.tag.add(news, { layout = l.spiral, screen = s, })
awful.tag.add(irc, { layout = l.tile.bottom, screen = s, })
awful.tag.add(mus, { layout = l.tile.bottom, screen = s, })
awful.tag.add(pir, { layout = l.spiral, screen = s, })
awful.tag.add(mov, { layout = l.spiral, screen = s, })
awful.tag.add(gam, { layout = l.spiral, screen = s, })
end
-- Create an imagebox widget which will contain an icon indicating which layout we're using.
-- We need one layoutbox per screen.
s.mylayoutbox = awful.widget.layoutbox(s)
s.mylayoutbox:buttons(gears.table.join(awful.button({ }, 1, function() awful.layout.inc( 1) end)))
-- Create a taglist widget
s.mytaglist = awful.widget.taglist {
screen = s,
-- There is no point in showing an empty tag.
-- filter = awful.widget.taglist.filter.noempty,
filter = awful.widget.taglist.filter.all,
buttons = taglist_buttons,
}
-- Create a tasklist widget
s.mytasklist = awful.widget.tasklist {
screen = s, filter = awful.widget.tasklist.filter.currenttags, buttons = tasklist_buttons,
}
-- Create the wibox
s.mywibox = awful.wibar({ position = "top", screen = s, height = 25 })
-- Add widgets to the wibox
if s.index == 1 then
-- I only want the system tray, clock, etc. to be on screen one and not on every screen.
s.mywibox:setup {
layout = wibox.layout.align.horizontal,
{ layout = wibox.layout.fixed.horizontal,
s.mytaglist,
},
s.mytasklist,
{ layout = wibox.layout.fixed.horizontal,
spacer,
volume_widget{
widget_type = 'arc'
},
wibox.widget.systray(),
spacer,
battery_status,
mytextclock,
s.mylayoutbox,
},
}
else
s.mywibox:setup {
layout = wibox.layout.align.horizontal,
{ layout = wibox.layout.fixed.horizontal,
s.mytaglist,
},
s.mytasklist,
{ layout = wibox.layout.fixed.horizontal,
s.mylayoutbox,
},
}
end
end)
-- }}}https://wiki.archlinux.org/title/N
-- {{{ Mouse bindingsxproperty
root.buttons(gears.table.join(
awful.button({ }, 3, function () mymainmenu:toggle() end),
awful.button({ }, 4, awful.tag.viewnext),
awful.button({ }, 5, awful.tag.viewprev)
))
-- }}}
-- {{{ Key bindings
globalkeys = gears.table.join(
awful.key({ modkey, }, "s", hotkeys_popup.show_help,
{description="show help", group="awesome"}),
awful.key({ modkey, }, "Left", awful.tag.viewprev,
{description = "view previous", group = "tag"}),
awful.key({ modkey, }, "Right", awful.tag.viewnext,
{description = "view next", group = "tag"}),
awful.key({ modkey, }, "Escape", awful.tag.history.restore,
{description = "go back", group = "tag"}),
awful.key({ modkey, }, "j",
function ()
awful.client.focus.byidx( 1)
end,
{description = "focus next by index", group = "client"}
),
awful.key({ modkey, }, "k",
function ()
awful.client.focus.byidx(-1)
end,
{description = "focus previous by index", group = "client"}
),
awful.key({ modkey, }, "w", function () mymainmenu:show() end,
{description = "show main menu", group = "awesome"}),
-- Layout manipulation
awful.key({ modkey, "Shift" }, "j", function () awful.client.swap.byidx( 1) end,
{description = "swap with next client by index", group = "client"}),
awful.key({ modkey, "Shift" }, "k", function () awful.client.swap.byidx( -1) end,
{description = "swap with previous client by index", group = "client"}),
awful.key({ modkey, "Control" }, "j", function () awful.screen.focus_relative( 1) end,
{description = "focus the next screen", group = "screen"}),
awful.key({ modkey, "Control" }, "k", function () awful.screen.focus_relative(-1) end,
{description = "focus the previous screen", group = "screen"}),
awful.key({ modkey, }, "u", awful.client.urgent.jumpto,
{description = "jump to urgent client", group = "client"}),
awful.key({ modkey, }, "Tab",
function ()
awful.client.focus.history.previous()
if client.focus then
client.focus:raise()
end
end,
{description = "go back", group = "client"}),
-- Standard program
awful.key({ modkey, }, "Return", function () awful.spawn(terminal) end,
{description = "open a terminal", group = "launcher"}),
awful.key({ modkey, "Control" }, "r", awesome.restart,
{description = "reload awesome", group = "awesome"}),
awful.key({ modkey, "Shift" }, "q", awesome.quit,
{description = "quit awesome", group = "awesome"}),
awful.key({ modkey, }, "l", function () awful.tag.incmwfact( 0.05) end,
{description = "increase master width factor", group = "layout"}),
awful.key({ modkey, }, "h", function () awful.tag.incmwfact(-0.05) end,
{description = "decrease master width factor", group = "layout"}),
awful.key({ modkey, "Shift" }, "h", function () awful.tag.incnmaster( 1, nil, true) end,
{description = "increase the number of master clients", group = "layout"}),
awful.key({ modkey, "Shift" }, "l", function () awful.tag.incnmaster(-1, nil, true) end,
{description = "decrease the number of master clients", group = "layout"}),
awful.key({ modkey, "Control" }, "h", function () awful.tag.incncol( 1, nil, true) end,
{description = "increase the number of columns", group = "layout"}),
awful.key({ modkey, "Control" }, "l", function () awful.tag.incncol(-1, nil, true) end,
{description = "decrease the number of columns", group = "layout"}),
awful.key({ modkey, }, "space", function () awful.layout.inc( 1) end,
{description = "select next", group = "layout"}),
awful.key({ modkey, "Shift" }, "space", function () awful.layout.inc(-1) end,
{description = "select previous", group = "layout"}),
awful.key({ modkey, "Control" }, "n",
function ()
local c = awful.client.restore()
-- Focus restored client
if c then
c:emit_signal(
"request::activate", "key.unminimize", {raise = true}
)
end
end,
{description = "restore minimized", group = "client"}),
-- Prompt
awful.key({ modkey }, "r",
-- function () awful.screen.focused().mypromptbox:run() end,
function () awful.util.spawn("rofi -modi drun -show drun -show-icons -width 32 -no-click-to-exit",false) end,
{description = "run prompt", group = "launcher"}),
awful.key({ modkey }, "x",
function ()
awful.prompt.run {
prompt = "Run Lua code: ",
textbox = awful.screen.focused().mypromptbox.widget,
exe_callback = awful.util.eval,
history_path = awful.util.get_cache_dir() .. "/history_eval"
}
end,
{description = "lua execute prompt", group = "awesome"}),
-- Menubar
awful.key({ modkey }, "p", function() menubar.show() end,
{description = "show the menubar", group = "launcher"})
)
clientkeys = gears.table.join(
awful.key({ modkey, }, "f",
function (c)
c.fullscreen = not c.fullscreen
c:raise()
end,
{description = "toggle fullscreen", group = "client"}),
awful.key({ modkey, "Shift" }, "c", function (c) c:kill() end,
{description = "close", group = "client"}),
awful.key({ modkey, "Control" }, "space", awful.client.floating.toggle ,
{description = "toggle floating", group = "client"}),
awful.key({ modkey, "Control" }, "Return", function (c) c:swap(awful.client.getmaster()) end,
{description = "move to master", group = "client"}),
awful.key({ modkey, }, "o", function (c) c:move_to_screen() end,
{description = "move to screen", group = "client"}),
awful.key({ modkey, }, "t", function (c) c.ontop = not c.ontop end,
{description = "toggle keep on top", group = "client"}),
awful.key({ modkey, }, "n",
function (c)
-- The client currently has the input focus, so it cannot be
-- minimized, since minimized clients can't have the focus.
c.minimized = true
end ,
{description = "minimize", group = "client"}),
awful.key({ modkey, }, "m",
function (c)
c.maximized = not c.maximized
c:raise()
end ,
{description = "(un)maximize", group = "client"}),
awful.key({ modkey, "Control" }, "m",
function (c)
c.maximized_vertical = not c.maximized_vertical
c:raise()
end ,
{description = "(un)maximize vertically", group = "client"}),
awful.key({ modkey, "Shift" }, "m",
function (c)
c.maximized_horizontal = not c.maximized_horizontal
c:raise()
end ,
{description = "(un)maximize horizontally", group = "client"})
)
-- Bind all key numbers to tags.
-- Be careful: we use keycodes to make it work on any keyboard layout.
-- This should map on the top row of your keyboard, usually 1 to 9.
for i = 1, 9 do
globalkeys = gears.table.join(globalkeys,
-- View tag only.
awful.key({ modkey }, "#" .. i + 9,
function ()
local screen = awful.screen.focused()
local tag = screen.tags[i]
if tag then
tag:view_only()
end
end,
{description = "view tag #"..i, group = "tag"}),
-- Toggle tag display.
awful.key({ modkey, "Control" }, "#" .. i + 9,
function ()
local screen = awful.screen.focused()
local tag = screen.tags[i]
if tag then
awful.tag.viewtoggle(tag)
end
end,
{description = "toggle tag #" .. i, group = "tag"}),
-- Move client to tag.
awful.key({ modkey, "Shift" }, "#" .. i + 9,
function ()
if client.focus then
local tag = client.focus.screen.tags[i]
if tag then
client.focus:move_to_tag(tag)
end
end
end,
{description = "move focused client to tag #"..i, group = "tag"}),
-- Toggle tag on focused client.
awful.key({ modkey, "Control", "Shift" }, "#" .. i + 9,
function ()
if client.focus then
local tag = client.focus.screen.tags[i]
if tag then
client.focus:toggle_tag(tag)
end
end
end,
{description = "toggle focused client on tag #" .. i, group = "tag"})
)
end
clientbuttons = gears.table.join(
awful.button({ }, 1, function (c)
c:emit_signal("request::activate", "mouse_click", {raise = true})
end),
awful.button({ modkey }, 1, function (c)
c:emit_signal("request::activate", "mouse_click", {raise = true})
awful.mouse.client.move(c)
end),
awful.button({ modkey }, 3, function (c)
c:emit_signal("request::activate", "mouse_click", {raise = true})
awful.mouse.client.resize(c)
end)
)
-- Set keys
root.keys(globalkeys)
-- }}}
-- {{{ Rules
-- Rules to apply to new clients (through the "manage" signal).
awful.rules.rules = {
-- All clients will match this rule.
{ rule = { },
properties = { border_width = beautiful.border_width,
border_color = beautiful.border_normal,
focus = awful.client.focus.filter,
raise = true,
keys = clientkeys,
buttons = clientbuttons,
screen = awful.screen.preferred,
placement = awful.placement.no_overlap+awful.placement.no_offscreen
}
},
-- Floating clients.
{ rule_any = {
instance = {
"DTA", -- Firefox addon DownThemAll.
"copyq", -- Includes session name in class.
"pinentry",
},
class = {
"Arandr",
"Blueman-manager",
"Gpick",
"Kruler",
"MessageWin", -- kalarm.
"Sxiv",
"Tor Browser", -- Needs a fixed window size to avoid fingerprinting by screen size.
"Wpa_gui",
"veromix",
"xtightvncviewer"},
-- Note that the name property shown in xprop might be set slightly after creation of the client
-- and the name shown there might not match defined rules here.
name = {
"Event Tester", -- xev.
},
role = {
"AlarmWindow", -- Thunderbird's calendar.
"ConfigManager", -- Thunderbird's about:config.
"pop-up", -- e.g. Google Chrome's (detached) Developer Tools.
}
}, properties = { floating = true }},
-- Add titlebars to normal clients and dialogs
{ rule_any = {type = { "normal", "dialog" }
}, properties = { titlebars_enabled = false }
},
-- Set Firefox to always map on the tag named "2" on screen 1.
-- { rule = { class = "Firefox" },
-- properties = { screen = 1, tag = "2" } },
-- { rule = { class = "Lxterminal" },
-- properties = {
-- screen = "HDMI-0",
-- tags = "WEB"}
-- },
}
-- }}}
-- {{{ Signals
-- Signal function to execute when a new client appears.
client.connect_signal("manage", function (c)
-- Set the windows at the slave,
-- i.e. put it at the end of others instead of setting it master.
if not awesome.startup then awful.client.setslave(c) end
if awesome.startup
and not c.size_hints.user_position
and not c.size_hints.program_position then
-- Prevent clients from being unreachable after screen count changes.
awful.placement.no_offscreen(c)
end
end)
-- Add a titlebar if titlebars_enabled is set to true in the rules.
client.connect_signal("request::titlebars", function(c)
-- buttons for the titlebar
local buttons = gears.table.join(
awful.button({ }, 1, function()
c:emit_signal("request::activate", "titlebar", {raise = true})
awful.mouse.client.move(c)
end),
awful.button({ }, 3, function()
c:emit_signal("request::activate", "titlebar", {raise = true})
awful.mouse.client.resize(c)
end)
)
awful.titlebar(c) : setup {
{ -- Left
awful.titlebar.widget.iconwidget(c),
buttons = buttons,
layout = wibox.layout.fixed.horizontal
},
{ -- Middle
{ -- Title
align = "center",
widget = awful.titlebar.widget.titlewidget(c)
},
buttons = buttons,
layout = wibox.layout.flex.horizontal
},
{ -- Right
awful.titlebar.widget.floatingbutton (c),
awful.titlebar.widget.maximizedbutton(c),
awful.titlebar.widget.stickybutton (c),
awful.titlebar.widget.ontopbutton (c),
awful.titlebar.widget.closebutton (c),
layout = wibox.layout.fixed.horizontal()
},
layout = wibox.layout.align.horizontal
}
end)
-- Enable sloppy focus, so that focus follows mouse.
client.connect_signal("mouse::enter", function(c)
c:emit_signal("request::activate", "mouse_enter", {raise = false})
end)
client.connect_signal("focus", function(c) c.border_color = beautiful.border_focus end)
client.connect_signal("unfocus", function(c) c.border_color = beautiful.border_normal end)
-- }}}
-- Autostart applications
-- awful.spawn.once("qutebrowser", {unique_id = "Qutebrowser" })
-- awful.spawn(terminal, { tag = "MIS" })
-- awful.spawn("microsoft-edge-dev", { tags = "WEB" })
awful.spawn.with_shell("$HOME/.config/awesome/autostart.sh")

131
config/awesome/theme.lua Normal file
View File

@ -0,0 +1,131 @@
---------------------------
-- Default awesome theme --
---------------------------
local theme_assets = require("beautiful.theme_assets")
local xresources = require("beautiful.xresources")
local dpi = xresources.apply_dpi
local gfs = require("gears.filesystem")
local themes_path = gfs.get_themes_dir()
local theme = {}
theme.font = "Hack Nerd Font"
theme.bg_normal = "#222222"
theme.bg_focus = "#535d6c"
theme.bg_urgent = "#ff0000"
theme.bg_minimize = "#444444"
theme.bg_systray = theme.bg_normal
theme.fg_normal = "#aaaaaa"
theme.fg_focus = "#ffffff"
theme.fg_urgent = "#ffffff"
theme.fg_minimize = "#ffffff"
theme.useless_gap = dpi(0)
theme.border_width = dpi(1)
theme.border_normal = "#000000"
theme.border_focus = "#535d6c"
theme.border_marked = "#91231c"
-- There are other variable sets
-- overriding the default one when
-- defined, the sets are:
-- taglist_[bg|fg]_[focus|urgent|occupied|empty|volatile]
-- tasklist_[bg|fg]_[focus|urgent]
-- titlebar_[bg|fg]_[normal|focus]
-- tooltip_[font|opacity|fg_color|bg_color|border_width|border_color]
-- mouse_finder_[color|timeout|animate_timeout|radius|factor]
-- prompt_[fg|bg|fg_cursor|bg_cursor|font]
-- hotkeys_[bg|fg|border_width|border_color|shape|opacity|modifiers_fg|label_bg|label_fg|group_margin|font|description_font]
-- Example:
--theme.taglist_bg_focus = "#ff0000"
-- Generate taglist squares:
local taglist_square_size = dpi(4)
theme.taglist_squares_sel = theme_assets.taglist_squares_sel(
taglist_square_size, theme.fg_normal
)
theme.taglist_squares_unsel = theme_assets.taglist_squares_unsel(
taglist_square_size, theme.fg_normal
)
-- Variables set for theming notifications:
-- notification_font
-- notification_[bg|fg]
-- notification_[width|height|margin]
-- notification_[border_color|border_width|shape|opacity]
-- Variables set for theming the menu:
-- menu_[bg|fg]_[normal|focus]
-- menu_[border_color|border_width]
theme.menu_submenu_icon = themes_path.."default/submenu.png"
theme.menu_height = dpi(15)
theme.menu_width = dpi(100)
-- You can add as many variables as
-- you wish and access them by using
-- beautiful.variable in your rc.lua
--theme.bg_widget = "#cc0000"
-- Define the image to load
theme.titlebar_close_button_normal = themes_path.."default/titlebar/close_normal.png"
theme.titlebar_close_button_focus = themes_path.."default/titlebar/close_focus.png"
theme.titlebar_minimize_button_normal = themes_path.."default/titlebar/minimize_normal.png"
theme.titlebar_minimize_button_focus = themes_path.."default/titlebar/minimize_focus.png"
theme.titlebar_ontop_button_normal_inactive = themes_path.."default/titlebar/ontop_normal_inactive.png"
theme.titlebar_ontop_button_focus_inactive = themes_path.."default/titlebar/ontop_focus_inactive.png"
theme.titlebar_ontop_button_normal_active = themes_path.."default/titlebar/ontop_normal_active.png"
theme.titlebar_ontop_button_focus_active = themes_path.."default/titlebar/ontop_focus_active.png"
theme.titlebar_sticky_button_normal_inactive = themes_path.."default/titlebar/sticky_normal_inactive.png"
theme.titlebar_sticky_button_focus_inactive = themes_path.."default/titlebar/sticky_focus_inactive.png"
theme.titlebar_sticky_button_normal_active = themes_path.."default/titlebar/sticky_normal_active.png"
theme.titlebar_sticky_button_focus_active = themes_path.."default/titlebar/sticky_focus_active.png"
theme.titlebar_floating_button_normal_inactive = themes_path.."default/titlebar/floating_normal_inactive.png"
theme.titlebar_floating_button_focus_inactive = themes_path.."default/titlebar/floating_focus_inactive.png"
theme.titlebar_floating_button_normal_active = themes_path.."default/titlebar/floating_normal_active.png"
theme.titlebar_floating_button_focus_active = themes_path.."default/titlebar/floating_focus_active.png"
theme.titlebar_maximized_button_normal_inactive = themes_path.."default/titlebar/maximized_normal_inactive.png"
theme.titlebar_maximized_button_focus_inactive = themes_path.."default/titlebar/maximized_focus_inactive.png"
theme.titlebar_maximized_button_normal_active = themes_path.."default/titlebar/maximized_normal_active.png"
theme.titlebar_maximized_button_focus_active = themes_path.."default/titlebar/maximized_focus_active.png"
theme.wallpaper = "~/.config/awesome/wallpapers/debian-wallpaper.jpg"
-- You can use your own layout icons like this:
theme.layout_fairh = themes_path.."default/layouts/fairhw.png"
theme.layout_fairv = themes_path.."default/layouts/fairvw.png"
theme.layout_floating = themes_path.."default/layouts/floatingw.png"
theme.layout_magnifier = themes_path.."default/layouts/magnifierw.png"
theme.layout_max = themes_path.."default/layouts/maxw.png"
theme.layout_fullscreen = themes_path.."default/layouts/fullscreenw.png"
theme.layout_tilebottom = themes_path.."default/layouts/tilebottomw.png"
theme.layout_tileleft = themes_path.."default/layouts/tileleftw.png"
theme.layout_tile = themes_path.."default/layouts/tilew.png"
theme.layout_tiletop = themes_path.."default/layouts/tiletopw.png"
theme.layout_spiral = themes_path.."default/layouts/spiralw.png"
theme.layout_dwindle = themes_path.."default/layouts/dwindlew.png"
theme.layout_cornernw = themes_path.."default/layouts/cornernww.png"
theme.layout_cornerne = themes_path.."default/layouts/cornernew.png"
theme.layout_cornersw = themes_path.."default/layouts/cornersww.png"
theme.layout_cornerse = themes_path.."default/layouts/cornersew.png"
-- Generate Awesome icon:
theme.awesome_icon = theme_assets.awesome_icon(
theme.menu_height, theme.bg_focus, theme.fg_focus
)
-- Define the icon theme for application icons. If not set then the icons
-- from /usr/share/icons and /usr/share/icons/hicolor will be used.
theme.icon_theme = nil
return theme
-- vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80

Binary file not shown.

After

Width:  |  Height:  |  Size: 439 KiB

View File

@ -0,0 +1,55 @@
[general]
fontname=Hack Nerd Font Mono 12
selchars=-A-Za-z0-9,./?%&#:_
scrollback=1000
bgcolor=rgb(40,42,54)
fgcolor=rgb(248,248,242)
palette_color_0=rgb(33,34,44)
palette_color_1=rgb(255,85,85)
palette_color_2=rgb(80,250,123)
palette_color_3=rgb(241,250,140)
palette_color_4=rgb(189,147,249)
palette_color_5=rgb(255,121,198)
palette_color_6=rgb(139,233,253)
palette_color_7=rgb(68,71,90)
palette_color_8=rgb(98,114,164)
palette_color_9=rgb(255,85,85)
palette_color_10=rgb(80,250,123)
palette_color_11=rgb(241,250,140)
palette_color_12=rgb(189,147,249)
palette_color_13=rgb(255,121,198)
palette_color_14=rgb(139,233,253)
palette_color_15=rgb(248,248,242)
color_preset=Custom
disallowbold=false
cursorblinks=false
cursorunderline=false
audiblebell=true
tabpos=top
geometry_columns=80
geometry_rows=24
hidescrollbar=true
hidemenubar=true
hideclosebutton=true
hidepointer=false
disablef10=false
disablealt=false
disableconfirm=false
boldbright=false
visualbell=true
[shortcut]
new_window_accel=<Primary><Shift>n
new_tab_accel=<Primary><Shift>t
close_tab_accel=<Primary><Shift>w
close_window_accel=<Primary><Shift>q
copy_accel=<Primary><Shift>c
paste_accel=<Primary><Shift>v
name_tab_accel=<Primary><Shift>i
previous_tab_accel=<Primary>Page_Up
next_tab_accel=<Primary>Page_Down
move_tab_left_accel=<Primary><Shift>Page_Up
move_tab_right_accel=<Primary><Shift>Page_Down
zoom_in_accel=<Primary><Shift>plus
zoom_out_accel=<Primary><Shift>underscore
zoom_reset_accel=<Primary><Shift>parenright

21
config/mpd/mpd.conf Normal file
View File

@ -0,0 +1,21 @@
music_directory "~/Music"
playlist_directory "~/.config/mpd/playlists"
auto_update "yes"
bind_to_address "127.0.0.1"
restore_paused "yes"
max_output_buffer_size "16384"
audio_output {
type "pulse"
name "pulse"
#type "alsa"
#name "ALSA"
}
audio_output {
type "fifo"
name "Visualizer feed"
path "/tmp/mpd.fifo"
format "44100:16:2"
}

28
config/newsboat/config Normal file
View File

@ -0,0 +1,28 @@
auto-reload yes
download-path "~/Music/%h/%n"
max-downloads 3
player "ncmpcpp"
browser qutebrowser
macro i set browser "feh %u"; open-in-browser ; set browser "qutebrowser"
macro w set browser "w3m %u"; open-in-browser ; set browser "qutebrowser"
# col # item # fg # bg
#color background color7 default # the most bottom bar
#color listnormal color7 default # unfocused and without N
#color listnormal_unread color7 default # unfocused and with N
#color listfocus color7 color8 # focused and without N
#color listfocus_unread color7 color8 bold # focused but with N
#color info color0 color1 # bottom and top info bars
color article color15 default # content of an article
# highlights
highlight article "^(Feed|Link):.*$" color14 default bold
highlight article "^(Title|Date|Author):.*$" color11 default bold
highlight article "https?://[^ ]+" color12 default underline
highlight article "\\[[0-9]+\\]" color10 default bold
highlight article "\\[image\\ [0-9]+\\]" color9 default bold
highlight article "^(Flags):.*$" color9 default bold

31
config/newsboat/urls Normal file
View File

@ -0,0 +1,31 @@
# starred Articles
# ctrl-e to flag, s-enter to star it.
# ctrl-e, delete to remove flag
"query:Starred:flags # \"s\""
"query:Unread:unread = \"yes\""
# (Reddit)
# https://reddit.com/r/antiwork.rss "~antiwork" "(Reddit)"
https://reddit.com/r/archlinux.rss "~archlinux" "(Reddit)"
https://reddit.com/r/awesomewm.rss "~awesomewm" "(Reddit)"
https://reddit.com/r/debian.rss "~debian" "(Reddit)"
https://reddit.com/r/devops.rss "~devops" "(Reddit)"
https://reddit.com/r/homelab.rss "~homelab" "(Reddit)"
https://reddit.com/r/linux.rss "~linux" "(Reddit)"
https://reddit.com/r/linuxadmin.rss "~linuxadamin" "(Reddit)"
https://reddit.com/r/powershell.rss "~powershell" "(Reddit)"
https://reddit.com/r/proxmox.rss "~proxmox" "(Reddit)"
https://reddit.com/r/selfhosted.rss "~selfhosted" "(Reddit)"
https://reddit.com/r/sysadmin.rss "~sysadmin" "(Reddit)"
# (Blogs)
https://blog.devolutions.net/feed/rss.xml "~devolutions" "(Blogs)"
# (News)
https://www.news.com.au/content-feeds/latest-news-national/ "~newscomau" "(News)"
https://archlinux.org/feeds/news/ "~archlinuxnews" "(News)"
# (Podcasts)
https://selfhosted.show/rss "~self-hosted" "(Podcasts)"
https://linuxunplugged.com/rss "~linuxunplugged" "(Podcasts)"
https://linuxactionnews.com/rss "~linuxactionnews" "(Podcasts)"

257
config/picom/picom.conf Normal file
View File

@ -0,0 +1,257 @@
# Thank you code_nomad: http://9m.no/ꪯ鵞
# and Arch Wiki contributors: https://wiki.archlinux.org/index.php/Compton
#################################
#
# Backend
#
#################################
# Backend to use: "xrender" or "glx".
# GLX backend is typically much faster but depends on a sane driver.
backend = "glx";
#################################
#
# GLX backend
#
#################################
glx-no-stencil = true;
# GLX backend: Copy unmodified regions from front buffer instead of redrawing them all.
# My tests with nvidia-drivers show a 10% decrease in performance when the whole screen is modified,
# but a 20% increase when only 1/4 is.
# My tests on nouveau show terrible slowdown.
glx-copy-from-front = false;
# GLX backend: Use MESA_copy_sub_buffer to do partial screen update.
# My tests on nouveau shows a 200% performance boost when only 1/4 of the screen is updated.
# May break VSync and is not available on some drivers.
# Overrides --glx-copy-from-front.
# glx-use-copysubbuffermesa = true;
# GLX backend: Avoid rebinding pixmap on window damage.
# Probably could improve performance on rapid window content changes, but is known to break things on some drivers (LLVMpipe).
# Recommended if it works.
glx-no-rebind-pixmap = true;
# GLX backend: GLX buffer swap method we assume.
# Could be undefined (0), copy (1), exchange (2), 3-6, or buffer-age (-1).
# undefined is the slowest and the safest, and the default value.
# copy is fastest, but may fail on some drivers,
# 2-6 are gradually slower but safer (6 is still faster than 0).
# Usually, double buffer means 2, triple buffer means 3.
# buffer-age means auto-detect using GLX_EXT_buffer_age, supported by some drivers.
# Useless with --glx-use-copysubbuffermesa.
# Partially breaks --resize-damage.
# Defaults to undefined.
#glx-swap-method = "undefined";
round-borders = 15;
#################################
#
# Shadows
#
#################################
# Enabled client-side shadows on windows.
shadow = true;
# The blur radius for shadows. (default 12)
shadow-radius = 14;
# The left offset for shadows. (default -15)
shadow-offset-x = -7;
# The top offset for shadows. (default -15)
shadow-offset-y = -7;
# The translucency for shadows. (default .75)
shadow-opacity = .75;
# Set if you want different colour shadows
# shadow-red = 0.0;
# shadow-green = 0.0;
# shadow-blue = 0.0;
# The shadow exclude options are helpful if you have shadows enabled. Due to the way picom draws its shadows, certain applications will have visual glitches
# (most applications are fine, only apps that do weird things with xshapes or argb are affected).
# This list includes all the affected apps I found in my testing. The "! name~=''" part excludes shadows on any "Unknown" windows, this prevents a visual glitch with the XFWM alt tab switcher.
shadow-exclude = [
"! name~=''",
"name = 'Notification'",
"name = 'Plank'",
"name = 'Docky'",
"name = 'Kupfer'",
"name = 'xfce4-notifyd'",
"name = 'cpt_frame_window'",
"name *= 'VLC'",
"name *= 'compton'",
"name *= 'picom'",
"name *= 'Chromium'",
"name *= 'Chrome'",
"name *= 'conky'",
"class_g = 'Firefox' && argb",
"class_g = 'Conky'",
"class_g = 'Kupfer'",
"class_g = 'Synapse'",
"class_g ?= 'Notify-osd'",
"class_g ?= 'Cairo-dock'",
"class_g ?= 'Xfce4-notifyd'",
"class_g ?= 'Xfce4-power-manager'",
"class_g ?= 'ulauncher'",
"class_g ?= 'rofi'",
"_GTK_FRAME_EXTENTS@:c",
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_HIDDEN'"
];
# Avoid drawing shadow on all shaped windows (see also: --detect-rounded-corners)
shadow-ignore-shaped = false;
#################################
#
# Opacity
#
#################################
inactive-opacity = 1;
active-opacity = 1;
frame-opacity = 1;
inactive-opacity-override = false;
opacity-rule = [
"80:class_g = 'copyq'",
"90:name = 'alttab'",
# no opacity on sticky windows
"99:_NET_WM_STATE@:32a *= '_NET_WM_STATE_STICKY'",
"75:class_g = 'kitty'"
];
# Dim inactive windows. (0.0 - 1.0)
inactive-dim = 0.05;
# Do not let dimness adjust based on window opacity.
# inactive-dim-fixed = true;
# Blur background of transparent windows. Bad performance with X Render backend. GLX backend is preferred.
blur-background = false;
# Blur background of opaque windows with transparent frames as well.
#blur-background-frame = true;
# Do not let blur radius adjust based on window opacity.
blur-background-fixed = false;
blur-background-exclude = [
"window_type = 'dock'",
"window_type = 'desktop'"
];
#################################
#
# Fading
#
#################################
# Fade windows during opacity changes.
fading = true;
# The time between steps in a fade in milliseconds. (default 10).
#fade-delta = 4;
#fade-delta = 10;
# Opacity change between steps while fading in. (default 0.028).
#fade-in-step = 0.03;
fade-in-step = 0.056;
# Opacity change between steps while fading out. (default 0.03).
fade-out-step = 0.06;
# Fade windows in/out when opening/closing
# no-fading-openclose = true;
# Specify a list of conditions of windows that should not be faded.
fade-exclude = [
"class_g = 'Conky'"
];
#################################
#
# Other
#
#################################
# Try to detect WM windows and mark them as active.
mark-wmwin-focused = true;
# Mark all non-WM but override-redirect windows active (e.g. menus).
mark-ovredir-focused = true;
# Use EWMH _NET_WM_ACTIVE_WINDOW to determine which window is focused instead of using FocusIn/Out events.
# Usually more reliable but depends on a EWMH-compliant WM.
use-ewmh-active-win = true;
# Detect rounded corners and treat them as rectangular when --shadow-ignore-shaped is on.
detect-rounded-corners = false;
# Detect _NET_WM_OPACITY on client windows, useful for window managers not passing _NET_WM_OPACITY of client windows to frame windows.
# This prevents opacity being ignored for some apps.
# For example without this enabled my xfce4-notifyd is 100% opacity no matter what.
detect-client-opacity = true;
# Vertical synchronization: match the refresh rate of the monitor
vsync = true;
# Enable DBE painting mode, intended to use with VSync to (hopefully) eliminate tearing.
# Reported to have no effect, though.
dbe = false;
# Limit picom to repaint at most once every 1 / refresh_rate second to boost performance.
# This should not be used with --vsync drm/opengl/opengl-oml as they essentially does --sw-opti's job already,
# unless you wish to specify a lower refresh rate than the actual value.
#sw-opti = true;
# Unredirect all windows if a full-screen opaque window is detected, to maximize performance for full-screen windows, like games.
# Known to cause flickering when redirecting/unredirecting windows.
unredir-if-possible = false;
# Specify a list of conditions of windows that should always be considered focused.
focus-exclude = [
"ANTIDIM_FLAG@:8c",
"_NET_WM_STATE@:32a *= '_NET_WM_STATE_STICKY'"
];
# Use WM_TRANSIENT_FOR to group windows, and consider windows in the same group focused at the same time.
detect-transient = true;
# Use WM_CLIENT_LEADER to group windows, and consider windows in the same group focused at the same time.
# WM_TRANSIENT_FOR has higher priority if --detect-transient is enabled, too.
detect-client-leader = true;
#################################
#
# Window type settings
#
#################################
wintypes:
{
tooltip =
{
# fade: Fade the particular type of windows.
fade = true;
# shadow: Give those windows shadow
shadow = false;
# opacity: Default opacity for the type of windows.
opacity = 0.85;
# focus: Whether to always consider windows of this type focused.
focus = true;
};
};
######################
#
# XSync
# See: https://github.com/yshui/picom/commit/b18d46bcbdc35a3b5620d817dd46fbc76485c20d
#
######################
# Use X Sync fence to sync clients' draw calls. Needed on nvidia-drivers with GLX backend for some users.
xrender-sync-fence = true;
animations = true;
animation-stiffness = 300.0;
animation-dampening = 25.0;
animation-clamping = true;
animation-mass = 1;
#animation-window-mass = 1.0;
#animation-delta = 10;
#animation-for-unmap-window = "slide-up";
animation-for-open-window = "zoom";
animation-for-menu-window = "slide-down";
animation-for-transient-window = "slide-down";

View File

@ -0,0 +1,136 @@
# Autogenerated config.py
#
# NOTE: config.py is intended for advanced users who are comfortable
# with manually migrating the config file on qutebrowser upgrades. If
# you prefer, you can also configure qutebrowser using the
# :set/:bind/:config-* commands without having to write a config.py
# file.
#
# Documentation:
# qute://help/configuring.html
# qute://help/settings.html
# Change the argument to True to still load settings configured via autoconfig.yml
config.load_autoconfig(False)
# Which cookies to accept. With QtWebEngine, this setting also controls
# other features with tracking capabilities similar to those of cookies;
# including IndexedDB, DOM storage, filesystem API, service workers, and
# AppCache. Note that with QtWebKit, only `all` and `never` are
# supported as per-domain values. Setting `no-3rdparty` or `no-
# unknown-3rdparty` per-domain on QtWebKit will have the same effect as
# `all`. If this setting is used with URL patterns, the pattern gets
# applied to the origin/first party URL of the page making the request,
# not the request URL. With QtWebEngine 5.15.0+, paths will be stripped
# from URLs, so URL patterns using paths will not match. With
# QtWebEngine 5.15.2+, subdomains are additionally stripped as well, so
# you will typically need to set this setting for `example.com` when the
# cookie is set on `somesubdomain.example.com` for it to work properly.
# To debug issues with this setting, start qutebrowser with `--debug
# --logfilter network --debug-flag log-cookies` which will show all
# cookies being set.
# Type: String
# Valid values:
# - all: Accept all cookies.
# - no-3rdparty: Accept cookies from the same origin only. This is known to break some sites, such as GMail.
# - no-unknown-3rdparty: Accept cookies from the same origin only, unless a cookie is already set for the domain. On QtWebEngine, this is the same as no-3rdparty.
# - never: Don't accept cookies at all.
config.set('content.cookies.accept', 'all', 'chrome-devtools://*')
# Which cookies to accept. With QtWebEngine, this setting also controls
# other features with tracking capabilities similar to those of cookies;
# including IndexedDB, DOM storage, filesystem API, service workers, and
# AppCache. Note that with QtWebKit, only `all` and `never` are
# supported as per-domain values. Setting `no-3rdparty` or `no-
# unknown-3rdparty` per-domain on QtWebKit will have the same effect as
# `all`. If this setting is used with URL patterns, the pattern gets
# applied to the origin/first party URL of the page making the request,
# not the request URL. With QtWebEngine 5.15.0+, paths will be stripped
# from URLs, so URL patterns using paths will not match. With
# QtWebEngine 5.15.2+, subdomains are additionally stripped as well, so
# you will typically need to set this setting for `example.com` when the
# cookie is set on `somesubdomain.example.com` for it to work properly.
# To debug issues with this setting, start qutebrowser with `--debug
# --logfilter network --debug-flag log-cookies` which will show all
# cookies being set.
# Type: String
# Valid values:
# - all: Accept all cookies.
# - no-3rdparty: Accept cookies from the same origin only. This is known to break some sites, such as GMail.
# - no-unknown-3rdparty: Accept cookies from the same origin only, unless a cookie is already set for the domain. On QtWebEngine, this is the same as no-3rdparty.
# - never: Don't accept cookies at all.
config.set('content.cookies.accept', 'all', 'devtools://*')
# Value to send in the `Accept-Language` header. Note that the value
# read from JavaScript is always the global value.
# Type: String
config.set('content.headers.accept_language', '', 'https://matchmaker.krunker.io/*')
# User agent to send. The following placeholders are defined: *
# `{os_info}`: Something like "X11; Linux x86_64". * `{webkit_version}`:
# The underlying WebKit version (set to a fixed value with
# QtWebEngine). * `{qt_key}`: "Qt" for QtWebKit, "QtWebEngine" for
# QtWebEngine. * `{qt_version}`: The underlying Qt version. *
# `{upstream_browser_key}`: "Version" for QtWebKit, "Chrome" for
# QtWebEngine. * `{upstream_browser_version}`: The corresponding
# Safari/Chrome version. * `{qutebrowser_version}`: The currently
# running qutebrowser version. The default value is equal to the
# unchanged user agent of QtWebKit/QtWebEngine. Note that the value
# read from JavaScript is always the global value. With QtWebEngine
# between 5.12 and 5.14 (inclusive), changing the value exposed to
# JavaScript requires a restart.
# Type: FormatString
config.set('content.headers.user_agent', 'Mozilla/5.0 ({os_info}) AppleWebKit/{webkit_version} (KHTML, like Gecko) {upstream_browser_key}/{upstream_browser_version} Safari/{webkit_version}', 'https://web.whatsapp.com/')
# User agent to send. The following placeholders are defined: *
# `{os_info}`: Something like "X11; Linux x86_64". * `{webkit_version}`:
# The underlying WebKit version (set to a fixed value with
# QtWebEngine). * `{qt_key}`: "Qt" for QtWebKit, "QtWebEngine" for
# QtWebEngine. * `{qt_version}`: The underlying Qt version. *
# `{upstream_browser_key}`: "Version" for QtWebKit, "Chrome" for
# QtWebEngine. * `{upstream_browser_version}`: The corresponding
# Safari/Chrome version. * `{qutebrowser_version}`: The currently
# running qutebrowser version. The default value is equal to the
# unchanged user agent of QtWebKit/QtWebEngine. Note that the value
# read from JavaScript is always the global value. With QtWebEngine
# between 5.12 and 5.14 (inclusive), changing the value exposed to
# JavaScript requires a restart.
# Type: FormatString
config.set('content.headers.user_agent', 'Mozilla/5.0 ({os_info}; rv:90.0) Gecko/20100101 Firefox/90.0', 'https://accounts.google.com/*')
# Load images automatically in web pages.
# Type: Bool
config.set('content.images', True, 'chrome-devtools://*')
# Load images automatically in web pages.
# Type: Bool
config.set('content.images', True, 'devtools://*')
# Enable JavaScript.
# Type: Bool
config.set('content.javascript.enabled', True, 'chrome-devtools://*')
# Enable JavaScript.
# Type: Bool
config.set('content.javascript.enabled', True, 'devtools://*')
# Enable JavaScript.
# Type: Bool
config.set('content.javascript.enabled', True, 'chrome://*/*')
# Enable JavaScript.
# Type: Bool
config.set('content.javascript.enabled', True, 'qute://*/*')
# Allow locally loaded documents to access remote URLs.
# Type: Bool
config.set('content.local_content_can_access_remote_urls', True, 'file:///home/mmckinnon/.local/share/qutebrowser/userscripts/*')
# Allow locally loaded documents to access other local URLs.
# Type: Bool
config.set('content.local_content_can_access_file_urls', False, 'file:///home/mmckinnon/.local/share/qutebrowser/userscripts/*')
#Fix Certificate Errors
config.set('content.tls.certificate_errors','ask-block-thirdparty')
config.bind('<Ctrl-c>', 'tab-close')

32
git/gitconfig Normal file
View File

@ -0,0 +1,32 @@
[user]
email = mmckinnon@comprofix.com
name = Matthew McKinnon
[color]
ui = true
[color "branch"]
current = yellow reverse
local = yellow
remote = green
[color "diff"]
meta = yellow bold
frag = magenta bold
old = red bold
new = green bold
[color "status"]
added = yellow
changed = green
untracked = red
[push]
default = simple
[http]
sslverify = false
postBuffer = 524288000
[core]
autocrlf = false

40
install.sh Executable file
View File

@ -0,0 +1,40 @@
#!/bin/bash
# Setup Shell
if [ -n "$($SHELL -c 'echo $ZSH_VERSION')" ]; then
echo "Setting up ZSH"
rm -fr ~/.oh-my-zsh
rm -fr ~/.zshrc
git clone https://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh
ln -s `pwd`/zsh/dracula/dracula.zsh-theme ~/.oh-my-zsh/themes/dracula.zsh-theme
ln -s `pwd`/zsh/zshrc ~/.zshrc
elif [ -n "$($SHELL -c 'echo $BASH_VERSION')" ]; then
rm -fr ~/.bashrc
rm -fr ~/.bash_colors
rm -fr ~/.bash_aliases
ln -s `pwd`/bash/bashrc ~/.bashrc
ln -s `pwd`/bash/bash_colors ~/.bash_colors
ln -s `pwd`/bash/bash_aliases ~/.bash_aliases
fi
# Setup nano
echo "Setup nano"
rm -fr ~/.nano
rm -fr ~/.nanorc
ln -s `pwd`/nano/nanorc ~/.nanorc
ln -s `pwd`/nano ~/.nano
# Setup VIM
echo "Setup VIM"
rm -fr ~/.vim
ln -s `pwd`/vim ~/.vim
# Setup mutt
echo "Setup mutt"
echo "Make sure you generate an oauth2 file - ./mutt_oauth2.py oauth2 --verbose --authorize"
rm -fr ~/.mutt
ln -s `pwd`/mutt ~/.mutt

81
mutt/colors Normal file
View File

@ -0,0 +1,81 @@
# object can be one of:
# * attachment
# * body (match regexp in the body of messages)
# * bold (hiliting bold patterns in the body of messages)
# * error (error messages printed by Mutt)
# * header (match regexp in the message header)
# * hdrdefault (default color of the message header in the pager)
# * index (match pattern in the message index)
# * indicator (arrow or bar used to indicate the current item in a menu)
# * markers (the '+' markers at the beginning of wrapped lines in the pager)
# * message (informational messages)
# * normal (normal (not quoted) text
# * quoted (text matching $quote_regexp in the body of a message)
# * quoted1, quotedN (higher levels of quoting)
# * search (hiliting of words in the pager)
# * signature
# * status (mode lines used to display info about the mailbox or message)
# * tilde (the '~' used to pad blank lines in the pager)
# * tree (thread tree drawn in the message index and attachment menu)
# * underline (hiliting underlined patterns in the body of messages)
#
#
# foreground and background can be one of the following:
# * white
# * black
# * green
# * magenta
# * blue
# * cyan
# * yellow
# * red
# * default
color status color010 color000
color normal color015 color000
color indicator color011 color000
color tree color009 color000
color attachment color009 color000
color signature color005 color000
color quoted color011 color000
color message color015 color000
color tilde color010 color000
color markers color010 color000
color header color011 color000 "(^Date):"
color header color015 color000 "(^From):"
color header color027 color000 "(^To):"
color header color027 color000 "(^Cc):"
color header color202 color000 "(^Subject):"
mono header bold "^(Date|From|To|Cc|Subject):"
color index color013 color000 ~U
color index color009 color000 ~F
color index color027 color000 ~N
color index color001 color000 ~D
color index color000 color009 ~T
mono index bold ~U
mono index bold ~F
mono index bold ~N
mono index bold ~D
mono index bold ~T
color body color011 color000 "<[Ee]?[Bb]?[Gg]>"
color body color011 color000 "<[Bb][Gg]>"
color body color011 color000 "[;:]-*[)>(<|]"
# # URLs
color body color027 color000 "(http|ftp|news|telnet|finger)://[^ \”\t\r\n]*"
color body color027 color000 "mailto:[-a-z_0-9.]+@[-a-z_0-9.]+"
color body color027 color000 "[-a-z_0-9.%$]+@[-a-z_0-9.]+\\.[-a-z][-a-z]+"
mono body bold "(http|ftp|news|telnet|finger)://[^ \”\t\r\n]*"
mono body bold "mailto:[-a-z_0-9.]+@[-a-z_0-9.]+"

26
mutt/comprofix Normal file
View File

@ -0,0 +1,26 @@
set realname = "Matthew McKinnon"
set from = "mmckinnon@comprofix.com"
set imap_user = "mmckinnon@comprofix.com"
set smtp_url="smtp://$imap_user@outlook.office365.com/"
#macro index d "s=Deleted Items\n" "move message to trash"
#macro pager d "C=Deleted Items\n\n<exit><delete-message>" "move message to trash"
set imap_authenticators = "oauthbearer:xoauth2"
set imap_oauth_refresh_command = "~/.mutt/mutt_oauth2.py ~/.mutt/oauth2"
set smtp_authenticators = ${imap_authenticators}
set smtp_oauth_refresh_command = ${imap_oauth_refresh_command}
set folder = "imap://$imap_user@outlook.office365.com/"
set spoolfile = "+Inbox"
set record = "+Sent Items"
set postponed = "+Drafts"
set trash = "+Deleted Items"
set move = no
set imap_check_subscribed = yes
#set imap_list_subscribed = yes
mailboxes "+Inbox" "+Sent Items" "+Deleted Items" "+Drafts"

16
mutt/lang Normal file
View File

@ -0,0 +1,16 @@
# IMAP folders
set my_drafts="Drafts"
set my_drafts_noquote="Drafts"
set my_sent="Sent<quote-char><space>Items"
set my_sent_noquote="Sent Items"
set my_trash="Deleted<quote-char><space>Items"
set my_trash_noquote="Deleted Items"
# Quotation and date formats
set attribution="The %d, %n wrote:"
set date_format="!%m/%d/%Y %H:%M"
# Hours and dates
set charset="utf-8"
set assumed_charset="utf-8"
set send_charset="utf-8:us-ascii"

19
mutt/mailcap Normal file
View File

@ -0,0 +1,19 @@
#text/html; links %s; nametemplate=%s.html
text/html; ( nohup qutebrowser %s > /dev/null 2>&1 & ); nametemplate=%s.html;
text/html; lynx -dump %s; nametemplate=%s.html; copiousoutput;
text/html; links -dump %s -codepage utf-8; nametemplate=%s.html; copiousoutput
text/html; luakit '%s' &; test=test -n "$DISPLAY"; needsterminal;
text/plain; nohup less %s > /dev/null 2>&1 &
application/pdf; { set -m \; /bin/mv -f -T %s %s.mv \; ( evince %s.mv >/dev/null 2>&1 \; /bin/rm -f %s.mv \; ) & } \; disown -a
#image/jpeg; feh %s
#image/gif; feh %s
#image/GIF; feh %s
#image/JPG; feh %s
#image/jpg; feh %s
#image/png; feh %s
image; ( nohup feh %s > /dev/null 2>&1 & )

421
mutt/mutt_oauth2.py Executable file
View File

@ -0,0 +1,421 @@
#!/usr/bin/env python3
#
# Mutt OAuth2 token management script, version 2020-08-07
# Written against python 3.7.3, not tried with earlier python versions.
#
# Copyright (C) 2020 Alexander Perlis
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation; either version 2 of the
# License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
# 02110-1301, USA.
'''Mutt OAuth2 token management'''
import sys
import json
import argparse
import urllib.parse
import urllib.request
import imaplib
import poplib
import smtplib
import base64
import secrets
import hashlib
import time
from datetime import timedelta, datetime
from pathlib import Path
import socket
import http.server
import subprocess
import readline
# The token file must be encrypted because it contains multi-use bearer tokens
# whose usage does not require additional verification. Specify whichever
# encryption and decryption pipes you prefer. They should read from standard
# input and write to standard output. The example values here invoke GPG,
# although won't work until an appropriate identity appears in the first line.
ENCRYPTION_PIPE = ['gpg', '--encrypt', '--recipient', 'Comprofix Oauth2']
DECRYPTION_PIPE = ['gpg', '--decrypt']
registrations = {
'google': {
'authorize_endpoint': 'https://accounts.google.com/o/oauth2/auth',
'devicecode_endpoint': 'https://oauth2.googleapis.com/device/code',
'token_endpoint': 'https://accounts.google.com/o/oauth2/token',
'redirect_uri': 'urn:ietf:wg:oauth:2.0:oob',
'imap_endpoint': 'imap.gmail.com',
'pop_endpoint': 'pop.gmail.com',
'smtp_endpoint': 'smtp.gmail.com',
'sasl_method': 'OAUTHBEARER',
'scope': 'https://mail.google.com/',
'client_id': '',
'client_secret': '',
},
'microsoft': {
'authorize_endpoint': 'https://login.microsoftonline.com/common/oauth2/v2.0/authorize',
'devicecode_endpoint': 'https://login.microsoftonline.com/common/oauth2/v2.0/devicecode',
'token_endpoint': 'https://login.microsoftonline.com/common/oauth2/v2.0/token',
'redirect_uri': 'https://login.microsoftonline.com/common/oauth2/nativeclient',
'tenant': 'common',
'imap_endpoint': 'outlook.office365.com',
'pop_endpoint': 'outlook.office365.com',
'smtp_endpoint': 'smtp.office365.com',
'sasl_method': 'XOAUTH2',
'scope': ('offline_access https://outlook.office.com/IMAP.AccessAsUser.All '
'https://outlook.office.com/POP.AccessAsUser.All '
'https://outlook.office.com/SMTP.Send'),
'client_id': '08162f7c-0fd2-4200-a84a-f25a4db0b584',
'client_secret': 'TxRBilcHdC6WGBee]fs?QR:SJ8nI[g82'
},
}
ap = argparse.ArgumentParser(epilog='''
This script obtains and prints a valid OAuth2 access token. State is maintained in an
encrypted TOKENFILE. Run with "--verbose --authorize" to get started or whenever all
tokens have expired, optionally with "--authflow" to override the default authorization
flow. To truly start over from scratch, first delete TOKENFILE. Use "--verbose --test"
to test the IMAP/POP/SMTP endpoints.
''')
ap.add_argument('-v', '--verbose', action='store_true', help='increase verbosity')
ap.add_argument('-d', '--debug', action='store_true', help='enable debug output')
ap.add_argument('tokenfile', help='persistent token storage')
ap.add_argument('-a', '--authorize', action='store_true', help='manually authorize new tokens')
ap.add_argument('--authflow', help='authcode | localhostauthcode | devicecode')
ap.add_argument('-t', '--test', action='store_true', help='test IMAP/POP/SMTP endpoints')
args = ap.parse_args()
token = {}
path = Path(args.tokenfile)
if path.exists():
if 0o777 & path.stat().st_mode != 0o600:
sys.exit('Token file has unsafe mode. Suggest deleting and starting over.')
try:
sub = subprocess.run(DECRYPTION_PIPE, check=True, input=path.read_bytes(),
capture_output=True)
token = json.loads(sub.stdout)
except subprocess.CalledProcessError:
sys.exit('Difficulty decrypting token file. Is your decryption agent primed for '
'non-interactive usage, or an appropriate environment variable such as '
'GPG_TTY set to allow interactive agent usage from inside a pipe?')
def writetokenfile():
'''Writes global token dictionary into token file.'''
if not path.exists():
path.touch(mode=0o600)
if 0o777 & path.stat().st_mode != 0o600:
sys.exit('Token file has unsafe mode. Suggest deleting and starting over.')
sub2 = subprocess.run(ENCRYPTION_PIPE, check=True, input=json.dumps(token).encode(),
capture_output=True)
path.write_bytes(sub2.stdout)
if args.debug:
print('Obtained from token file:', json.dumps(token))
if not token:
if not args.authorize:
sys.exit('You must run script with "--authorize" at least once.')
print('Available app and endpoint registrations:', *registrations)
token['registration'] = input('OAuth2 registration: ')
token['authflow'] = input('Preferred OAuth2 flow ("authcode" or "localhostauthcode" '
'or "devicecode"): ')
token['email'] = input('Account e-mail address: ')
token['access_token'] = ''
token['access_token_expiration'] = ''
token['refresh_token'] = ''
writetokenfile()
if token['registration'] not in registrations:
sys.exit(f'ERROR: Unknown registration "{token["registration"]}". Delete token file '
f'and start over.')
registration = registrations[token['registration']]
authflow = token['authflow']
if args.authflow:
authflow = args.authflow
baseparams = {'client_id': registration['client_id']}
# Microsoft uses 'tenant' but Google does not
if 'tenant' in registration:
baseparams['tenant'] = registration['tenant']
def access_token_valid():
'''Returns True when stored access token exists and is still valid at this time.'''
token_exp = token['access_token_expiration']
return token_exp and datetime.now() < datetime.fromisoformat(token_exp)
def update_tokens(r):
'''Takes a response dictionary, extracts tokens out of it, and updates token file.'''
token['access_token'] = r['access_token']
token['access_token_expiration'] = (datetime.now() +
timedelta(seconds=int(r['expires_in']))).isoformat()
if 'refresh_token' in r:
token['refresh_token'] = r['refresh_token']
writetokenfile()
if args.verbose:
print(f'NOTICE: Obtained new access token, expires {token["access_token_expiration"]}.')
if args.authorize:
p = baseparams.copy()
p['scope'] = registration['scope']
if authflow in ('authcode', 'localhostauthcode'):
verifier = secrets.token_urlsafe(90)
challenge = base64.urlsafe_b64encode(hashlib.sha256(verifier.encode()).digest())[:-1]
redirect_uri = registration['redirect_uri']
listen_port = 0
if authflow == 'localhostauthcode':
# Find an available port to listen on
s = socket.socket()
s.bind(('127.0.0.1', 0))
listen_port = s.getsockname()[1]
s.close()
redirect_uri = 'http://localhost:'+str(listen_port)+'/'
# Probably should edit the port number into the actual redirect URL.
p.update({'login_hint': token['email'],
'response_type': 'code',
'redirect_uri': redirect_uri,
'code_challenge': challenge,
'code_challenge_method': 'S256'})
print(registration["authorize_endpoint"] + '?' +
urllib.parse.urlencode(p, quote_via=urllib.parse.quote))
authcode = ''
if authflow == 'authcode':
authcode = input('Visit displayed URL to retrieve authorization code. Enter '
'code from server (might be in browser address bar): ')
else:
print('Visit displayed URL to authorize this application. Waiting...',
end='', flush=True)
class MyHandler(http.server.BaseHTTPRequestHandler):
'''Handles the browser query resulting from redirect to redirect_uri.'''
# pylint: disable=C0103
def do_HEAD(self):
'''Response to a HEAD requests.'''
self.send_response(200)
self.send_header('Content-type', 'text/html')
self.end_headers()
def do_GET(self):
'''For GET request, extract code parameter from URL.'''
# pylint: disable=W0603
global authcode
querystring = urllib.parse.urlparse(self.path).query
querydict = urllib.parse.parse_qs(querystring)
if 'code' in querydict:
authcode = querydict['code'][0]
self.do_HEAD()
self.wfile.write(b'<html><head><title>Authorizaton result</title></head>')
self.wfile.write(b'<body><p>Authorization redirect completed. You may '
b'close this window.</p></body></html>')
with http.server.HTTPServer(('127.0.0.1', listen_port), MyHandler) as httpd:
try:
httpd.handle_request()
except KeyboardInterrupt:
pass
if not authcode:
sys.exit('Did not obtain an authcode.')
for k in 'response_type', 'login_hint', 'code_challenge', 'code_challenge_method':
del p[k]
p.update({'grant_type': 'authorization_code',
'code': authcode,
'client_secret': registration['client_secret'],
'code_verifier': verifier})
print('Exchanging the authorization code for an access token')
try:
response = urllib.request.urlopen(registration['token_endpoint'],
urllib.parse.urlencode(p).encode())
except urllib.error.HTTPError as err:
print(err.code, err.reason)
response = err
response = response.read()
if args.debug:
print(response)
response = json.loads(response)
if 'error' in response:
print(response['error'])
if 'error_description' in response:
print(response['error_description'])
sys.exit(1)
elif authflow == 'devicecode':
try:
response = urllib.request.urlopen(registration['devicecode_endpoint'],
urllib.parse.urlencode(p).encode())
except urllib.error.HTTPError as err:
print(err.code, err.reason)
response = err
response = response.read()
if args.debug:
print(response)
response = json.loads(response)
if 'error' in response:
print(response['error'])
if 'error_description' in response:
print(response['error_description'])
sys.exit(1)
print(response['message'])
del p['scope']
p.update({'grant_type': 'urn:ietf:params:oauth:grant-type:device_code',
'client_secret': registration['client_secret'],
'device_code': response['device_code']})
interval = int(response['interval'])
print('Polling...', end='', flush=True)
while True:
time.sleep(interval)
print('.', end='', flush=True)
try:
response = urllib.request.urlopen(registration['token_endpoint'],
urllib.parse.urlencode(p).encode())
except urllib.error.HTTPError as err:
# Not actually always an error, might just mean "keep trying..."
response = err
response = response.read()
if args.debug:
print(response)
response = json.loads(response)
if 'error' not in response:
break
if response['error'] == 'authorization_declined':
print(' user declined authorization.')
sys.exit(1)
if response['error'] == 'expired_token':
print(' too much time has elapsed.')
sys.exit(1)
if response['error'] != 'authorization_pending':
print(response['error'])
if 'error_description' in response:
print(response['error_description'])
sys.exit(1)
print()
else:
sys.exit(f'ERROR: Unknown OAuth2 flow "{token["authflow"]}. Delete token file and '
f'start over.')
update_tokens(response)
if not access_token_valid():
if args.verbose:
print('NOTICE: Invalid or expired access token; using refresh token '
'to obtain new access token.')
if not token['refresh_token']:
sys.exit('ERROR: No refresh token. Run script with "--authorize".')
p = baseparams.copy()
p.update({'client_secret': registration['client_secret'],
'refresh_token': token['refresh_token'],
'grant_type': 'refresh_token'})
try:
response = urllib.request.urlopen(registration['token_endpoint'],
urllib.parse.urlencode(p).encode())
except urllib.error.HTTPError as err:
print(err.code, err.reason)
response = err
response = response.read()
if args.debug:
print(response)
response = json.loads(response)
if 'error' in response:
print(response['error'])
if 'error_description' in response:
print(response['error_description'])
print('Perhaps refresh token invalid. Try running once with "--authorize"')
sys.exit(1)
update_tokens(response)
if not access_token_valid():
sys.exit('ERROR: No valid access token. This should not be able to happen.')
if args.verbose:
print('Access Token: ', end='')
print(token['access_token'])
def build_sasl_string(user, host, port, bearer_token):
'''Build appropriate SASL string, which depends on cloud server's supported SASL method.'''
if registration['sasl_method'] == 'OAUTHBEARER':
return f'n,a={user},\1host={host}\1port={port}\1auth=Bearer {bearer_token}\1\1'
if registration['sasl_method'] == 'XOAUTH2':
return f'user={user}\1auth=Bearer {bearer_token}\1\1'
sys.exit(f'Unknown SASL method {registration["sasl_method"]}.')
if args.test:
errors = False
imap_conn = imaplib.IMAP4_SSL(registration['imap_endpoint'])
sasl_string = build_sasl_string(token['email'], registration['imap_endpoint'], 993,
token['access_token'])
if args.debug:
imap_conn.debug = 4
try:
imap_conn.authenticate(registration['sasl_method'], lambda _: sasl_string.encode())
# Microsoft has a bug wherein a mismatch between username and token can still report a
# successful login... (Try a consumer login with the token from a work/school account.)
# Fortunately subsequent commands fail with an error. Thus we follow AUTH with another
# IMAP command before reporting success.
imap_conn.list()
if args.verbose:
print('IMAP authentication succeeded')
except imaplib.IMAP4.error as e:
print('IMAP authentication FAILED (does your account allow IMAP?):', e)
errors = True
pop_conn = poplib.POP3_SSL(registration['pop_endpoint'])
sasl_string = build_sasl_string(token['email'], registration['pop_endpoint'], 995,
token['access_token'])
if args.debug:
pop_conn.set_debuglevel(2)
try:
# poplib doesn't have an auth command taking an authenticator object
# Microsoft requires a two-line SASL for POP
# pylint: disable=W0212
pop_conn._shortcmd('AUTH ' + registration['sasl_method'])
pop_conn._shortcmd(base64.standard_b64encode(sasl_string.encode()).decode())
if args.verbose:
print('POP authentication succeeded')
except poplib.error_proto as e:
print('POP authentication FAILED (does your account allow POP?):', e.args[0].decode())
errors = True
# SMTP_SSL would be simpler but Microsoft does not answer on port 465.
smtp_conn = smtplib.SMTP(registration['smtp_endpoint'], 587)
sasl_string = build_sasl_string(token['email'], registration['smtp_endpoint'], 587,
token['access_token'])
smtp_conn.ehlo('test')
smtp_conn.starttls()
smtp_conn.ehlo('test')
if args.debug:
smtp_conn.set_debuglevel(2)
try:
smtp_conn.auth(registration['sasl_method'], lambda _=None: sasl_string)
if args.verbose:
print('SMTP authentication succeeded')
except smtplib.SMTPAuthenticationError as e:
print('SMTP authentication FAILED:', e)
errors = True
if errors:
sys.exit(1)

62
mutt/muttrc Normal file
View File

@ -0,0 +1,62 @@
source $HOME/.mutt/colors
source ~/.mutt/comprofix
macro index <f4> '<sync-mailbox><enter-command>source ~/.mutt/comprofix<enter><change-folder>!<enter>'
set move = no
set confirmappend = no
set mailcap_path = $HOME/.mutt/mailcap
set sort = threads
set sort_aux = reverse-last-date-received
#set sort_aux = reverse-date-received
set smart_wrap
set signature=$HOME/.mutt/signature
#alternative_order text/plain test text/html
auto_view text/html
auto_view image/png
auto_view application/x-gunzip
auto_view application/x-gzip
set sidebar_visible = yes
set sidebar_width = 23
#set sidebar_delim = '|'
set sidebar_divider_char = '|'
set sidebar_sort_method = 'path'
set sidebar_short_path = yes
color sidebar_new color027 color000
macro index b '<enter-command>toggle sidebar_visible<enter><refresh>'
macro pager b '<enter-command>toggle sidebar_visible<enter><redraw-screen>'
bind index B bounce-message
set index_format="%3C %Z %[!%d.%m %H:%M] %-35.35L (%5c) %s" # Bronski's favourite
#set index_format="%4C %Z %[!%d %b %y %I:%M%p] %-35.35L (%5c) %s"
#set index_format="%4C %Z %d %-15.15L (%-5c) %s"
set status_chars = " *%A"
set status_format = "───[ Folder: %f ]───[%r%m messages%?n? (%n new)?%?d? (%d to delete)?%?t? (%t tagged)? ]───%>─%?p?( %p postponed )?───"
set pager_index_lines=12
bind index \CP sidebar-prev
bind index \CN sidebar-next
bind index \CO sidebar-open
bind pager \CP sidebar-prev
bind pager \CN sidebar-next
bind pager \CO sidebar-open
# Pretty it up
# # # ----
# # # default list of header fields to weed out when displaying mail
# # # ignore them all and then unignore what you want to see
ignore *
unignore Date To From: Cc Subject X-Tts X-Label
unignore x-mailing-list: posted-to:
unignore x-mailer:
hdr_order Date To From: Cc Subject X-Tts X-Label
#

7
mutt/signature Normal file
View File

@ -0,0 +1,7 @@
Matt McKinnon
Comprofix Support
Web: https://www.comprofix.com
Email: support@comprofix.com
--
For more information, please reread.

1
nano/nanorc Normal file
View File

@ -0,0 +1 @@
include ~/.nano/syntax/ALL.nanorc

900
nano/syntax/ALL.nanorc Normal file
View File

@ -0,0 +1,900 @@
syntax "awk" "\.awk$"
header "^#!.*bin/(env +)?awk( |$)"
color brightyellow "\$[A-Za-z0-9_!@#$*?-]+"
color brightyellow "\<(ARGC|ARGIND|ARGV|BINMODE|CONVFMT|ENVIRON|ERRNO|FIELDWIDTHS)\>"
color brightyellow "\<(FILENAME|FNR|FS|IGNORECASE|LINT|NF|NR|OFMT|OFS|ORS)\>"
color brightyellow "\<(PROCINFO|RS|RT|RSTART|RLENGTH|SUBSEP|TEXTDOMAIN)\>"
color brightblue "\<(function|extension|BEGIN|END)\>"
color red "[-+*/%^|!=&<>?;:]|\\|\[|\]"
color brightblack "\<(for|if|while|do|else|in|delete|exit)\>"
color brightblack "\<(break|continue|return)\>"
color brightblue "\<(close|getline|next|nextfile|print|printf|system|fflush)\>"
color brightblue "\<(atan2|cos|exp|int|log|rand|sin|sqrt|srand)\>"
color brightblue "\<(asort|asorti|gensub|gsub|index|length|match)\>"
color brightblue "\<(split|sprintf|strtonum|sub|substr|tolower|toupper)\>"
color brightblue "\<(mktime|strftime|systime)\>"
color brightblue "\<(and|compl|lshift|or|rshift|xor)\>"
color brightblue "\<(bindtextdomain|dcgettext|dcngettext)\>"
color magenta "/.*[^\]/"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\."
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "c" "\.(c(c|pp|xx)?|C)$" "\.(h(h|pp|xx)?|H)$" "\.ii?$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightyellow "\<[A-Z_][0-9A-Z_]+\>"
color green "\<(float|double|bool|char|int|short|long|void|(un)?signed)\>"
color green "\<[a-z0-9_]+_t\>"
color brightblack "\<(struct|enum|static|const|union|typedef|extern)\>"
color brightblack "\<(for|if|while|do|else|case|default|switch)\>"
color brightblack "\<(return|inline|sizeof|auto|register|volatile|restrict)\>"
color brightblack "\<(try|throw|catch|operator|new|delete)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|^]"
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>|'.'"
color brightyellow "^[[:space:]]*#[[:space:]]*(define|include(_next)?|(un|ifn?)def|endif|el(if|se)|if|warning|error|pragma)"
color magenta "__attribute__[[:space:]]*\(\([^)]*\)\)" "__(aligned|asm|builtin|hidden|inline|packed|restrict|section|typeof|weak)__"
color yellow ""(\\.|[^"])*"|<[A-Za-z_./-]+>"
color magenta "\\([\"'abfnrtv\\]|[0-3]?[0-7]{1,2}|x[A-Fa-f0-9]{1,2}|$)"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "cmake" "CMakeLists\.txt$|\.cmake$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightcyan "\<(ON|OFF|TRUE|FALSE|YES|NO)\>"
color brightyellow "\$\{[A-Za-z0-9_!@#$*?-]+\}"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([()#$^]|\\|\")"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "coffeescript" "\.coffee$"
header "^#!.*/(env +)?coffee"
color red "[!&|=/*+-<>]|\<(and|or|is|isnt|not)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*:[[:space:]]*(->|\()" "->"
color black "[()]"
color brightblack "\<(for|of|continue|break|isnt|null|unless|this|else|if|return)\>"
color brightblack "\<(try|catch|finally|throw|new|delete|typeof|in|instanceof)\>"
color brightblack "\<(debugger|switch|while|do|class|extends|super)\>"
color brightblack "\<(undefined|then|unless|until|loop|of|by|when)\>"
color brightcyan "\<(true|false|yes|no|on|off)\>"
color brightyellow "@[A-Za-z0-9_]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "colortest" "ColorTest$"
color black "\<PLAIN\>"
color red "\<red\>"
color green "\<green\>"
color yellow "\<yellow\>"
color blue "\<blue\>"
color magenta "\<magenta\>"
color cyan "\<cyan\>"
color brightred "\<brightred\>"
color brightgreen "\<brightgreen\>"
color brightyellow "\<brightyellow\>"
color brightblue "\<brightblue\>"
color brightmagenta "\<brightmagenta\>"
color brightcyan "\<brightcyan\>"
syntax "c#" "\.cs$"
# Class
color brightmagenta "class +[A-Za-z0-9]+ *((:) +[A-Za-z0-9.]+)?"
# Annotation
color magenta "@[A-Za-z]+"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(bool|byte|sbyte|char|decimal|double|float|IntPtr|int|uint|long|ulong|object|short|ushort|string|base|this|var|void)\>"
color brightblack "\<(alias|as|case|catch|checked|default|do|dynamic|else|finally|fixed|for|foreach|goto|if|is|lock|new|null|return|switch|throw|try|unchecked|while)\>"
color brightblack "\<(abstract|async|class|const|delegate|enum|event|explicit|extern|get|implicit|in|internal|interface|namespace|operator|out|override|params|partial|private|protected|public|readonly|ref|sealed|set|sizeof|stackalloc|static|struct|typeof|unsafe|using|value|virtual|volatile|yield)\>"
# LINQ-only keywords (ones that cannot be used outside of a LINQ query - lots others can)
color brightblack "\<(from|where|select|group|info|orderby|join|let|in|on|equals|by|ascending|descending)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|]"
color blue "\<([0-9._]+|0x[A-Fa-f0-9_]+|0b[0-1_]+)[FL]?\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([btnfr]|'|\"|\\)"
color magenta "\\u[A-Fa-f0-9]{4}"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "css" "\.s?css$"
# Selectors
color green "\<(a|abbr|address|area|article|aside|audio|b|base|bdo|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|command|datalist|dd|del|details|dfn|div|dl|dt|em|embed|eventsource|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|keygen|label|legend|li|link|mark|map|menu|meta|meter|nav|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|ruby|rp|rt|samp|script|section|select|small|source|span|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|ul|var|video|wbr)\>"
color red "[>+~*]"
color brightyellow "[.#][A-Za-z_][A-Za-z0-9_-]*"
color red ":(active|focus|hover|link|visited|first-child|lang|valid|invalid|not|selection)\>"
color red ":(after|before|first-line|first-letter|root|target)\>"
color yellow "\[[^\[]*\]"
color black start="\{" end="\}"
# Sass
color brightmagenta "(^|[[:space:]])@(include|mixin)\>"
color brightyellow "\$[A-Za-z0-9_-]+"
color brightmagenta "(^|[[:space:]])@(charset|font-face|media|page|import)\>"
color red "[*]"
color brightcyan "\<(above|absolute|always|armenian|auto|avoid|baseline|behind|below|bidi-override|blink|block|bolder|bold|bottom|capitalize|center-left|center-right|center|circle|cjk-ideographic|close-quote|collapse|compact|condensed|continuous|crop|crosshair|cross|cue-after|cue-before|cursive|dashed|decimal|decimal-leading-zero|default|digits|disc|dotted|double|embed|e-resize|expanded|extra-condensed|extra-expanded|fantasy|far-left|far-right|faster|fast|fixed|fixed|georgian|groove|hebrew|help|hide|higher|high|hiragana-iroha|hiragana|inherit|inline|inline-block|inline-table|inset|inside|invert|italic|justify|katakana-iroha|katakana|landscape|large|larger|left|left-side|leftwards|level|lighter|line-through|list-item|loud|lower-alpha|lowercase|lower-greek|lower-latin|lower-roman|lower|low|ltr|marker|medium|medium|middle|mix|monospace|move|narrower|ne-resize|no-close-quote|none|no-open-quote|no-repeat|normal|nowrap|n-resize|nw-resize|oblique|once|open-quote|outset|outside|overline|pointer|portait|relative|repeat-x|repeat-y|repeat|ridge|right-side|right|rightwards|rlt|run-in|sans-serif|scroll|scroll|semi-condensed|semi-expanded|separate|se-resize|serif|show|silent|slower|slow|small-caps|smaller|small|soft|solid|spell-out|square|s-resize|static|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|text-bottom|text|text-top|thick|thin|top|top|transparent|ultra-condensed|ultra-expanded|underline|upper-alpha|uppercase|upper-latin|upper-roman|visible|wait|wider|w-resize|x-fast|x-high|x-large|x-loud|x-low|x-slow|x-small|x-soft|xx-large|xx-small|pre-wrap|break-word)([[:space:];,]|$)"
color brightyellow ":[[:space:]]*(code|hidden|table|pre)\>"
color brightblack "\<(background-attachment|background-clip|background-color|background-image|background-position|background-repeat|background|border-bottom-color|border-bottom-style|border-bottom-width|border-bottom|border-collapse|border-color|border-left-color|border-left-style|border-left-width|border-left|border-radius|border-right-color|border-right-style|border-right-width|border-right|border-spacing|border-style|border-top-color|border-top-style|border-top-width|border-top|border-width|border|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|content|counter-increment|counter-reset|cue-after|cue-before|cue|cursor|direction|display|elevation|empty-cells|float|font-family|font-size-adjust|font-size|font-style|font-variant|font-weight|font|height|left|letter-spacing|line-height|list-style-image|list-style-position|list-style-type|list-style|margin-bottom|margin-left|margin-right|margin-top|margin|marker-offset|marks|max-height|max-width|min-height|min-width|opacity|orphans|outline-color|outline-style|outline-width|outline|overflow|overflow-x|overflow-y|padding-bottom|padding-left|padding-right|padding-top|padding|page-break-after|page-break-before|page-break-inside|page|pause-after|pause-before|pause|pitch-range|pitch|play-during|position|quotes|richness|right|size|speak-header|speak-numerical|speak-punctuation|speak|speech-rate|stress|table-layout|text-align|text-decoration|text-indent|text-shadow|text-transform|top|transition|unicode-bidi|vertical-align|visibility|voice-family|volume|white-space|widows|width|word-spacing|word-wrap|z-index)[[:space:]]*:"
color brightwhite,red "-(ms|moz|apple|khtml|wap|webkit|o|xv)-[a-z][a-z-]+"
color black "[:;,]"
color blue "\<(0|[\+-]?[1-9][0-9]*)"
color blue "[\+-]?([0-9]+|[0-9]*\.[0-9]+)(%|e(m|x)|p(x|t|c)|in|ft|(m|c)m|k?Hz|deg|g?rad|m?s)"
color blue "#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})\>"
color red "\!important\>"
color brightblue "[a-z-]*(-[a-z]+)?\(" "\(|\)"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "cython" "\.(pyx|pxd|pyi)$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(and|as|assert|break|class|continue|def|del|elif|else|except)\>"
color brightblack "\<(exec|finally|for|from|global|if|import|in|is|lambda|not|or)\>"
color brightblack "\<(pass|print|raise|return|try|while|with|yield|None)\>"
color brightblack "\<(DEF|ELIF|ELSE|IF)\>"
color brightblack "\<(cp?def( inline)?|cimport|cppclass|ctypedef|extern|include)\>"
color brightblack "\<(namespace|property|struct)\>"
color green "\<(bint|char|double|int|public|void|unsigned)\>"
color red "[.:;,+*|=!\%@<>/&-]"
color brightyellow "@[A-Za-z0-9_]+"
color brightmagenta "__[A-Za-z0-9_]+__"
color brightcyan "\<(True|False)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "['][^']*[^\\][']" "[']{3}.*[^\\][']{3}"
color yellow "["][^"]*[^\\]["]" "["]{3}.*[^\\]["]{3}"
color yellow start=""""[^"]" end="""""
color yellow start="'''[^']" end="'''"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "default"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "dot" "\.(dot|gv)$"
color brightblack "\<(digraph|edge|graph|node|subgraph)\>"
color magenta "\<(arrowhead|arrowsize|arrowtail|bgcolor|center|color|constraint|decorateP|dir|distortion|fillcolor|fontcolor|fontname|fontsize|headclip|headlabel|height|labelangle|labeldistance|labelfontcolor|labelfontname|labelfontsize|label|layers|layer|margin|mclimit|minlen|name|nodesep|nslimit|ordering|orientation|pagedir|page|peripheries|port_label_distance|rankdir|ranksep|rank|ratio|regular|rotate|samehead|sametail|shapefile|shape|sides|size|skew|style|tailclip|taillabel|URL|weight|width)\>"
color red "=|->|--"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
syntax "email"
color magenta "^>([^>].*|$)"
color blue "^>>([^>].*|$)"
color green "^>>>.*"
syntax "gitconfig" "git(config|modules)$|\.git/config$"
color brightcyan "\<(true|false)\>"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "git-editmsg" "(COMMIT|TAG)_EDITMSG$"
color cyan "^#.*$"
color ,red "[[:space:]]+$"
syntax "git-rebase" "git-rebase-todo$"
color brightblack "^(edit|fixup|pick|reword|squash|exec|[efprsx])\>"
color blue "\<[0-9a-f]{7,40}\>"
color cyan "^#.*"
syntax "glsl" "\.(frag|vert|fp|vp|glsl)$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(void|bool|bvec2|bvec3|bvec4|int|ivec2|ivec3|ivec4|float|vec2|vec3|vec4|mat2|mat3|mat4|struct|sampler1D|sampler2D|sampler3D|samplerCUBE|sampler1DShadow|sampler2DShadow)\>"
color green "\<gl_(DepthRangeParameters|PointParameters|MaterialParameters|LightSourceParameters|LightModelParameters|LightModelProducts|LightProducts|FogParameters)\>"
color brightblack "\<(const|attribute|varying|uniform|in|out|inout|if|else|return|discard|while|for|do)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|^]"
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "go" "\.go$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblue "\<(append|cap|close|complex|copy|delete|imag|len)\>"
color brightblue "\<(make|new|panic|print|println|protect|real|recover)\>"
color green "\<(u?int(8|16|32|64)?|float(32|64)|complex(64|128))\>"
color green "\<(uintptr|byte|rune|string|interface|bool|map|chan|error)\>"
color brightblack "\<(package|import|const|var|type|struct|func|go|defer|nil|iota)\>"
color brightblack "\<(for|range|if|else|case|default|switch|return)\>"
color brightred "\<(go|goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>!~%&|^]|:="
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>|'.'"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\[abfnrtv'\"\\]"
color magenta "\\([0-7]{3}|x[A-Fa-f0-9]{2}|u[A-Fa-f0-9]{4}|U[A-Fa-f0-9]{8})"
color yellow "`[^`]*`"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "html" "\.html?$"
header "<!doctype html"
color magenta "\<(accept|accept-charset|accesskey|action|alt|async|autocomplete|autofocus|autoplay|border|challenge|charset|checked|cite|class|cols|colspan|content|contenteditable|contextmenu|controls|coords|crossorigin|data-[a-z-]+|datetime|default|defer|dir|dirname|disabled|draggable|dropzone|enctype|for|form|formaction|formenctype|formmethod|formnovalidate|formtarget|headers|height|hidden|high|href|hreflang|http-equiv|icon|id|ismap|keytype|kind|label|lang|list|loop|low|manifest|max|maxlength|media|mediagroup|method|min|multiple|muted|name|novalidate|open|optimum|pattern|placeholder|poster|preload|pubdate|radiogroup|readonly|rel|required|reversed|rows|rowspan|sandbox|spellcheck|scope|scoped|seamless|selected|shape|size|sizes|span|src|srcdoc|srclang|start|step|style|tabindex|target|title|type|typemustmatch|usemap|value|width|wrap)\>"
color brightwhite,red "</?[A-Za-z0-9_]+[ >]"
color brightmagenta "</?(a|abbr|address|area|article|aside|audio|b|base|bdo|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|command|datalist|dd|del|details|dfn|div|dl|dt|em|embed|eventsource|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|keygen|label|legend|li|link|mark|map|menu|meta|meter|nav|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|ruby|rp|rt|samp|script|section|select|small|source|span|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|ul|var|video|wbr)[ >]"
color yellow "=([A-Za-z0-9!$%*\^(){}#|:;_~@+,.?/\\-]|\[|\])+"
color red "="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color black start=">" end="<"
color brightmagenta "[<>]"
# Embedded template languages
color brightyellow "\{\{[^}]*\}\}|<%=.*%>"
color brightblue start="<\?" end="\?>"
color brightblue start="<%[^=]" end="%>"
color brightblue start="\{%" end="%\}"
color magenta "&(#[0-9]+|#x[0-9a-fA-F]+|[A-Za-z][A-Za-z0-9]*);"
color cyan start="<!--" end="-->"
color cyan "<!(doctype|DOCTYPE)[^>]*>"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "ini" "\.(ini|desktop|lfl|override)$" "(mimeapps\.list|pinforc|setup\.cfg)$" "weechat/.+\.conf$"
header "^\[[A-Za-z]+\]$"
color brightcyan "\<(true|false)\>"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color red "[=;]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "inputrc" "inputrc$"
color red "\<(off|none)\>"
color green "\<on\>"
color brightblue "\<set|\$include\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "java" "\.java$"
# Class
color brightmagenta "class +[A-Za-z0-9]+ *((implements|extends) +[A-Za-z0-9.]+)?"
# Annotation
color magenta "@[A-Za-z]+"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(boolean|byte|char|double|float|int|long|short|String|void)\>"
color brightblack "\<(case|catch|default|do|else|finally|for|if)\>"
color brightblack "\<(new|return|switch|this|throw|transient|try|while)\>"
color brightblack "\<(abstract|class|extends|final|implements|import|instanceof)\>"
color brightblack "\<(interface|native|package|private|protected|public|static)\>"
color brightblack "\<(strictfp|super|synchronized|throws|volatile|null)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|]"
color blue "\<([0-9._]+|0x[A-Fa-f0-9_]+|0b[0-1_]+)[FL]?\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([btnfr]|'|\"|\\)"
color magenta "\\u[A-Fa-f0-9]{4}"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "JavaScript" "\.js$"
color blue "\<[-+]?([1-9][0-9]*|0[0-7]*|0x[0-9a-fA-F]+)([uU][lL]?|[lL][uU]?)?\>"
color blue "\<[-+]?([0-9]+\.[0-9]*|[0-9]*\.[0-9]+)([EePp][+-]?[0-9]+)?[fFlL]?"
color blue "\<[-+]?([0-9]+[EePp][+-]?[0-9]+)[fFlL]?"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(break|case|catch|continue|default|delete|do|else|finally)\>"
color brightblack "\<(for|function|get|if|in|instanceof|new|return|set|switch)\>"
color brightblack "\<(switch|this|throw|try|typeof|var|void|while|with)\>"
color brightblack "\<(null|undefined|NaN)\>"
color brightcyan "\<(true|false)\>"
color green "\<(Array|Boolean|Date|Enumerator|Error|Function|Math)\>"
color green "\<(Number|Object|RegExp|String)\>"
color red "[-+/*=<>!~%?:&|]"
color magenta "/[^*]([^/]|(\\/))*[^\\]/[gim]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\[0-7][0-7]?[0-7]?|\\x[0-9a-fA-F]+|\\[bfnrt'"\?\\]"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "json" "\.json$"
header "^\{$"
color blue "\<[-]?[1-9][0-9]*([Ee][+-]?[0-9]+)?\>" "\<[-]?[0](\.[0-9]+)?\>"
color brightblack "\<null\>"
color brightcyan "\<(true|false)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\"(\\"|[^"])*\"[[:space:]]*:" "'(\'|[^'])*'[[:space:]]*:"
color magenta "\\u[0-9a-fA-F]{4}|\\[bfnrt'"/\\]"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "keymap" "\.(k|key)?map$|Xmodmap$"
color brightblack "\<(add|clear|compose|keycode|keymaps|keysym|remove|string)\>"
color brightblack "\<(control|alt|shift)\>"
color blue "\<[0-9]+\>"
color red "="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "^!.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "KickStart" "\.ks$" "\.kickstart$"
color brightmagenta "%[a-z]+"
color brightblack "^[[:space:]]*(install|cdrom|text|graphical|volgroup|logvol|reboot|timezone|lang|keyboard|authconfig|firstboot|rootpw|user|firewall|selinux|repo|part|partition|clearpart|bootloader)"
color brightblack "--(name|mirrorlist|baseurl|utc)(=|\>)"
color brightyellow "\$(releasever|basearch)\>"
# Packages and groups
color brightblack "^@[A-Za-z][A-Za-z-]*"
color brightred "^-@[a-zA-Z0-9*-]+"
color red "^-[a-zA-Z0-9*-]+"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "ledger" "(^|\.|/)ledger$"
color brightmagenta "^([0-9]{4}/[0-9]{2}/[0-9]{2}|[=~]) .*"
color blue "^[0-9]{4}/[0-9]{2}/[0-9]{2}"
color brightyellow "^~ .*"
color brightblue "^= .*"
color brightblack "^[[:space:]]+\(?[A-Za-z ]+(:[A-Za-z ]+)*\)?"
color red "[*]"
color cyan "^[[:space:]]*;.*"
syntax "lisp" "(emacs|zile)$" "\.(el|li?sp|scm|ss)$"
color brightblue "\([a-z-]+"
color red "\(([-+*/<>]|<=|>=)|'"
color black "\("
color blue "\<[0-9]+\>"
icolor brightblack "\<nil\>"
color brightcyan "\<[tT]\>"
color yellow "\"(\\.|[^"])*\""
color magenta "'[A-Za-z][A-Za-z0-9_-]+"
color magenta "\\.?"
color cyan "(^|[[:space:]]);.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "lua" "\.lua$"
header "^#!.*lua(jit)?$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*([({'"]|\[=*\[)"
color brightblack "\<(do|end|while|repeat|until|if|elseif|then|else)\>"
color brightblack "\<(for|in|function|local|return|nil)\>"
color brightred "\<(goto|break)\>"
color brightcyan "\<(true|false)\>"
color red "[-+:*/%^=#<>]|~=|\.\.|\[|\]|\<(not|and|or)\>"
color brightwhite,red "[`!@$&|?]|!="
color black "\.{3,}|[({'"]"
color blue "\<([0-9]+)(\.[0-9]+)?([Ee][+-]?[0-9]+)?\>|0x[0-9a-fA-F]*"
color brightmagenta "::[A-Za-z_][A-Za-z0-9_]*::"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([0-9]{1,3}|x[A-Fa-f0-9]{2}|[abefntrv'"\\]|\[|\])"
color yellow start="\[\[" end="\]\]"
color yellow start="\[=\[" end="\]=\]"
color yellow start="\[==\[" end="\]==\]"
color cyan "^#!.*" "(^|[[:space:]])\-\-.*$"
color cyan start="\-\-\[\[" end="\]\]"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "makefile" "([Mm]akefile|\.ma?k)$"
header "^#!.*/(env +)?[bg]?make( |$)"
color brightblack "\<(ifeq|ifdef|ifneq|ifndef|else|endif)\>"
color brightblack "^(export|include|override)\>"
color brightmagenta "^[^:= ]+:"
color red "[=,%]" "\+=|\?=|:=|&&|\|\|"
color brightblue "\$\((abspath|addprefix|addsuffix|and|basename|call|dir)[[:space:]]"
color brightblue "\$\((error|eval|filter|filter-out|findstring|firstword)[[:space:]]"
color brightblue "\$\((flavor|foreach|if|info|join|lastword|notdir|or)[[:space:]]"
color brightblue "\$\((origin|patsubst|realpath|shell|sort|strip|suffix)[[:space:]]"
color brightblue "\$\((value|warning|wildcard|word|wordlist|words)[[:space:]]"
color black "[()$]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\$+(\{[^} ]+\}|\([^) ]+\))"
color brightyellow "\$[@^<*?%|+]|\$\([@^<*?%+-][DF]\)"
color magenta "\$\$|\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color cyan "^ @#.*"
# Show trailing whitespace
color ,green "[[:space:]]+$"
syntax "man" "\.[1-9]x?$"
color brightmagenta "\.(S|T)H.*$"
color brightblack "\.(BR?|I[PR]?).*$"
color brightyellow "\.(S|T)H|\.TP|\.(BR?|I[PR]?|PP)|\\f[BIPR]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "\.(br|DS|RS|RE|PD)"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "markdown" "\.(md|mkd|mkdn|markdown)$"
# Emphasis
color green "(^|[[:space:]])(_[^ ][^_]*_|\*[^ ][^*]*\*)"
# Strong emphasis
color brightgreen "(^|[[:space:]])(__[^ ][^_]*__|\*\*[^ ][^*]*\*\*)"
color brightmagenta "^=====*$|^-----*$|^#{1,6}.*"
color blue "^[[:space:]]*[\*+-] |^[[:space:]]*[0-9]+\. "
color black "^[[:space:]]+"
color magenta "\(([CcRr]|[Tt][Mm])\)" "\.{3}" "(^|[[:space:]])\-\-($|[[:space:]])"
color brightyellow "\!?\[[^]]*\]([[:space:]]*\[[^]]*\]|\(.*\))?"
color brightyellow "^\[.*\]:[[:space:]]*[^"]*"
color yellow "`[^`]*`|^ {4}[^-+*].*"
color cyan "^>.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "mpdconf" "mpd\.conf$"
color brightblack "\<(user|group|bind_to_address|host|port|plugin|name|type)\>"
color brightblack "\<((music|playlist)_directory|(db|log|state|pid|sticker)_file)\>"
color brightmagenta "^(input|audio_output|decoder)[[:space:]]*\{|\}"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "nanorc" "nanorc$"
header "^syntax +\""
color green "^i?color[[:space:]]*(bright)?(white|black|red|blue|green|yellow|magenta|cyan)?(,(white|black|red|blue|green|yellow|magenta|cyan))?\>"
color brightblack "^(set|unset)[[:space:]]+(allow_insecure_backup|autoindent|backup|backupdir|backwards|boldtext|brackets|casesensitive|const|cut|fill|historylog|matchbrackets|morespace|mouse|multibuffer|noconvert|nofollow|nohelp|nonewlines|nowrap|operatingdir|poslog|preserve|punct)\>" "^[[:space:]]*(set|unset)[[:space:]]+(quickblank|quotestr|rebinddelete|rebindkeypad|regexp|smarthome|smooth|softwrap|speller|suspend|suspendenable|tabsize|tabstospaces|tempfile|undo|view|whitespace|wordbounds)\>"
color brightblack "^(bind|i?color|set|unset|syntax|header|magic)\>"
color red "^unbind\>"
color brightblack "^i?color\>" "\<(start|end)="
color brightyellow "^include\>"
color brightblack "^(PLAIN|TYPE|STRING|MACRO|NUMBER|VARIABLE|OPERATOR|~?KEYWORD):"
color brightblack "^(BOOLEAN|SECTION|REGEXP|FUNCTION|ESCAPE|COMMENT|WARNING|JUMP):"
color brightblack "^(TAG|ATTRIBUTE):"
color brightyellow "^\+(TODO|LINT|STRING|BOOLEAN|FUNCTION|INI|(C|HASH)COMMENT)$"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "nginx" "nginx.*\.conf$" "\.nginx$"
header "^(server|upstream)[a-z ]*\{$"
color brightmagenta "\<(events|server|http|location|upstream)[[:space:]]*\{"
color brightblack "(^|[[:space:]{;])(access_log|add_after_body|add_before_body|add_header|addition_types|aio|alias|allow|ancient_browser|ancient_browser_value|auth_basic|auth_basic_user_file|autoindex|autoindex_exact_size|autoindex_localtime|break|charset|charset_map|charset_types|chunked_transfer_encoding|client_body_buffer_size|client_body_in_file_only|client_body_in_single_buffer|client_body_temp_path|client_body_timeout|client_header_buffer_size|client_header_timeout|client_max_body_size|connection_pool_size|create_full_put_path|daemon|dav_access|dav_methods|default_type|deny|directio|directio_alignment|disable_symlinks|empty_gif|env|error_log|error_page|expires|fastcgi_buffer_size|fastcgi_buffers|fastcgi_busy_buffers_size|fastcgi_cache|fastcgi_cache_bypass|fastcgi_cache_key|fastcgi_cache_lock|fastcgi_cache_lock_timeout|fastcgi_cache_min_uses|fastcgi_cache_path|fastcgi_cache_use_stale|fastcgi_cache_valid|fastcgi_connect_timeout|fastcgi_hide_header|fastcgi_ignore_client_abort|fastcgi_ignore_headers|fastcgi_index|fastcgi_intercept_errors|fastcgi_keep_conn|fastcgi_max_temp_file_size|fastcgi_next_upstream|fastcgi_no_cache|fastcgi_param|fastcgi_pass|fastcgi_pass_header|fastcgi_read_timeout|fastcgi_send_timeout|fastcgi_split_path_info|fastcgi_store|fastcgi_store_access|fastcgi_temp_file_write_size|fastcgi_temp_path|flv|geo|geoip_city|geoip_country|gzip|gzip_buffers|gzip_comp_level|gzip_disable|gzip_http_version|gzip_min_length|gzip_proxied|gzip_static|gzip_types|gzip_vary|if|if_modified_since|ignore_invalid_headers|image_filter|image_filter_buffer|image_filter_jpeg_quality|image_filter_sharpen|image_filter_transparency|include|index|internal|ip_hash|keepalive|keepalive_disable|keepalive_requests|keepalive_timeout|large_client_header_buffers|limit_conn|limit_conn_log_level|limit_conn_zone|limit_except|limit_rate|limit_rate_after|limit_req|limit_req_log_level|limit_req_zone|limit_zone|lingering_close|lingering_time|lingering_timeout|listen|location|log_format|log_not_found|log_subrequest|map|map_hash_bucket_size|map_hash_max_size|master_process|max_ranges|memcached_buffer_size|memcached_connect_timeout|memcached_next_upstream|memcached_pass|memcached_read_timeout|memcached_send_timeout|merge_slashes|min_delete_depth|modern_browser|modern_browser_value|mp4|mp4_buffer_size|mp4_max_buffer_size|msie_padding|msie_refresh|open_file_cache|open_file_cache_errors|open_file_cache_min_uses|open_file_cache_valid|open_log_file_cache|optimize_server_names|override_charset|pcre_jit|perl|perl_modules|perl_require|perl_set|pid|port_in_redirect|postpone_output|proxy_buffer_size|proxy_buffering|proxy_buffers|proxy_busy_buffers_size|proxy_cache|proxy_cache_bypass|proxy_cache_key|proxy_cache_lock|proxy_cache_lock_timeout|proxy_cache_min_uses|proxy_cache_path|proxy_cache_use_stale|proxy_cache_valid|proxy_connect_timeout|proxy_cookie_domain|proxy_cookie_path|proxy_hide_header|proxy_http_version|proxy_ignore_client_abort|proxy_ignore_headers|proxy_intercept_errors|proxy_max_temp_file_size|proxy_next_upstream|proxy_no_cache|proxy_pass|proxy_pass_header|proxy_read_timeout|proxy_redirect|proxy_send_timeout|proxy_set_header|proxy_ssl_session_reuse|proxy_store|proxy_store_access|proxy_temp_file_write_size|proxy_temp_path|random_index|read_ahead|real_ip_header|recursive_error_pages|request_pool_size|reset_timedout_connection|resolver|resolver_timeout|return|rewrite|root|satisfy|satisfy_any|secure_link_secret|send_lowat|send_timeout|sendfile|sendfile_max_chunk|server|server|server_name|server_name_in_redirect|server_names_hash_bucket_size|server_names_hash_max_size|server_tokens|set|set_real_ip_from|source_charset|split_clients|ssi|ssi_silent_errors|ssi_types|ssl|ssl_certificate|ssl_certificate_key|ssl_ciphers|ssl_client_certificate|ssl_crl|ssl_dhparam|ssl_engine|ssl_prefer_server_ciphers|ssl_protocols|ssl_session_cache|ssl_session_timeout|ssl_verify_client|ssl_verify_depth|sub_filter|sub_filter_once|sub_filter_types|tcp_nodelay|tcp_nopush|timer_resolution|try_files|types|types_hash_bucket_size|types_hash_max_size|underscores_in_headers|uninitialized_variable_warn|upstream|user|userid|userid_domain|userid_expires|userid_name|userid_p3p|userid_path|userid_service|valid_referers|variables_hash_bucket_size|variables_hash_max_size|worker_priority|worker_processes|worker_rlimit_core|worker_rlimit_nofile|working_directory|xml_entities|xslt_stylesheet|xslt_types)([[:space:]]|$)"
color black "[{}]"
color brightcyan "\<(on|off)\>"
color brightyellow "\$[A-Za-z][A-Za-z0-9_]*"
color red "[*]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow start="'$" end="';$"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "patch" "\.(patch|diff)$"
color brightgreen "^\+.*"
color green "^\+\+\+.*"
color brightred "^-.*"
color red "^---.*"
color blue "^@@.*"
color magenta "^diff.*"
syntax "peg" "\.l?peg$"
color brightblack "^[[:space:]]*[A-Za-z][A-Za-z0-9_]*[[:space:]]*<-"
color blue "\^[+-]?[0-9]+"
color red "[-+*?^/!&]|->|<-|=>"
color brightyellow "%[A-Za-z][A-Za-z0-9_]*"
color magenta "\[[^]]*\]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])\-\-.*$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "php" "\.php[2345s~]?$"
header "^(//|/\*).*[Pp][Hh][Pp]|<\?php\>"
color red "[-+/*=<>?:!~%&|]"
color brightmagenta "(<\?(php)?|\?>)"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(float|global|double|bool|char|int|enum|const)\>"
color brightblack "\<(class|new|private|public|function|for|foreach|if|while|do|var)\>"
color brightblack "\<(return|else|elseif|case|default|switch)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\$[A-Za-z_][A-Za-z0-9_]*"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "pkgbuild" "PKGBUILD$" "\.install$"
color brightblue "^[A-Za-z0-9_+-]+[[:space:]]*\(\)"
color brightblack "\<(case|do|done|elif|else|esac|fi|for|function|if)\>"
color brightblack "\<(in|select|then|time|until|while)\>"
color brightblue "\<(echo|exit|export|let|local|read|return|set|shift|umask|unset)\>"
color green "\<(pkgname|pkgver|pkgrel|epoch|pkgdesc|arch|url|license)\>"
color green "\<(groups|depends|makedepends|checkdepends|optdepends)\>"
color green "\<(provides|conflicts|replaces|backup|options|^install)\>"
color green "\<(changelog|source|noextract)\>"
color green "\<(md5sums|sha1sums|sha256sums|sha384sums|sha512sums)\>"
color green "\<(srcdir|pkgdir)\>"
color brightyellow "\<(strip|docs|libtool|emptydirs|zipman|purge|upx)\>"
color brightyellow "\<(ccache|distcc|buildflags|makeflags)\>"
color red "[{}()<>!=&|;`$]|\\|\[|\]|-(eq|ne|gt|lt|ge|le|s|n|z)\>"
color yellow ""(\\.|[^"])*""
color brightyellow "\$\{?[A-Za-z0-9_!@#$*?-]+\}?|`[^`]*`"
color yellow "'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "pkg-config" "\.pc$"
color brightblack "^(Name|Description|URL|Version|Conflicts|Cflags):"
color brightblack "^(Requires|Libs)(\.private)?:"
color red "="
color brightyellow "\$\{[A-Za-z_][A-Za-z0-9_]*\}"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "po" "\.pot?$"
color brightblack "\<(msgid|msgstr)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "privoxy-config" "privoxy/config$"
color brightblack "(accept-intercepted-requests|actionsfile|admin-address|allow-cgi-request-crunching|buffer-limit|compression-level|confdir|connection-sharing|debug|default-server-timeout|deny-access|enable-compression|enable-edit-actions|enable-remote-http-toggle|enable-remote-toggle|enforce-blocks|filterfile|forward|forwarded-connect-retries|forward-socks4|forward-socks4a|forward-socks5|handle-as-empty-doc-returns-ok|hostname|keep-alive-timeout|listen-address|logdir|logfile|max-client-connections|permit-access|proxy-info-url|single-threaded|socket-timeout|split-large-forms|templdir|toggle|tolerate-pipelining|trustfile|trust-info-url|user-manual)[[:space:]]"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "privoxy-action" "\.action$"
color brightred "[{[:space:]]\-block([[:space:]{}]|$)"
color brightgreen "[{[:space:]]\+block([[:space:]{}]|$)"
color brightred "-(add-header|change-x-forwarded-for|client-header-filter|client-header-tagger|content-type-overwrite|crunch-client-header|crunch-if-none-match|crunch-incoming-cookies|crunch-outgoing-cookies|crunch-server-header|deanimate-gifs|downgrade-http-version|fast-redirects|filter|force-text-mode|forward-override|handle-as-empty-document|handle-as-image|hide-accept-language|hide-content-disposition|hide-from-header|hide-if-modified-since|hide-referrer|hide-user-agent|limit-connect|overwrite-last-modified|prevent-compression|redirect|server-header-filter|server-header-tagger|session-cookies-only|set-image-blocker)"
color brightgreen "\+(add-header|change-x-forwarded-for|client-header-filter|client-header-tagger|content-type-overwrite|crunch-client-header|crunch-if-none-match|crunch-incoming-cookies|crunch-outgoing-cookies|crunch-server-header|deanimate-gifs|downgrade-http-version|fast-redirects|filter|force-text-mode|forward-override|handle-as-empty-document|handle-as-image|hide-accept-language|hide-content-disposition|hide-from-header|hide-if-modified-since|hide-referrer|hide-user-agent|limit-connect|overwrite-last-modified|prevent-compression|redirect|server-header-filter|server-header-tagger|session-cookies-only|set-image-blocker)"
color black "[{}]"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "privoxy-filter" "\.filter$"
color brightblack "^(FILTER|CLIENT-HEADER-FILTER|CLIENT-HEADER-TAGGER|SERVER-HEADER-FILTER|SERVER-HEADER-TAGGER): [a-z-]+"
color brightblue "^(FILTER|CLIENT-HEADER-FILTER|CLIENT-HEADER-TAGGER|SERVER-HEADER-FILTER|SERVER-HEADER-TAGGER):"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "properties" "\.properties$"
color brightblack "^[[:space:]]*[^#!]([^:= ]|\\[:= ])*[:= ]"
color red "[:=]"
color magenta "\\([#!=: ]|$)"
color magenta "\\u[[:xdigit:]]{4}"
color cyan "^[[:space:]]*[#!].*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "python" "\.py$" "jhbuildrc$"
header "^#!.*/(env +)?python[-0-9._]*( |$)"
color brightblack "\<(as|assert|break|class|continue|def|del|elif|else|except)\>"
color brightblack "\<(exec|finally|for|from|global|if|import|lambda)\>"
color brightblack "\<(pass|print|raise|return|try|while|with|yield|None)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color red "[-+*/|=%<>&~^]|\<(and|not|or|is|in)\>"
color brightyellow "@[A-Za-z0-9_]+"
color brightmagenta "__[A-Za-z0-9_]+__"
color brightcyan "\<(True|False)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "['][^']*[^\\][']" "[']{3}.*[^\\][']{3}"
color yellow "["][^"]*[^\\]["]" "["]{3}.*[^\\]["]{3}"
color yellow start=""""[^"]" end="""""
color yellow start="'''[^']" end="'''"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "rpmspec" "\.spec$" "\.rpmspec$"
color brightblack "\<(Icon|ExclusiveOs|ExcludeOs):"
color brightblack "\<(BuildArch|BuildArchitectures|ExclusiveArch|ExcludeArch):"
color brightblack "\<(Conflicts|Obsoletes|Provides|Requires|Requires\(.*\)|Enhances|Suggests|BuildConflicts|BuildRequires|Recommends|PreReq|Supplements):"
color brightblack "\<(Epoch|Serial|Nosource|Nopatch):"
color brightblack "\<(AutoReq|AutoProv|AutoReqProv):"
color brightblack "\<(Copyright|License|Summary|Summary\(.*\)|Distribution|Vendor|Packager|Group|Source[0-9]*|Patch[0-9]*|BuildRoot|Prefix):"
color brightblack "\<(Name|Version|Release|Url|URL):"
color brightblack start="^(Source|Patch)" end=":"
color brightblack "(i386|i486|i586|i686|athlon|ia64|alpha|alphaev5|alphaev56|alphapca56|alphaev6|alphaev67|sparc|sparcv9|sparc64armv3l|armv4b|armv4lm|ips|mipsel|ppc|ppc|iseries|ppcpseries|ppc64|m68k|m68kmint|Sgi|rs6000|i370|s390x|s390|noarch)"
color brightblack "(ifarch|ifnarch|ifos|ifnos)"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "%(if|else|endif|define|global|undefine)"
color brightyellow "%_?([A-Z_a-z_0-9_]*)"
color brightyellow start="%\{" end="\}"
color brightyellow start="%\{__" end="\}"
color brightyellow "\$(RPM_BUILD_ROOT)\>"
color brightmagenta "^%(build$|changelog|check$|clean$|description)"
color brightmagenta "^%(files|install$|package|prep$)"
color brightmagenta "^%(pre|preun|pretrans|post|postun|posttrans)"
color brightmagenta "^%(trigger|triggerin|triggerpostun|triggerun|verifyscript)"
color cyan "(^|[[:space:]])#([^{].*)?$"
color blue "^\*.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
color brightwhite,cyan "TODO:?"
syntax "ruby" "\.rb$|Rakefile$"
color brightblack "\<(BEGIN|END|alias|and|begin|break|case|class|def|defined\?|do|else|elsif|end|ensure|false|for|if|in|module|next|nil|not|or|redo|rescue|retry|return|self|super|then|true|undef|unless|until|when|while|yield)\>"
color yellow "(^|[[:space:]]):[A-Za-z0-9_]+\>"
color magenta "/([^/]|(\\/))*/[iomx]*" "%r\{([^}]|(\\}))*\}[iomx]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color cyan start="^=begin$" end="^=end$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "sed" "\.sed$"
header "^#!.*bin/(env +)?sed( |$)"
color red "[|^$.*+]"
color brightyellow "\{[0-9]+,?[0-9]*\}"
color magenta "\\."
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "sh" "\.sh$" "\.bash$" "bashrc$" "bash_profile$"
header "^#!.*/(env +)?(ba|k|pdk)?sh[-0-9_]*( |$)"
color brightblue "^[A-Za-z0-9_+-]+[[:space:]]*\(\)"
color brightblack "\<(case|do|done|elif|else|esac|fi|for|function|if)\>"
color brightblack "\<(in|select|then|time|until|while)\>"
color brightblue "\<(echo|exit|export|let|local|read|return|set|shift|umask|unset)\>"
color brightblue "\<(source)\>"
color red "[{}()<>!=&|;`$]|\\|\[|\]|-(eq|ne|gt|lt|ge|le|s|n|z)\>"
color yellow ""(\\.|[^"])*""
color brightyellow "\$\{?[A-Za-z0-9_!@#$*?-]+\}?|`[^`]*`"
color yellow "'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "sql" "\.sql$" "sqliterc$"
icolor brightblack "\<(ALL|ASC|AS|ALTER|AND|ADD|AUTO_INCREMENT)\>"
icolor brightblack "\<(BETWEEN|BINARY|BOTH|BY|BOOLEAN)\>"
icolor brightblack "\<(CHANGE|CHECK|COLUMNS|COLUMN|CROSS|CREATE)\>"
icolor brightblack "\<(DATABASES|DATABASE|DATA|DELAYED|DESCRIBE|DESC|DISTINCT|DELETE|DROP|DEFAULT)\>"
icolor brightblack "\<(ENCLOSED|ESCAPED|EXISTS|EXPLAIN)\>"
icolor brightblack "\<(FIELDS|FIELD|FLUSH|FOR|FOREIGN|FUNCTION|FROM)\>"
icolor brightblack "\<(GROUP|GRANT|HAVING)\>"
icolor brightblack "\<(IGNORE|INDEX|INFILE|INSERT|INNER|INTO|IDENTIFIED|IN|IS|IF)\>"
icolor brightblack "\<(JOIN|KEYS|KILL|KEY)\>"
icolor brightblack "\<(LEADING|LIKE|LIMIT|LINES|LOAD|LOCAL|LOCK|LOW_PRIORITY|LEFT|LANGUAGE)\>"
icolor brightblack "\<(MODIFY|NATURAL|NOT|NULL|NEXTVAL)\>"
icolor brightblack "\<(OPTIMIZE|OPTION|OPTIONALLY|ORDER|OUTFILE|OR|OUTER|ON)\>"
icolor brightblack "\<(PROCEDURE|PROCEDURAL|PRIMARY)\>"
icolor brightblack "\<(READ|REFERENCES|REGEXP|RENAME|REPLACE|RETURN|REVOKE|RLIKE|RIGHT)\>"
icolor brightblack "\<(SHOW|SONAME|STATUS|STRAIGHT_JOIN|SELECT|SETVAL|SET)\>"
icolor brightblack "\<(TABLES|TERMINATED|TO|TRAILING|TRUNCATE|TABLE|TEMPORARY|TRIGGER|TRUSTED)\>"
icolor brightblack "\<(UNIQUE|UNLOCK|USE|USING|UPDATE|VALUES|VARIABLES|VIEW)\>"
icolor brightblack "\<(WITH|WRITE|WHERE|ZEROFILL|TYPE|XOR)\>"
color green "\<(VARCHAR|TINYINT|TEXT|DATE|SMALLINT|MEDIUMINT|INT|INTEGER|BIGINT|FLOAT|DOUBLE|DECIMAL|DATETIME|TIMESTAMP|TIME|YEAR|UNSIGNED|CHAR|TINYBLOB|TINYTEXT|BLOB|MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT|ENUM|BOOL|BINARY|VARBINARY)\>"
# SQLite meta commands
icolor brightblack "\.\<(databases|dump|echo|exit|explain|header(s)?|help)\>"
icolor brightblack "\.\<(import|indices|mode|nullvalue|output|prompt|quit|read)\>"
icolor brightblack "\.\<(schema|separator|show|tables|timeout|width)\>"
color brightcyan "\<(ON|OFF)\>"
color blue "\<([0-9]+)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "`(\\.|[^\\`])*`"
color cyan "\-\-.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "systemd" "\.(service|socket|mount|slice|target|timer|path)$"
header "^\[Unit\]$"
color brightblack "^(Accept|After|Alias|AllowIsolate|Also|ANSI_COLOR|_AUDIT_LOGINUID|_AUDIT_SESSION|Backlog|Before|BindIPv6Only|BindsTo|BindToDevice|BlockIOReadBandwidth|BlockIOWeight|BlockIOWriteBandwidth|_BOOT_ID|Broadcast|BUG_REPORT_URL|BusName|Capabilities|CapabilityBoundingSet|CHASSIS|cipher|class|_CMDLINE|CODE_FILE|CODE_FUNC|CODE_LINE|_COMM|Compress|ConditionACPower|ConditionCapability|ConditionDirectoryNotEmpty|ConditionFileIsExecutable|ConditionFileNotEmpty|ConditionHost|ConditionKernelCommandLine|ConditionNull|ConditionPathExists|ConditionPathExistsGlob|ConditionPathIsDirectory|ConditionPathIsMountPoint|ConditionPathIsReadWrite|ConditionPathIsSymbolicLink|ConditionSecurity|ConditionVirtualization|Conflicts|ControlGroup|ControlGroupAttribute|ControlGroupModify|ControlGroupPersistent|controllers|Controllers|CPE_NAME|CPUAffinity|CPUSchedulingPolicy|CPUSchedulingPriority|CPUSchedulingResetOnFork|CPUShares|CrashChVT|CrashShell|__CURSOR|debug|DefaultControllers|DefaultDependencies|DefaultLimitAS|DefaultLimitCORE|DefaultLimitCPU|DefaultLimitDATA|DefaultLimitFSIZE|DefaultLimitLOCKS|DefaultLimitMEMLOCK|DefaultLimitMSGQUEUE|DefaultLimitNICE|DefaultLimitNOFILE|DefaultLimitNPROC|DefaultLimitRSS|DefaultLimitRTPRIO|DefaultLimitRTTIME|DefaultLimitSIGPENDING|DefaultLimitSTACK|DefaultStandardError|DefaultStandardOutput|Description|DeviceAllow|DeviceDeny|DirectoryMode|DirectoryNotEmpty|Documentation|DumpCore|entropy|Environment|EnvironmentFile|ERRNO|event_timeout|_EXE|ExecReload|ExecStart|ExecStartPost|ExecStartPre|ExecStop|ExecStopPost|ExecStopPre|filter|FONT|FONT_MAP|FONT_UNIMAP|ForwardToConsole|ForwardToKMsg|ForwardToSyslog|FreeBind|freq|FsckPassNo|fstab|_GID|Group|GuessMainPID|HandleHibernateKey|HandleLidSwitch|HandlePowerKey|HandleSuspendKey|hash|HibernateKeyIgnoreInhibited|HOME_URL|_HOSTNAME|ICON_NAME|ID|IdleAction|IdleActionSec|ID_LIKE|ID_MODEL|ID_MODEL_FROM_DATABASE|IgnoreOnIsolate|IgnoreOnSnapshot|IgnoreSIGPIPE|InaccessibleDirectories|InhibitDelayMaxSec|init|IOSchedulingClass|IOSchedulingPriority|IPTOS|IPTTL|JobTimeoutSec|JoinControllers|KeepAlive|KEYMAP|KEYMAP_TOGGLE|KillExcludeUsers|KillMode|KillOnlyUsers|KillSignal|KillUserProcesses|LidSwitchIgnoreInhibited|LimitAS|LimitCORE|LimitCPU|LimitDATA|LimitFSIZE|LimitLOCKS|LimitMEMLOCK|LimitMSGQUEUE|LimitNICE|LimitNOFILE|LimitNPROC|LimitRSS|LimitRTPRIO|LimitRTTIME|LimitSIGPENDING|LimitSTACK|link_priority|valueListenDatagram|ListenFIFO|ListenMessageQueue|ListenNetlink|ListenSequentialPacket|ListenSpecial|ListenStream|LogColor|LogLevel|LogLocation|LogTarget|luks|_MACHINE_ID|MakeDirectory|Mark|MaxConnections|MaxFileSec|MaxLevelConsole|MaxLevelKMsg|MaxLevelStore|MaxLevelSyslog|MaxRetentionSec|MemoryLimit|MemorySoftLimit|MESSAGE|MESSAGE_ID|MessageQueueMaxMessages|MessageQueueMessageSize|__MONOTONIC_TIMESTAMP|MountFlags|NAME|NAutoVTs|Nice|NonBlocking|NoNewPrivileges|NotifyAccess|OnActiveSec|OnBootSec|OnCalendar|OnFailure|OnFailureIsolate|OnStartupSec|OnUnitActiveSec|OnUnitInactiveSec|OOMScoreAdjust|Options|output|PAMName|PartOf|PassCredentials|PassSecurity|PathChanged|PathExists|PathExistsGlob|PathModified|PermissionsStartOnly|_PID|PIDFile|PipeSize|PowerKeyIgnoreInhibited|PRETTY_HOSTNAME|PRETTY_NAME|Priority|PRIORITY|PrivateNetwork|PrivateTmp|PropagatesReloadTo|pss|RateLimitBurst|RateLimitInterval|ReadOnlyDirectories|ReadWriteDirectories|__REALTIME_TIMESTAMP|ReceiveBuffer|RefuseManualStart|RefuseManualStop|rel|ReloadPropagatedFrom|RemainAfterExit|RequiredBy|Requires|RequiresMountsFor|RequiresOverridable|Requisite|RequisiteOverridable|ReserveVT|ResetControllers|Restart|RestartPreventExitStatus|RestartSec|RootDirectory|RootDirectoryStartOnly|RuntimeKeepFree|RuntimeMaxFileSize|RuntimeMaxUse|RuntimeWatchdogSec|samples|scale_x|scale_y|Seal|SecureBits|_SELINUX_CONTEXT|SendBuffer|SendSIGKILL|Service|ShowStatus|ShutdownWatchdogSec|size|SmackLabel|SmackLabelIPIn|SmackLabelIPOut|SocketMode|Sockets|SourcePath|_SOURCE_REALTIME_TIMESTAMP|SplitMode|StandardError|StandardInput|StandardOutput|StartLimitAction|StartLimitBurst|StartLimitInterval|static_node|StopWhenUnneeded|Storage|string_escape|none|replaceSuccessExitStatus|SupplementaryGroups|SUPPORT_URL|SuspendKeyIgnoreInhibited|SyslogFacility|SYSLOG_FACILITY|SyslogIdentifier|SYSLOG_IDENTIFIER|SyslogLevel|SyslogLevelPrefix|SYSLOG_PID|SystemCallFilter|SYSTEMD_ALIAS|_SYSTEMD_CGROUP|_SYSTEMD_OWNER_UID|SYSTEMD_READY|_SYSTEMD_SESSION|_SYSTEMD_UNIT|_SYSTEMD_USER_UNIT|SYSTEMD_WANTS|SystemKeepFree|SystemMaxFileSize|SystemMaxUse|SysVStartPriority|TCPCongestion|TCPWrapName|timeout|TimeoutSec|TimeoutStartSec|TimeoutStopSec|TimerSlackNSec|Transparent|_TRANSPORT|tries|TTYPath|TTYReset|TTYVHangup|TTYVTDisallocate|Type|_UID|UMask|Unit|User|UtmpIdentifier|VERSION|VERSION_ID|WantedBy|Wants|WatchdogSec|What|Where|WorkingDirectory)="
color brightblue "^\.include\>"
color red "="
color brightmagenta "^\[(Unit|Install|Service|Socket|Mount|Timer|Path)\]"
color brightyellow "\$MAINPID"
color brightcyan "\<(true|false)\>"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "tex" "\.(tex|cls|ltx|sty|dtx|ins|bbl)$"
color brightyellow "\\[A-Za-z]+"
color brightmagenta "\\section"
color cyan "%.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "vala" "\.vala$"
color green "\<(float|double|bool|char|int|uint|short|long|void|(un)?signed)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(for|if|while|do|else|case|default|switch|try|throw|catch)\>"
color brightblack "\<(inline|typedef|struct|enum|union|extern|static|const)\>"
color brightblack "\<(operator|new|delete|return|null|using)\>"
color brightblack "\<(class|override|private|public|signal|this|weak)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color blue "\<([0-9]+)\>"
color red "[-+/*=<>?:!~%&|]" "->"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "vi" "(^|/|\.)(ex|vim)rc$|\.vim"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<([nvxsoilc]?(nore|un)?map|[nvlx]n|[ico]?no|[cilovx][um]|s?unm)\>"
color brightblack "\<(snor|nun|nm|set|if|endif|let|unlet)\>"
color red "[!&=]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])\"[^"]*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "xml" "\.([jrs]html?|sgml?|xml|opml|xslt?|plist)$"
header "<\?xml"
color brightmagenta start="<" end=">"
color brightblack " [a-z_-]+="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightwhite,red "&"
color magenta "&(#[0-9]+|#x[0-9a-fA-F]+|[A-Za-z][A-Za-z0-9]*);"
color cyan start="<!--" end="-->"
color cyan start="<!DOCTYPE" end=">"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "xresources" "X(defaults|resources)$"
color green "^[[:alnum:]]+\*"
color brightyellow "\*[[:alnum:]]+\:"
color blue "\<[0-9]+\>"
color red "[*:=]"
color brightcyan "\<(true|false)\>"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "yaml" "\.ya?ml$"
header "^---" "%YAML"
color green "(^| )!!(binary|bool|float|int|map|null|omap|seq|set|str) "
color brightcyan "\<(YES|yes|Y|y|ON|on|NO|no|N|n|OFF|off)\>"
color brightcyan "\<(true|false)\>"
color red ":[[:space:]]" "\[" "\]" ":[[:space:]]+[|>]" "^[[:space:]]*- "
color brightyellow "[[:space:]][\*&][A-Za-z0-9]+"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightmagenta "^---" "^\.\.\." "^%YAML" "^%TAG"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "yum" "\.repo$|yum.*\.conf$"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color brightyellow "\$(releasever|arch|basearch|uuid|YUM[0-9])"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

26
nano/syntax/awk.nanorc Normal file
View File

@ -0,0 +1,26 @@
syntax "awk" "\.awk$"
header "^#!.*bin/(env +)?awk( |$)"
color brightyellow "\$[A-Za-z0-9_!@#$*?-]+"
color brightyellow "\<(ARGC|ARGIND|ARGV|BINMODE|CONVFMT|ENVIRON|ERRNO|FIELDWIDTHS)\>"
color brightyellow "\<(FILENAME|FNR|FS|IGNORECASE|LINT|NF|NR|OFMT|OFS|ORS)\>"
color brightyellow "\<(PROCINFO|RS|RT|RSTART|RLENGTH|SUBSEP|TEXTDOMAIN)\>"
color brightblue "\<(function|extension|BEGIN|END)\>"
color red "[-+*/%^|!=&<>?;:]|\\|\[|\]"
color brightblack "\<(for|if|while|do|else|in|delete|exit)\>"
color brightblack "\<(break|continue|return)\>"
color brightblue "\<(close|getline|next|nextfile|print|printf|system|fflush)\>"
color brightblue "\<(atan2|cos|exp|int|log|rand|sin|sqrt|srand)\>"
color brightblue "\<(asort|asorti|gensub|gsub|index|length|match)\>"
color brightblue "\<(split|sprintf|strtonum|sub|substr|tolower|toupper)\>"
color brightblue "\<(mktime|strftime|systime)\>"
color brightblue "\<(and|compl|lshift|or|rshift|xor)\>"
color brightblue "\<(bindtextdomain|dcgettext|dcngettext)\>"
color magenta "/.*[^\]/"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\."
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

25
nano/syntax/c.nanorc Normal file
View File

@ -0,0 +1,25 @@
syntax "c" "\.(c(c|pp|xx)?|C)$" "\.(h(h|pp|xx)?|H)$" "\.ii?$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightyellow "\<[A-Z_][0-9A-Z_]+\>"
color green "\<(float|double|bool|char|int|short|long|void|(un)?signed)\>"
color green "\<[a-z0-9_]+_t\>"
color brightblack "\<(struct|enum|static|const|union|typedef|extern)\>"
color brightblack "\<(for|if|while|do|else|case|default|switch)\>"
color brightblack "\<(return|inline|sizeof|auto|register|volatile|restrict)\>"
color brightblack "\<(try|throw|catch|operator|new|delete)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|^]"
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>|'.'"
color brightyellow "^[[:space:]]*#[[:space:]]*(define|include(_next)?|(un|ifn?)def|endif|el(if|se)|if|warning|error|pragma)"
color magenta "__attribute__[[:space:]]*\(\([^)]*\)\)" "__(aligned|asm|builtin|hidden|inline|packed|restrict|section|typeof|weak)__"
color yellow ""(\\.|[^"])*"|<[A-Za-z_./-]+>"
color magenta "\\([\"'abfnrtv\\]|[0-3]?[0-7]{1,2}|x[A-Fa-f0-9]{1,2}|$)"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

12
nano/syntax/cmake.nanorc Normal file
View File

@ -0,0 +1,12 @@
syntax "cmake" "CMakeLists\.txt$|\.cmake$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightcyan "\<(ON|OFF|TRUE|FALSE|YES|NO)\>"
color brightyellow "\$\{[A-Za-z0-9_!@#$*?-]+\}"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([()#$^]|\\|\")"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,17 @@
syntax "coffeescript" "\.coffee$"
header "^#!.*/(env +)?coffee"
color red "[!&|=/*+-<>]|\<(and|or|is|isnt|not)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*:[[:space:]]*(->|\()" "->"
color black "[()]"
color brightblack "\<(for|of|continue|break|isnt|null|unless|this|else|if|return)\>"
color brightblack "\<(try|catch|finally|throw|new|delete|typeof|in|instanceof)\>"
color brightblack "\<(debugger|switch|while|do|class|extends|super)\>"
color brightblack "\<(undefined|then|unless|until|loop|of|by|when)\>"
color brightcyan "\<(true|false|yes|no|on|off)\>"
color brightyellow "@[A-Za-z0-9_]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,17 @@
syntax "colortest" "ColorTest$"
color black "\<PLAIN\>"
color red "\<red\>"
color green "\<green\>"
color yellow "\<yellow\>"
color blue "\<blue\>"
color magenta "\<magenta\>"
color cyan "\<cyan\>"
color brightred "\<brightred\>"
color brightgreen "\<brightgreen\>"
color brightyellow "\<brightyellow\>"
color brightblue "\<brightblue\>"
color brightmagenta "\<brightmagenta\>"
color brightcyan "\<brightcyan\>"

28
nano/syntax/csharp.nanorc Normal file
View File

@ -0,0 +1,28 @@
syntax "c#" "\.cs$"
# Class
color brightmagenta "class +[A-Za-z0-9]+ *((:) +[A-Za-z0-9.]+)?"
# Annotation
color magenta "@[A-Za-z]+"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(bool|byte|sbyte|char|decimal|double|float|IntPtr|int|uint|long|ulong|object|short|ushort|string|base|this|var|void)\>"
color brightblack "\<(alias|as|case|catch|checked|default|do|dynamic|else|finally|fixed|for|foreach|goto|if|is|lock|new|null|return|switch|throw|try|unchecked|while)\>"
color brightblack "\<(abstract|async|class|const|delegate|enum|event|explicit|extern|get|implicit|in|internal|interface|namespace|operator|out|override|params|partial|private|protected|public|readonly|ref|sealed|set|sizeof|stackalloc|static|struct|typeof|unsafe|using|value|virtual|volatile|yield)\>"
# LINQ-only keywords (ones that cannot be used outside of a LINQ query - lots others can)
color brightblack "\<(from|where|select|group|info|orderby|join|let|in|on|equals|by|ascending|descending)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|]"
color blue "\<([0-9._]+|0x[A-Fa-f0-9_]+|0b[0-1_]+)[FL]?\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([btnfr]|'|\"|\\)"
color magenta "\\u[A-Fa-f0-9]{4}"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

34
nano/syntax/css.nanorc Normal file
View File

@ -0,0 +1,34 @@
syntax "css" "\.s?css$"
# Selectors
color green "\<(a|abbr|address|area|article|aside|audio|b|base|bdo|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|command|datalist|dd|del|details|dfn|div|dl|dt|em|embed|eventsource|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|keygen|label|legend|li|link|mark|map|menu|meta|meter|nav|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|ruby|rp|rt|samp|script|section|select|small|source|span|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|ul|var|video|wbr)\>"
color red "[>+~*]"
color brightyellow "[.#][A-Za-z_][A-Za-z0-9_-]*"
color red ":(active|focus|hover|link|visited|first-child|lang|valid|invalid|not|selection)\>"
color red ":(after|before|first-line|first-letter|root|target)\>"
color yellow "\[[^\[]*\]"
color black start="\{" end="\}"
# Sass
color brightmagenta "(^|[[:space:]])@(include|mixin)\>"
color brightyellow "\$[A-Za-z0-9_-]+"
color brightmagenta "(^|[[:space:]])@(charset|font-face|media|page|import)\>"
color red "[*]"
color brightcyan "\<(above|absolute|always|armenian|auto|avoid|baseline|behind|below|bidi-override|blink|block|bolder|bold|bottom|capitalize|center-left|center-right|center|circle|cjk-ideographic|close-quote|collapse|compact|condensed|continuous|crop|crosshair|cross|cue-after|cue-before|cursive|dashed|decimal|decimal-leading-zero|default|digits|disc|dotted|double|embed|e-resize|expanded|extra-condensed|extra-expanded|fantasy|far-left|far-right|faster|fast|fixed|fixed|georgian|groove|hebrew|help|hide|higher|high|hiragana-iroha|hiragana|inherit|inline|inline-block|inline-table|inset|inside|invert|italic|justify|katakana-iroha|katakana|landscape|large|larger|left|left-side|leftwards|level|lighter|line-through|list-item|loud|lower-alpha|lowercase|lower-greek|lower-latin|lower-roman|lower|low|ltr|marker|medium|medium|middle|mix|monospace|move|narrower|ne-resize|no-close-quote|none|no-open-quote|no-repeat|normal|nowrap|n-resize|nw-resize|oblique|once|open-quote|outset|outside|overline|pointer|portait|relative|repeat-x|repeat-y|repeat|ridge|right-side|right|rightwards|rlt|run-in|sans-serif|scroll|scroll|semi-condensed|semi-expanded|separate|se-resize|serif|show|silent|slower|slow|small-caps|smaller|small|soft|solid|spell-out|square|s-resize|static|sub|super|sw-resize|table-caption|table-cell|table-column-group|table-column|table-footer-group|table-header-group|table-row-group|table-row|text-bottom|text|text-top|thick|thin|top|top|transparent|ultra-condensed|ultra-expanded|underline|upper-alpha|uppercase|upper-latin|upper-roman|visible|wait|wider|w-resize|x-fast|x-high|x-large|x-loud|x-low|x-slow|x-small|x-soft|xx-large|xx-small|pre-wrap|break-word)([[:space:];,]|$)"
color brightyellow ":[[:space:]]*(code|hidden|table|pre)\>"
color brightblack "\<(background-attachment|background-clip|background-color|background-image|background-position|background-repeat|background|border-bottom-color|border-bottom-style|border-bottom-width|border-bottom|border-collapse|border-color|border-left-color|border-left-style|border-left-width|border-left|border-radius|border-right-color|border-right-style|border-right-width|border-right|border-spacing|border-style|border-top-color|border-top-style|border-top-width|border-top|border-width|border|bottom|box-shadow|box-sizing|caption-side|clear|clip|color|content|counter-increment|counter-reset|cue-after|cue-before|cue|cursor|direction|display|elevation|empty-cells|float|font-family|font-size-adjust|font-size|font-style|font-variant|font-weight|font|height|left|letter-spacing|line-height|list-style-image|list-style-position|list-style-type|list-style|margin-bottom|margin-left|margin-right|margin-top|margin|marker-offset|marks|max-height|max-width|min-height|min-width|opacity|orphans|outline-color|outline-style|outline-width|outline|overflow|overflow-x|overflow-y|padding-bottom|padding-left|padding-right|padding-top|padding|page-break-after|page-break-before|page-break-inside|page|pause-after|pause-before|pause|pitch-range|pitch|play-during|position|quotes|richness|right|size|speak-header|speak-numerical|speak-punctuation|speak|speech-rate|stress|table-layout|text-align|text-decoration|text-indent|text-shadow|text-transform|top|transition|unicode-bidi|vertical-align|visibility|voice-family|volume|white-space|widows|width|word-spacing|word-wrap|z-index)[[:space:]]*:"
color brightwhite,red "-(ms|moz|apple|khtml|wap|webkit|o|xv)-[a-z][a-z-]+"
color black "[:;,]"
color blue "\<(0|[\+-]?[1-9][0-9]*)"
color blue "[\+-]?([0-9]+|[0-9]*\.[0-9]+)(%|e(m|x)|p(x|t|c)|in|ft|(m|c)m|k?Hz|deg|g?rad|m?s)"
color blue "#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})\>"
color red "\!important\>"
color brightblue "[a-z-]*(-[a-z]+)?\(" "\(|\)"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

28
nano/syntax/cython.nanorc Normal file
View File

@ -0,0 +1,28 @@
syntax "cython" "\.(pyx|pxd|pyi)$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(and|as|assert|break|class|continue|def|del|elif|else|except)\>"
color brightblack "\<(exec|finally|for|from|global|if|import|in|is|lambda|not|or)\>"
color brightblack "\<(pass|print|raise|return|try|while|with|yield|None)\>"
color brightblack "\<(DEF|ELIF|ELSE|IF)\>"
color brightblack "\<(cp?def( inline)?|cimport|cppclass|ctypedef|extern|include)\>"
color brightblack "\<(namespace|property|struct)\>"
color green "\<(bint|char|double|int|public|void|unsigned)\>"
color red "[.:;,+*|=!\%@<>/&-]"
color brightyellow "@[A-Za-z0-9_]+"
color brightmagenta "__[A-Za-z0-9_]+__"
color brightcyan "\<(True|False)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "['][^']*[^\\][']" "[']{3}.*[^\\][']{3}"
color yellow "["][^"]*[^\\]["]" "["]{3}.*[^\\]["]{3}"
color yellow start=""""[^"]" end="""""
color yellow start="'''[^']" end="'''"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,4 @@
syntax "default"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

8
nano/syntax/dot.nanorc Normal file
View File

@ -0,0 +1,8 @@
syntax "dot" "\.(dot|gv)$"
color brightblack "\<(digraph|edge|graph|node|subgraph)\>"
color magenta "\<(arrowhead|arrowsize|arrowtail|bgcolor|center|color|constraint|decorateP|dir|distortion|fillcolor|fontcolor|fontname|fontsize|headclip|headlabel|height|labelangle|labeldistance|labelfontcolor|labelfontname|labelfontsize|label|layers|layer|margin|mclimit|minlen|name|nodesep|nslimit|ordering|orientation|pagedir|page|peripheries|port_label_distance|rankdir|ranksep|rank|ratio|regular|rotate|samehead|sametail|shapefile|shape|sides|size|skew|style|tailclip|taillabel|URL|weight|width)\>"
color red "=|->|--"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"

5
nano/syntax/email.nanorc Normal file
View File

@ -0,0 +1,5 @@
syntax "email"
color magenta "^>([^>].*|$)"
color blue "^>>([^>].*|$)"
color green "^>>>.*"

21
nano/syntax/git.nanorc Normal file
View File

@ -0,0 +1,21 @@
syntax "gitconfig" "git(config|modules)$|\.git/config$"
color brightcyan "\<(true|false)\>"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "git-editmsg" "(COMMIT|TAG)_EDITMSG$"
color cyan "^#.*$"
color ,red "[[:space:]]+$"
syntax "git-rebase" "git-rebase-todo$"
color brightblack "^(edit|fixup|pick|reword|squash|exec|[efprsx])\>"
color blue "\<[0-9a-f]{7,40}\>"
color cyan "^#.*"

17
nano/syntax/glsl.nanorc Normal file
View File

@ -0,0 +1,17 @@
syntax "glsl" "\.(frag|vert|fp|vp|glsl)$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(void|bool|bvec2|bvec3|bvec4|int|ivec2|ivec3|ivec4|float|vec2|vec3|vec4|mat2|mat3|mat4|struct|sampler1D|sampler2D|sampler3D|samplerCUBE|sampler1DShadow|sampler2DShadow)\>"
color green "\<gl_(DepthRangeParameters|PointParameters|MaterialParameters|LightSourceParameters|LightModelParameters|LightModelProducts|LightProducts|FogParameters)\>"
color brightblack "\<(const|attribute|varying|uniform|in|out|inout|if|else|return|discard|while|for|do)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|^]"
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

24
nano/syntax/go.nanorc Normal file
View File

@ -0,0 +1,24 @@
syntax "go" "\.go$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblue "\<(append|cap|close|complex|copy|delete|imag|len)\>"
color brightblue "\<(make|new|panic|print|println|protect|real|recover)\>"
color green "\<(u?int(8|16|32|64)?|float(32|64)|complex(64|128))\>"
color green "\<(uintptr|byte|rune|string|interface|bool|map|chan|error)\>"
color brightblack "\<(package|import|const|var|type|struct|func|go|defer|nil|iota)\>"
color brightblack "\<(for|range|if|else|case|default|switch|return)\>"
color brightred "\<(go|goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>!~%&|^]|:="
color blue "\<([0-9]+|0x[0-9a-fA-F]*)\>|'.'"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\[abfnrtv'\"\\]"
color magenta "\\([0-7]{3}|x[A-Fa-f0-9]{2}|u[A-Fa-f0-9]{4}|U[A-Fa-f0-9]{8})"
color yellow "`[^`]*`"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

24
nano/syntax/html.nanorc Normal file
View File

@ -0,0 +1,24 @@
syntax "html" "\.html?$"
header "<!doctype html"
color magenta "\<(accept|accept-charset|accesskey|action|alt|async|autocomplete|autofocus|autoplay|border|challenge|charset|checked|cite|class|cols|colspan|content|contenteditable|contextmenu|controls|coords|crossorigin|data-[a-z-]+|datetime|default|defer|dir|dirname|disabled|draggable|dropzone|enctype|for|form|formaction|formenctype|formmethod|formnovalidate|formtarget|headers|height|hidden|high|href|hreflang|http-equiv|icon|id|ismap|keytype|kind|label|lang|list|loop|low|manifest|max|maxlength|media|mediagroup|method|min|multiple|muted|name|novalidate|open|optimum|pattern|placeholder|poster|preload|pubdate|radiogroup|readonly|rel|required|reversed|rows|rowspan|sandbox|spellcheck|scope|scoped|seamless|selected|shape|size|sizes|span|src|srcdoc|srclang|start|step|style|tabindex|target|title|type|typemustmatch|usemap|value|width|wrap)\>"
color brightwhite,red "</?[A-Za-z0-9_]+[ >]"
color brightmagenta "</?(a|abbr|address|area|article|aside|audio|b|base|bdo|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|command|datalist|dd|del|details|dfn|div|dl|dt|em|embed|eventsource|fieldset|figcaption|figure|footer|form|h1|h2|h3|h4|h5|h6|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|keygen|label|legend|li|link|mark|map|menu|meta|meter|nav|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|ruby|rp|rt|samp|script|section|select|small|source|span|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|ul|var|video|wbr)[ >]"
color yellow "=([A-Za-z0-9!$%*\^(){}#|:;_~@+,.?/\\-]|\[|\])+"
color red "="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color black start=">" end="<"
color brightmagenta "[<>]"
# Embedded template languages
color brightyellow "\{\{[^}]*\}\}|<%=.*%>"
color brightblue start="<\?" end="\?>"
color brightblue start="<%[^=]" end="%>"
color brightblue start="\{%" end="%\}"
color magenta "&(#[0-9]+|#x[0-9a-fA-F]+|[A-Za-z][A-Za-z0-9]*);"
color cyan start="<!--" end="-->"
color cyan "<!(doctype|DOCTYPE)[^>]*>"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

12
nano/syntax/ini.nanorc Normal file
View File

@ -0,0 +1,12 @@
syntax "ini" "\.(ini|desktop|lfl|override)$" "(mimeapps\.list|pinforc|setup\.cfg)$" "weechat/.+\.conf$"
header "^\[[A-Za-z]+\]$"
color brightcyan "\<(true|false)\>"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color red "[=;]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,11 @@
syntax "inputrc" "inputrc$"
color red "\<(off|none)\>"
color green "\<on\>"
color brightblue "\<set|\$include\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

29
nano/syntax/java.nanorc Normal file
View File

@ -0,0 +1,29 @@
syntax "java" "\.java$"
# Class
color brightmagenta "class +[A-Za-z0-9]+ *((implements|extends) +[A-Za-z0-9.]+)?"
# Annotation
color magenta "@[A-Za-z]+"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(boolean|byte|char|double|float|int|long|short|String|void)\>"
color brightblack "\<(case|catch|default|do|else|finally|for|if)\>"
color brightblack "\<(new|return|switch|this|throw|transient|try|while)\>"
color brightblack "\<(abstract|class|extends|final|implements|import|instanceof)\>"
color brightblack "\<(interface|native|package|private|protected|public|static)\>"
color brightblack "\<(strictfp|super|synchronized|throws|volatile|null)\>"
color brightred "\<(break|continue)\>"
color brightcyan "\<(true|false)\>"
color red "[-+/*=<>?:!~%&|]"
color blue "\<([0-9._]+|0x[A-Fa-f0-9_]+|0b[0-1_]+)[FL]?\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([btnfr]|'|\"|\\)"
color magenta "\\u[A-Fa-f0-9]{4}"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,24 @@
syntax "JavaScript" "\.js$"
color blue "\<[-+]?([1-9][0-9]*|0[0-7]*|0x[0-9a-fA-F]+)([uU][lL]?|[lL][uU]?)?\>"
color blue "\<[-+]?([0-9]+\.[0-9]*|[0-9]*\.[0-9]+)([EePp][+-]?[0-9]+)?[fFlL]?"
color blue "\<[-+]?([0-9]+[EePp][+-]?[0-9]+)[fFlL]?"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(break|case|catch|continue|default|delete|do|else|finally)\>"
color brightblack "\<(for|function|get|if|in|instanceof|new|return|set|switch)\>"
color brightblack "\<(switch|this|throw|try|typeof|var|void|while|with)\>"
color brightblack "\<(null|undefined|NaN)\>"
color brightcyan "\<(true|false)\>"
color green "\<(Array|Boolean|Date|Enumerator|Error|Function|Math)\>"
color green "\<(Number|Object|RegExp|String)\>"
color red "[-+/*=<>!~%?:&|]"
color magenta "/[^*]([^/]|(\\/))*[^\\]/[gim]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\[0-7][0-7]?[0-7]?|\\x[0-9a-fA-F]+|\\[bfnrt'"\?\\]"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

12
nano/syntax/json.nanorc Normal file
View File

@ -0,0 +1,12 @@
syntax "json" "\.json$"
header "^\{$"
color blue "\<[-]?[1-9][0-9]*([Ee][+-]?[0-9]+)?\>" "\<[-]?[0](\.[0-9]+)?\>"
color brightblack "\<null\>"
color brightcyan "\<(true|false)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\"(\\"|[^"])*\"[[:space:]]*:" "'(\'|[^'])*'[[:space:]]*:"
color magenta "\\u[0-9a-fA-F]{4}|\\[bfnrt'"/\\]"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

11
nano/syntax/keymap.nanorc Normal file
View File

@ -0,0 +1,11 @@
syntax "keymap" "\.(k|key)?map$|Xmodmap$"
color brightblack "\<(add|clear|compose|keycode|keymaps|keysym|remove|string)\>"
color brightblack "\<(control|alt|shift)\>"
color blue "\<[0-9]+\>"
color red "="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "^!.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,16 @@
syntax "KickStart" "\.ks$" "\.kickstart$"
color brightmagenta "%[a-z]+"
color brightblack "^[[:space:]]*(install|cdrom|text|graphical|volgroup|logvol|reboot|timezone|lang|keyboard|authconfig|firstboot|rootpw|user|firewall|selinux|repo|part|partition|clearpart|bootloader)"
color brightblack "--(name|mirrorlist|baseurl|utc)(=|\>)"
color brightyellow "\$(releasever|basearch)\>"
# Packages and groups
color brightblack "^@[A-Za-z][A-Za-z-]*"
color brightred "^-@[a-zA-Z0-9*-]+"
color red "^-[a-zA-Z0-9*-]+"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,9 @@
syntax "ledger" "(^|\.|/)ledger$"
color brightmagenta "^([0-9]{4}/[0-9]{2}/[0-9]{2}|[=~]) .*"
color blue "^[0-9]{4}/[0-9]{2}/[0-9]{2}"
color brightyellow "^~ .*"
color brightblue "^= .*"
color brightblack "^[[:space:]]+\(?[A-Za-z ]+(:[A-Za-z ]+)*\)?"
color red "[*]"
color cyan "^[[:space:]]*;.*"

15
nano/syntax/lisp.nanorc Normal file
View File

@ -0,0 +1,15 @@
syntax "lisp" "(emacs|zile)$" "\.(el|li?sp|scm|ss)$"
color brightblue "\([a-z-]+"
color red "\(([-+*/<>]|<=|>=)|'"
color black "\("
color blue "\<[0-9]+\>"
icolor brightblack "\<nil\>"
color brightcyan "\<[tT]\>"
color yellow "\"(\\.|[^"])*\""
color magenta "'[A-Za-z][A-Za-z0-9_-]+"
color magenta "\\.?"
color cyan "(^|[[:space:]]);.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

24
nano/syntax/lua.nanorc Normal file
View File

@ -0,0 +1,24 @@
syntax "lua" "\.lua$"
header "^#!.*lua(jit)?$"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*([({'"]|\[=*\[)"
color brightblack "\<(do|end|while|repeat|until|if|elseif|then|else)\>"
color brightblack "\<(for|in|function|local|return|nil)\>"
color brightred "\<(goto|break)\>"
color brightcyan "\<(true|false)\>"
color red "[-+:*/%^=#<>]|~=|\.\.|\[|\]|\<(not|and|or)\>"
color brightwhite,red "[`!@$&|?]|!="
color black "\.{3,}|[({'"]"
color blue "\<([0-9]+)(\.[0-9]+)?([Ee][+-]?[0-9]+)?\>|0x[0-9a-fA-F]*"
color brightmagenta "::[A-Za-z_][A-Za-z0-9_]*::"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\([0-9]{1,3}|x[A-Fa-f0-9]{2}|[abefntrv'"\\]|\[|\])"
color yellow start="\[\[" end="\]\]"
color yellow start="\[=\[" end="\]=\]"
color yellow start="\[==\[" end="\]==\]"
color cyan "^#!.*" "(^|[[:space:]])\-\-.*$"
color cyan start="\-\-\[\[" end="\]\]"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,22 @@
syntax "makefile" "([Mm]akefile|\.ma?k)$"
header "^#!.*/(env +)?[bg]?make( |$)"
color brightblack "\<(ifeq|ifdef|ifneq|ifndef|else|endif)\>"
color brightblack "^(export|include|override)\>"
color brightmagenta "^[^:= ]+:"
color red "[=,%]" "\+=|\?=|:=|&&|\|\|"
color brightblue "\$\((abspath|addprefix|addsuffix|and|basename|call|dir)[[:space:]]"
color brightblue "\$\((error|eval|filter|filter-out|findstring|firstword)[[:space:]]"
color brightblue "\$\((flavor|foreach|if|info|join|lastword|notdir|or)[[:space:]]"
color brightblue "\$\((origin|patsubst|realpath|shell|sort|strip|suffix)[[:space:]]"
color brightblue "\$\((value|warning|wildcard|word|wordlist|words)[[:space:]]"
color black "[()$]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\$+(\{[^} ]+\}|\([^) ]+\))"
color brightyellow "\$[@^<*?%|+]|\$\([@^<*?%+-][DF]\)"
color magenta "\$\$|\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color cyan "^ @#.*"
# Show trailing whitespace
color ,green "[[:space:]]+$"

10
nano/syntax/man.nanorc Normal file
View File

@ -0,0 +1,10 @@
syntax "man" "\.[1-9]x?$"
color brightmagenta "\.(S|T)H.*$"
color brightblack "\.(BR?|I[PR]?).*$"
color brightyellow "\.(S|T)H|\.TP|\.(BR?|I[PR]?|PP)|\\f[BIPR]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "\.(br|DS|RS|RE|PD)"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,19 @@
syntax "markdown" "\.(md|mkd|mkdn|markdown)$"
# Emphasis
color green "(^|[[:space:]])(_[^ ][^_]*_|\*[^ ][^*]*\*)"
# Strong emphasis
color brightgreen "(^|[[:space:]])(__[^ ][^_]*__|\*\*[^ ][^*]*\*\*)"
color brightmagenta "^=====*$|^-----*$|^#{1,6}.*"
color blue "^[[:space:]]*[\*+-] |^[[:space:]]*[0-9]+\. "
color black "^[[:space:]]+"
color magenta "\(([CcRr]|[Tt][Mm])\)" "\.{3}" "(^|[[:space:]])\-\-($|[[:space:]])"
color brightyellow "\!?\[[^]]*\]([[:space:]]*\[[^]]*\]|\(.*\))?"
color brightyellow "^\[.*\]:[[:space:]]*[^"]*"
color yellow "`[^`]*`|^ {4}[^-+*].*"
color cyan "^>.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,10 @@
syntax "mpdconf" "mpd\.conf$"
color brightblack "\<(user|group|bind_to_address|host|port|plugin|name|type)\>"
color brightblack "\<((music|playlist)_directory|(db|log|state|pid|sticker)_file)\>"
color brightmagenta "^(input|audio_output|decoder)[[:space:]]*\{|\}"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

20
nano/syntax/nanorc.nanorc Normal file
View File

@ -0,0 +1,20 @@
syntax "nanorc" "nanorc$"
header "^syntax +\""
color green "^i?color[[:space:]]*(bright)?(white|black|red|blue|green|yellow|magenta|cyan)?(,(white|black|red|blue|green|yellow|magenta|cyan))?\>"
color brightblack "^(set|unset)[[:space:]]+(allow_insecure_backup|autoindent|backup|backupdir|backwards|boldtext|brackets|casesensitive|const|cut|fill|historylog|matchbrackets|morespace|mouse|multibuffer|noconvert|nofollow|nohelp|nonewlines|nowrap|operatingdir|poslog|preserve|punct)\>" "^[[:space:]]*(set|unset)[[:space:]]+(quickblank|quotestr|rebinddelete|rebindkeypad|regexp|smarthome|smooth|softwrap|speller|suspend|suspendenable|tabsize|tabstospaces|tempfile|undo|view|whitespace|wordbounds)\>"
color brightblack "^(bind|i?color|set|unset|syntax|header|magic)\>"
color red "^unbind\>"
color brightblack "^i?color\>" "\<(start|end)="
color brightyellow "^include\>"
color brightblack "^(PLAIN|TYPE|STRING|MACRO|NUMBER|VARIABLE|OPERATOR|~?KEYWORD):"
color brightblack "^(BOOLEAN|SECTION|REGEXP|FUNCTION|ESCAPE|COMMENT|WARNING|JUMP):"
color brightblack "^(TAG|ATTRIBUTE):"
color brightyellow "^\+(TODO|LINT|STRING|BOOLEAN|FUNCTION|INI|(C|HASH)COMMENT)$"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

15
nano/syntax/nginx.nanorc Normal file
View File

@ -0,0 +1,15 @@
syntax "nginx" "nginx.*\.conf$" "\.nginx$"
header "^(server|upstream)[a-z ]*\{$"
color brightmagenta "\<(events|server|http|location|upstream)[[:space:]]*\{"
color brightblack "(^|[[:space:]{;])(access_log|add_after_body|add_before_body|add_header|addition_types|aio|alias|allow|ancient_browser|ancient_browser_value|auth_basic|auth_basic_user_file|autoindex|autoindex_exact_size|autoindex_localtime|break|charset|charset_map|charset_types|chunked_transfer_encoding|client_body_buffer_size|client_body_in_file_only|client_body_in_single_buffer|client_body_temp_path|client_body_timeout|client_header_buffer_size|client_header_timeout|client_max_body_size|connection_pool_size|create_full_put_path|daemon|dav_access|dav_methods|default_type|deny|directio|directio_alignment|disable_symlinks|empty_gif|env|error_log|error_page|expires|fastcgi_buffer_size|fastcgi_buffers|fastcgi_busy_buffers_size|fastcgi_cache|fastcgi_cache_bypass|fastcgi_cache_key|fastcgi_cache_lock|fastcgi_cache_lock_timeout|fastcgi_cache_min_uses|fastcgi_cache_path|fastcgi_cache_use_stale|fastcgi_cache_valid|fastcgi_connect_timeout|fastcgi_hide_header|fastcgi_ignore_client_abort|fastcgi_ignore_headers|fastcgi_index|fastcgi_intercept_errors|fastcgi_keep_conn|fastcgi_max_temp_file_size|fastcgi_next_upstream|fastcgi_no_cache|fastcgi_param|fastcgi_pass|fastcgi_pass_header|fastcgi_read_timeout|fastcgi_send_timeout|fastcgi_split_path_info|fastcgi_store|fastcgi_store_access|fastcgi_temp_file_write_size|fastcgi_temp_path|flv|geo|geoip_city|geoip_country|gzip|gzip_buffers|gzip_comp_level|gzip_disable|gzip_http_version|gzip_min_length|gzip_proxied|gzip_static|gzip_types|gzip_vary|if|if_modified_since|ignore_invalid_headers|image_filter|image_filter_buffer|image_filter_jpeg_quality|image_filter_sharpen|image_filter_transparency|include|index|internal|ip_hash|keepalive|keepalive_disable|keepalive_requests|keepalive_timeout|large_client_header_buffers|limit_conn|limit_conn_log_level|limit_conn_zone|limit_except|limit_rate|limit_rate_after|limit_req|limit_req_log_level|limit_req_zone|limit_zone|lingering_close|lingering_time|lingering_timeout|listen|location|log_format|log_not_found|log_subrequest|map|map_hash_bucket_size|map_hash_max_size|master_process|max_ranges|memcached_buffer_size|memcached_connect_timeout|memcached_next_upstream|memcached_pass|memcached_read_timeout|memcached_send_timeout|merge_slashes|min_delete_depth|modern_browser|modern_browser_value|mp4|mp4_buffer_size|mp4_max_buffer_size|msie_padding|msie_refresh|open_file_cache|open_file_cache_errors|open_file_cache_min_uses|open_file_cache_valid|open_log_file_cache|optimize_server_names|override_charset|pcre_jit|perl|perl_modules|perl_require|perl_set|pid|port_in_redirect|postpone_output|proxy_buffer_size|proxy_buffering|proxy_buffers|proxy_busy_buffers_size|proxy_cache|proxy_cache_bypass|proxy_cache_key|proxy_cache_lock|proxy_cache_lock_timeout|proxy_cache_min_uses|proxy_cache_path|proxy_cache_use_stale|proxy_cache_valid|proxy_connect_timeout|proxy_cookie_domain|proxy_cookie_path|proxy_hide_header|proxy_http_version|proxy_ignore_client_abort|proxy_ignore_headers|proxy_intercept_errors|proxy_max_temp_file_size|proxy_next_upstream|proxy_no_cache|proxy_pass|proxy_pass_header|proxy_read_timeout|proxy_redirect|proxy_send_timeout|proxy_set_header|proxy_ssl_session_reuse|proxy_store|proxy_store_access|proxy_temp_file_write_size|proxy_temp_path|random_index|read_ahead|real_ip_header|recursive_error_pages|request_pool_size|reset_timedout_connection|resolver|resolver_timeout|return|rewrite|root|satisfy|satisfy_any|secure_link_secret|send_lowat|send_timeout|sendfile|sendfile_max_chunk|server|server|server_name|server_name_in_redirect|server_names_hash_bucket_size|server_names_hash_max_size|server_tokens|set|set_real_ip_from|source_charset|split_clients|ssi|ssi_silent_errors|ssi_types|ssl|ssl_certificate|ssl_certificate_key|ssl_ciphers|ssl_client_certificate|ssl_crl|ssl_dhparam|ssl_engine|ssl_prefer_server_ciphers|ssl_protocols|ssl_session_cache|ssl_session_timeout|ssl_verify_client|ssl_verify_depth|sub_filter|sub_filter_once|sub_filter_types|tcp_nodelay|tcp_nopush|timer_resolution|try_files|types|types_hash_bucket_size|types_hash_max_size|underscores_in_headers|uninitialized_variable_warn|upstream|user|userid|userid_domain|userid_expires|userid_name|userid_p3p|userid_path|userid_service|valid_referers|variables_hash_bucket_size|variables_hash_max_size|worker_priority|worker_processes|worker_rlimit_core|worker_rlimit_nofile|working_directory|xml_entities|xslt_stylesheet|xslt_types)([[:space:]]|$)"
color black "[{}]"
color brightcyan "\<(on|off)\>"
color brightyellow "\$[A-Za-z][A-Za-z0-9_]*"
color red "[*]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow start="'$" end="';$"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

9
nano/syntax/patch.nanorc Normal file
View File

@ -0,0 +1,9 @@
syntax "patch" "\.(patch|diff)$"
color brightgreen "^\+.*"
color green "^\+\+\+.*"
color brightred "^-.*"
color red "^---.*"
color blue "^@@.*"
color magenta "^diff.*"

13
nano/syntax/peg.nanorc Normal file
View File

@ -0,0 +1,13 @@
syntax "peg" "\.l?peg$"
color brightblack "^[[:space:]]*[A-Za-z][A-Za-z0-9_]*[[:space:]]*<-"
color blue "\^[+-]?[0-9]+"
color red "[-+*?^/!&]|->|<-|=>"
color brightyellow "%[A-Za-z][A-Za-z0-9_]*"
color magenta "\[[^]]*\]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])\-\-.*$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

20
nano/syntax/php.nanorc Normal file
View File

@ -0,0 +1,20 @@
syntax "php" "\.php[2345s~]?$"
header "^(//|/\*).*[Pp][Hh][Pp]|<\?php\>"
color red "[-+/*=<>?:!~%&|]"
color brightmagenta "(<\?(php)?|\?>)"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color green "\<(float|global|double|bool|char|int|enum|const)\>"
color brightblack "\<(class|new|private|public|function|for|foreach|if|while|do|var)\>"
color brightblack "\<(return|else|elseif|case|default|switch)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "\$[A-Za-z_][A-Za-z0-9_]*"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,9 @@
syntax "pkg-config" "\.pc$"
color brightblack "^(Name|Description|URL|Version|Conflicts|Cflags):"
color brightblack "^(Requires|Libs)(\.private)?:"
color red "="
color brightyellow "\$\{[A-Za-z_][A-Za-z0-9_]*\}"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,23 @@
syntax "pkgbuild" "PKGBUILD$" "\.install$"
color brightblue "^[A-Za-z0-9_+-]+[[:space:]]*\(\)"
color brightblack "\<(case|do|done|elif|else|esac|fi|for|function|if)\>"
color brightblack "\<(in|select|then|time|until|while)\>"
color brightblue "\<(echo|exit|export|let|local|read|return|set|shift|umask|unset)\>"
color green "\<(pkgname|pkgver|pkgrel|epoch|pkgdesc|arch|url|license)\>"
color green "\<(groups|depends|makedepends|checkdepends|optdepends)\>"
color green "\<(provides|conflicts|replaces|backup|options|^install)\>"
color green "\<(changelog|source|noextract)\>"
color green "\<(md5sums|sha1sums|sha256sums|sha384sums|sha512sums)\>"
color green "\<(srcdir|pkgdir)\>"
color brightyellow "\<(strip|docs|libtool|emptydirs|zipman|purge|upx)\>"
color brightyellow "\<(ccache|distcc|buildflags|makeflags)\>"
color red "[{}()<>!=&|;`$]|\\|\[|\]|-(eq|ne|gt|lt|ge|le|s|n|z)\>"
color yellow ""(\\.|[^"])*""
color brightyellow "\$\{?[A-Za-z0-9_!@#$*?-]+\}?|`[^`]*`"
color yellow "'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

9
nano/syntax/po.nanorc Normal file
View File

@ -0,0 +1,9 @@
syntax "po" "\.pot?$"
color brightblack "\<(msgid|msgstr)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,32 @@
syntax "privoxy-config" "privoxy/config$"
color brightblack "(accept-intercepted-requests|actionsfile|admin-address|allow-cgi-request-crunching|buffer-limit|compression-level|confdir|connection-sharing|debug|default-server-timeout|deny-access|enable-compression|enable-edit-actions|enable-remote-http-toggle|enable-remote-toggle|enforce-blocks|filterfile|forward|forwarded-connect-retries|forward-socks4|forward-socks4a|forward-socks5|handle-as-empty-doc-returns-ok|hostname|keep-alive-timeout|listen-address|logdir|logfile|max-client-connections|permit-access|proxy-info-url|single-threaded|socket-timeout|split-large-forms|templdir|toggle|tolerate-pipelining|trustfile|trust-info-url|user-manual)[[:space:]]"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "privoxy-action" "\.action$"
color brightred "[{[:space:]]\-block([[:space:]{}]|$)"
color brightgreen "[{[:space:]]\+block([[:space:]{}]|$)"
color brightred "-(add-header|change-x-forwarded-for|client-header-filter|client-header-tagger|content-type-overwrite|crunch-client-header|crunch-if-none-match|crunch-incoming-cookies|crunch-outgoing-cookies|crunch-server-header|deanimate-gifs|downgrade-http-version|fast-redirects|filter|force-text-mode|forward-override|handle-as-empty-document|handle-as-image|hide-accept-language|hide-content-disposition|hide-from-header|hide-if-modified-since|hide-referrer|hide-user-agent|limit-connect|overwrite-last-modified|prevent-compression|redirect|server-header-filter|server-header-tagger|session-cookies-only|set-image-blocker)"
color brightgreen "\+(add-header|change-x-forwarded-for|client-header-filter|client-header-tagger|content-type-overwrite|crunch-client-header|crunch-if-none-match|crunch-incoming-cookies|crunch-outgoing-cookies|crunch-server-header|deanimate-gifs|downgrade-http-version|fast-redirects|filter|force-text-mode|forward-override|handle-as-empty-document|handle-as-image|hide-accept-language|hide-content-disposition|hide-from-header|hide-if-modified-since|hide-referrer|hide-user-agent|limit-connect|overwrite-last-modified|prevent-compression|redirect|server-header-filter|server-header-tagger|session-cookies-only|set-image-blocker)"
color black "[{}]"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
syntax "privoxy-filter" "\.filter$"
color brightblack "^(FILTER|CLIENT-HEADER-FILTER|CLIENT-HEADER-TAGGER|SERVER-HEADER-FILTER|SERVER-HEADER-TAGGER): [a-z-]+"
color brightblue "^(FILTER|CLIENT-HEADER-FILTER|CLIENT-HEADER-TAGGER|SERVER-HEADER-FILTER|SERVER-HEADER-TAGGER):"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,10 @@
syntax "properties" "\.properties$"
color brightblack "^[[:space:]]*[^#!]([^:= ]|\\[:= ])*[:= ]"
color red "[:=]"
color magenta "\\([#!=: ]|$)"
color magenta "\\u[[:xdigit:]]{4}"
color cyan "^[[:space:]]*[#!].*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

23
nano/syntax/python.nanorc Normal file
View File

@ -0,0 +1,23 @@
syntax "python" "\.py$" "jhbuildrc$"
header "^#!.*/(env +)?python[-0-9._]*( |$)"
color brightblack "\<(as|assert|break|class|continue|def|del|elif|else|except)\>"
color brightblack "\<(exec|finally|for|from|global|if|import|lambda)\>"
color brightblack "\<(pass|print|raise|return|try|while|with|yield|None)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color red "[-+*/|=%<>&~^]|\<(and|not|or|is|in)\>"
color brightyellow "@[A-Za-z0-9_]+"
color brightmagenta "__[A-Za-z0-9_]+__"
color brightcyan "\<(True|False)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "['][^']*[^\\][']" "[']{3}.*[^\\][']{3}"
color yellow "["][^"]*[^\\]["]" "["]{3}.*[^\\]["]{3}"
color yellow start=""""[^"]" end="""""
color yellow start="'''[^']" end="'''"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,28 @@
syntax "rpmspec" "\.spec$" "\.rpmspec$"
color brightblack "\<(Icon|ExclusiveOs|ExcludeOs):"
color brightblack "\<(BuildArch|BuildArchitectures|ExclusiveArch|ExcludeArch):"
color brightblack "\<(Conflicts|Obsoletes|Provides|Requires|Requires\(.*\)|Enhances|Suggests|BuildConflicts|BuildRequires|Recommends|PreReq|Supplements):"
color brightblack "\<(Epoch|Serial|Nosource|Nopatch):"
color brightblack "\<(AutoReq|AutoProv|AutoReqProv):"
color brightblack "\<(Copyright|License|Summary|Summary\(.*\)|Distribution|Vendor|Packager|Group|Source[0-9]*|Patch[0-9]*|BuildRoot|Prefix):"
color brightblack "\<(Name|Version|Release|Url|URL):"
color brightblack start="^(Source|Patch)" end=":"
color brightblack "(i386|i486|i586|i686|athlon|ia64|alpha|alphaev5|alphaev56|alphapca56|alphaev6|alphaev67|sparc|sparcv9|sparc64armv3l|armv4b|armv4lm|ips|mipsel|ppc|ppc|iseries|ppcpseries|ppc64|m68k|m68kmint|Sgi|rs6000|i370|s390x|s390|noarch)"
color brightblack "(ifarch|ifnarch|ifos|ifnos)"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightyellow "%(if|else|endif|define|global|undefine)"
color brightyellow "%_?([A-Z_a-z_0-9_]*)"
color brightyellow start="%\{" end="\}"
color brightyellow start="%\{__" end="\}"
color brightyellow "\$(RPM_BUILD_ROOT)\>"
color brightmagenta "^%(build$|changelog|check$|clean$|description)"
color brightmagenta "^%(files|install$|package|prep$)"
color brightmagenta "^%(pre|preun|pretrans|post|postun|posttrans)"
color brightmagenta "^%(trigger|triggerin|triggerpostun|triggerun|verifyscript)"
color cyan "(^|[[:space:]])#([^{].*)?$"
color blue "^\*.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT
color brightwhite,cyan "TODO:?"

12
nano/syntax/ruby.nanorc Normal file
View File

@ -0,0 +1,12 @@
syntax "ruby" "\.rb$|Rakefile$"
color brightblack "\<(BEGIN|END|alias|and|begin|break|case|class|def|defined\?|do|else|elsif|end|ensure|false|for|if|in|module|next|nil|not|or|redo|rescue|retry|return|self|super|then|true|undef|unless|until|when|while|yield)\>"
color yellow "(^|[[:space:]]):[A-Za-z0-9_]+\>"
color magenta "/([^/]|(\\/))*/[iomx]*" "%r\{([^}]|(\\}))*\}[iomx]*"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color cyan start="^=begin$" end="^=end$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

10
nano/syntax/sed.nanorc Normal file
View File

@ -0,0 +1,10 @@
syntax "sed" "\.sed$"
header "^#!.*bin/(env +)?sed( |$)"
color red "[|^$.*+]"
color brightyellow "\{[0-9]+,?[0-9]*\}"
color magenta "\\."
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

18
nano/syntax/shell.nanorc Normal file
View File

@ -0,0 +1,18 @@
syntax "sh" "\.sh$" "\.bash$" "bashrc$" "bash_profile$"
header "^#!.*/(env +)?(ba|k|pdk)?sh[-0-9_]*( |$)"
color brightblue "^[A-Za-z0-9_+-]+[[:space:]]*\(\)"
color brightblack "\<(case|do|done|elif|else|esac|fi|for|function|if)\>"
color brightblack "\<(in|select|then|time|until|while)\>"
color brightblue "\<(echo|exit|export|let|local|read|return|set|shift|umask|unset)\>"
color brightblue "\<(source)\>"
color red "[{}()<>!=&|;`$]|\\|\[|\]|-(eq|ne|gt|lt|ge|le|s|n|z)\>"
color yellow ""(\\.|[^"])*""
color brightyellow "\$\{?[A-Za-z0-9_!@#$*?-]+\}?|`[^`]*`"
color yellow "'(\\.|[^'])*'"
color magenta "\\.?"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

35
nano/syntax/sql.nanorc Normal file
View File

@ -0,0 +1,35 @@
syntax "sql" "\.sql$" "sqliterc$"
icolor brightblack "\<(ALL|ASC|AS|ALTER|AND|ADD|AUTO_INCREMENT)\>"
icolor brightblack "\<(BETWEEN|BINARY|BOTH|BY|BOOLEAN)\>"
icolor brightblack "\<(CHANGE|CHECK|COLUMNS|COLUMN|CROSS|CREATE)\>"
icolor brightblack "\<(DATABASES|DATABASE|DATA|DELAYED|DESCRIBE|DESC|DISTINCT|DELETE|DROP|DEFAULT)\>"
icolor brightblack "\<(ENCLOSED|ESCAPED|EXISTS|EXPLAIN)\>"
icolor brightblack "\<(FIELDS|FIELD|FLUSH|FOR|FOREIGN|FUNCTION|FROM)\>"
icolor brightblack "\<(GROUP|GRANT|HAVING)\>"
icolor brightblack "\<(IGNORE|INDEX|INFILE|INSERT|INNER|INTO|IDENTIFIED|IN|IS|IF)\>"
icolor brightblack "\<(JOIN|KEYS|KILL|KEY)\>"
icolor brightblack "\<(LEADING|LIKE|LIMIT|LINES|LOAD|LOCAL|LOCK|LOW_PRIORITY|LEFT|LANGUAGE)\>"
icolor brightblack "\<(MODIFY|NATURAL|NOT|NULL|NEXTVAL)\>"
icolor brightblack "\<(OPTIMIZE|OPTION|OPTIONALLY|ORDER|OUTFILE|OR|OUTER|ON)\>"
icolor brightblack "\<(PROCEDURE|PROCEDURAL|PRIMARY)\>"
icolor brightblack "\<(READ|REFERENCES|REGEXP|RENAME|REPLACE|RETURN|REVOKE|RLIKE|RIGHT)\>"
icolor brightblack "\<(SHOW|SONAME|STATUS|STRAIGHT_JOIN|SELECT|SETVAL|SET)\>"
icolor brightblack "\<(TABLES|TERMINATED|TO|TRAILING|TRUNCATE|TABLE|TEMPORARY|TRIGGER|TRUSTED)\>"
icolor brightblack "\<(UNIQUE|UNLOCK|USE|USING|UPDATE|VALUES|VARIABLES|VIEW)\>"
icolor brightblack "\<(WITH|WRITE|WHERE|ZEROFILL|TYPE|XOR)\>"
color green "\<(VARCHAR|TINYINT|TEXT|DATE|SMALLINT|MEDIUMINT|INT|INTEGER|BIGINT|FLOAT|DOUBLE|DECIMAL|DATETIME|TIMESTAMP|TIME|YEAR|UNSIGNED|CHAR|TINYBLOB|TINYTEXT|BLOB|MEDIUMBLOB|MEDIUMTEXT|LONGBLOB|LONGTEXT|ENUM|BOOL|BINARY|VARBINARY)\>"
# SQLite meta commands
icolor brightblack "\.\<(databases|dump|echo|exit|explain|header(s)?|help)\>"
icolor brightblack "\.\<(import|indices|mode|nullvalue|output|prompt|quit|read)\>"
icolor brightblack "\.\<(schema|separator|show|tables|timeout|width)\>"
color brightcyan "\<(ON|OFF)\>"
color blue "\<([0-9]+)\>"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color yellow "`(\\.|[^\\`])*`"
color cyan "\-\-.*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,13 @@
syntax "systemd" "\.(service|socket|mount|slice|target|timer|path)$"
header "^\[Unit\]$"
color brightblack "^(Accept|After|Alias|AllowIsolate|Also|ANSI_COLOR|_AUDIT_LOGINUID|_AUDIT_SESSION|Backlog|Before|BindIPv6Only|BindsTo|BindToDevice|BlockIOReadBandwidth|BlockIOWeight|BlockIOWriteBandwidth|_BOOT_ID|Broadcast|BUG_REPORT_URL|BusName|Capabilities|CapabilityBoundingSet|CHASSIS|cipher|class|_CMDLINE|CODE_FILE|CODE_FUNC|CODE_LINE|_COMM|Compress|ConditionACPower|ConditionCapability|ConditionDirectoryNotEmpty|ConditionFileIsExecutable|ConditionFileNotEmpty|ConditionHost|ConditionKernelCommandLine|ConditionNull|ConditionPathExists|ConditionPathExistsGlob|ConditionPathIsDirectory|ConditionPathIsMountPoint|ConditionPathIsReadWrite|ConditionPathIsSymbolicLink|ConditionSecurity|ConditionVirtualization|Conflicts|ControlGroup|ControlGroupAttribute|ControlGroupModify|ControlGroupPersistent|controllers|Controllers|CPE_NAME|CPUAffinity|CPUSchedulingPolicy|CPUSchedulingPriority|CPUSchedulingResetOnFork|CPUShares|CrashChVT|CrashShell|__CURSOR|debug|DefaultControllers|DefaultDependencies|DefaultLimitAS|DefaultLimitCORE|DefaultLimitCPU|DefaultLimitDATA|DefaultLimitFSIZE|DefaultLimitLOCKS|DefaultLimitMEMLOCK|DefaultLimitMSGQUEUE|DefaultLimitNICE|DefaultLimitNOFILE|DefaultLimitNPROC|DefaultLimitRSS|DefaultLimitRTPRIO|DefaultLimitRTTIME|DefaultLimitSIGPENDING|DefaultLimitSTACK|DefaultStandardError|DefaultStandardOutput|Description|DeviceAllow|DeviceDeny|DirectoryMode|DirectoryNotEmpty|Documentation|DumpCore|entropy|Environment|EnvironmentFile|ERRNO|event_timeout|_EXE|ExecReload|ExecStart|ExecStartPost|ExecStartPre|ExecStop|ExecStopPost|ExecStopPre|filter|FONT|FONT_MAP|FONT_UNIMAP|ForwardToConsole|ForwardToKMsg|ForwardToSyslog|FreeBind|freq|FsckPassNo|fstab|_GID|Group|GuessMainPID|HandleHibernateKey|HandleLidSwitch|HandlePowerKey|HandleSuspendKey|hash|HibernateKeyIgnoreInhibited|HOME_URL|_HOSTNAME|ICON_NAME|ID|IdleAction|IdleActionSec|ID_LIKE|ID_MODEL|ID_MODEL_FROM_DATABASE|IgnoreOnIsolate|IgnoreOnSnapshot|IgnoreSIGPIPE|InaccessibleDirectories|InhibitDelayMaxSec|init|IOSchedulingClass|IOSchedulingPriority|IPTOS|IPTTL|JobTimeoutSec|JoinControllers|KeepAlive|KEYMAP|KEYMAP_TOGGLE|KillExcludeUsers|KillMode|KillOnlyUsers|KillSignal|KillUserProcesses|LidSwitchIgnoreInhibited|LimitAS|LimitCORE|LimitCPU|LimitDATA|LimitFSIZE|LimitLOCKS|LimitMEMLOCK|LimitMSGQUEUE|LimitNICE|LimitNOFILE|LimitNPROC|LimitRSS|LimitRTPRIO|LimitRTTIME|LimitSIGPENDING|LimitSTACK|link_priority|valueListenDatagram|ListenFIFO|ListenMessageQueue|ListenNetlink|ListenSequentialPacket|ListenSpecial|ListenStream|LogColor|LogLevel|LogLocation|LogTarget|luks|_MACHINE_ID|MakeDirectory|Mark|MaxConnections|MaxFileSec|MaxLevelConsole|MaxLevelKMsg|MaxLevelStore|MaxLevelSyslog|MaxRetentionSec|MemoryLimit|MemorySoftLimit|MESSAGE|MESSAGE_ID|MessageQueueMaxMessages|MessageQueueMessageSize|__MONOTONIC_TIMESTAMP|MountFlags|NAME|NAutoVTs|Nice|NonBlocking|NoNewPrivileges|NotifyAccess|OnActiveSec|OnBootSec|OnCalendar|OnFailure|OnFailureIsolate|OnStartupSec|OnUnitActiveSec|OnUnitInactiveSec|OOMScoreAdjust|Options|output|PAMName|PartOf|PassCredentials|PassSecurity|PathChanged|PathExists|PathExistsGlob|PathModified|PermissionsStartOnly|_PID|PIDFile|PipeSize|PowerKeyIgnoreInhibited|PRETTY_HOSTNAME|PRETTY_NAME|Priority|PRIORITY|PrivateNetwork|PrivateTmp|PropagatesReloadTo|pss|RateLimitBurst|RateLimitInterval|ReadOnlyDirectories|ReadWriteDirectories|__REALTIME_TIMESTAMP|ReceiveBuffer|RefuseManualStart|RefuseManualStop|rel|ReloadPropagatedFrom|RemainAfterExit|RequiredBy|Requires|RequiresMountsFor|RequiresOverridable|Requisite|RequisiteOverridable|ReserveVT|ResetControllers|Restart|RestartPreventExitStatus|RestartSec|RootDirectory|RootDirectoryStartOnly|RuntimeKeepFree|RuntimeMaxFileSize|RuntimeMaxUse|RuntimeWatchdogSec|samples|scale_x|scale_y|Seal|SecureBits|_SELINUX_CONTEXT|SendBuffer|SendSIGKILL|Service|ShowStatus|ShutdownWatchdogSec|size|SmackLabel|SmackLabelIPIn|SmackLabelIPOut|SocketMode|Sockets|SourcePath|_SOURCE_REALTIME_TIMESTAMP|SplitMode|StandardError|StandardInput|StandardOutput|StartLimitAction|StartLimitBurst|StartLimitInterval|static_node|StopWhenUnneeded|Storage|string_escape|none|replaceSuccessExitStatus|SupplementaryGroups|SUPPORT_URL|SuspendKeyIgnoreInhibited|SyslogFacility|SYSLOG_FACILITY|SyslogIdentifier|SYSLOG_IDENTIFIER|SyslogLevel|SyslogLevelPrefix|SYSLOG_PID|SystemCallFilter|SYSTEMD_ALIAS|_SYSTEMD_CGROUP|_SYSTEMD_OWNER_UID|SYSTEMD_READY|_SYSTEMD_SESSION|_SYSTEMD_UNIT|_SYSTEMD_USER_UNIT|SYSTEMD_WANTS|SystemKeepFree|SystemMaxFileSize|SystemMaxUse|SysVStartPriority|TCPCongestion|TCPWrapName|timeout|TimeoutSec|TimeoutStartSec|TimeoutStopSec|TimerSlackNSec|Transparent|_TRANSPORT|tries|TTYPath|TTYReset|TTYVHangup|TTYVTDisallocate|Type|_UID|UMask|Unit|User|UtmpIdentifier|VERSION|VERSION_ID|WantedBy|Wants|WatchdogSec|What|Where|WorkingDirectory)="
color brightblue "^\.include\>"
color red "="
color brightmagenta "^\[(Unit|Install|Service|Socket|Mount|Timer|Path)\]"
color brightyellow "\$MAINPID"
color brightcyan "\<(true|false)\>"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

8
nano/syntax/tex.nanorc Normal file
View File

@ -0,0 +1,8 @@
syntax "tex" "\.(tex|cls|ltx|sty|dtx|ins|bbl)$"
color brightyellow "\\[A-Za-z]+"
color brightmagenta "\\section"
color cyan "%.*"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

20
nano/syntax/vala.nanorc Normal file
View File

@ -0,0 +1,20 @@
syntax "vala" "\.vala$"
color green "\<(float|double|bool|char|int|uint|short|long|void|(un)?signed)\>"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<(for|if|while|do|else|case|default|switch|try|throw|catch)\>"
color brightblack "\<(inline|typedef|struct|enum|union|extern|static|const)\>"
color brightblack "\<(operator|new|delete|return|null|using)\>"
color brightblack "\<(class|override|private|public|signal|this|weak)\>"
color brightred "\<(goto|break|continue)\>"
color brightcyan "\<(true|false)\>"
color blue "\<([0-9]+)\>"
color red "[-+/*=<>?:!~%&|]" "->"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])//.*"
color cyan start="/\*" end="\*/"
color brightwhite,cyan "TODO:?"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

12
nano/syntax/vi.nanorc Normal file
View File

@ -0,0 +1,12 @@
syntax "vi" "(^|/|\.)(ex|vim)rc$|\.vim"
color brightblue "[A-Za-z_][A-Za-z0-9_]*[[:space:]]*[(]"
color black "[(]"
color brightblack "\<([nvxsoilc]?(nore|un)?map|[nvlx]n|[ico]?no|[cilovx][um]|s?unm)\>"
color brightblack "\<(snor|nun|nm|set|if|endif|let|unlet)\>"
color red "[!&=]"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])\"[^"]*$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

13
nano/syntax/xml.nanorc Normal file
View File

@ -0,0 +1,13 @@
syntax "xml" "\.([jrs]html?|sgml?|xml|opml|xslt?|plist)$"
header "<\?xml"
color brightmagenta start="<" end=">"
color brightblack " [a-z_-]+="
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color brightwhite,red "&"
color magenta "&(#[0-9]+|#x[0-9a-fA-F]+|[A-Za-z][A-Za-z0-9]*);"
color cyan start="<!--" end="-->"
color cyan start="<!DOCTYPE" end=">"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

View File

@ -0,0 +1,11 @@
syntax "xresources" "X(defaults|resources)$"
color green "^[[:alnum:]]+\*"
color brightyellow "\*[[:alnum:]]+\:"
color blue "\<[0-9]+\>"
color red "[*:=]"
color brightcyan "\<(true|false)\>"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

14
nano/syntax/yaml.nanorc Normal file
View File

@ -0,0 +1,14 @@
syntax "yaml" "\.ya?ml$"
header "^---" "%YAML"
color green "(^| )!!(binary|bool|float|int|map|null|omap|seq|set|str) "
color brightcyan "\<(YES|yes|Y|y|ON|on|NO|no|N|n|OFF|off)\>"
color brightcyan "\<(true|false)\>"
color red ":[[:space:]]" "\[" "\]" ":[[:space:]]+[|>]" "^[[:space:]]*- "
color brightyellow "[[:space:]][\*&][A-Za-z0-9]+"
color yellow ""(\\.|[^"])*"|'(\\.|[^'])*'"
color cyan "(^|[[:space:]])#([^{].*)?$"
color brightmagenta "^---" "^\.\.\." "^%YAML" "^%TAG"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

9
nano/syntax/yum.nanorc Normal file
View File

@ -0,0 +1,9 @@
syntax "yum" "\.repo$|yum.*\.conf$"
color brightblack "^[[:space:]]*[^=]*="
color brightmagenta "^[[:space:]]*\[.*\]$"
color brightyellow "\$(releasever|arch|basearch|uuid|YUM[0-9])"
color cyan "(^|[[:space:]])#([^{].*)?$"
color ,green "[[:space:]]+$"
color ,red " + +| + +"
# +EXTRALINT

37
oh-my-zsh/moe.zsh-theme Normal file
View File

@ -0,0 +1,37 @@
# -*- sh -*- vim:set ft=sh ai et sw=4 sts=4:
# It might be bash like, but I can't have my co-workers knowing I use zsh
for COLOR in CYAN WHITE YELLOW MAGENTA BLACK BLUE RED DEFAULT GREEN GREY; do
eval PR_$COLOR='%{$fg[${(L)COLOR}]%}'
eval PR_BOLD_$COLOR='%{$fg_bold[${(L)COLOR}]%}'
done
if [ "$EUID" -ne 0 ]; then
PROMPT='%{$fg_bold[white]%}[%{$fg_bold[green]%}%n%{$fg_bold[white]%}@%{$fg_bold[blue]%}%m %{$fg_bold[yellow]%}%~ %{$fg_bold[white]%}]%{$reset_color%}%(!.#.$) '
else
PROMPT='%{$fg_bold[white]%}[%{$fg_bold[red]%}%n%{$fg_bold[white]%}@%{$fg_bold[blue]%}%m %{$fg_bold[yellow]%}%~ %{$fg_bold[white]%}]%{$reset_color%}%(!.#.$) '
fi
RPS1='$(git_prompt_info)$(git_prompt_status) $(svn_prompt_info) %{$reset_color%}'
PR_RESET="%{$reset_color%}"
VCS_DIRTY_COLOR="${PR_RESET}${PR_BOLD_YELLOW}"
VCS_CLEAN_COLOR="${PR_RESET}${PR_BOLD_GREEN}"
# ########## COLOR ###########
# ########## SVN ###########
ZSH_THEME_SVN_PROMPT_PREFIX="${PR_RESET}${PR_BOLD_RED}[svn:"
ZSH_THEME_SVN_PROMPT_SUFFIX="${PR_RESET}${PR_BOLD_RED}]"
ZSH_THEME_SVN_PROMPT_DIRTY="${VCS_DIRTY_COLOR} ✘${VCS_SUFIX_COLOR}"
ZSH_THEME_SVN_PROMPT_CLEAN="${VCS_CLEAN_COLOR} ✔${VCS_SUFIX_COLOR}"
# ########## SVN ###########
# ########## GIT ###########
ZSH_THEME_GIT_PROMPT_PREFIX="${PR_RESET}${PR_BOLD_RED}[git:"
ZSH_THEME_GIT_PROMPT_SUFFIX="]"
ZSH_THEME_GIT_PROMPT_DIRTY=""
ZSH_THEME_GIT_PROMPT_CLEAN=""
ZSH_THEME_GIT_PROMPT_ADDED="${PR_RESET}${PR_BOLD_GREEN}✚${PR_RESET}"
ZSH_THEME_GIT_PROMPT_MODIFIED="${PR_RESET}${PR_BOLD_BLUE}✹${PR_RESET}"
ZSH_THEME_GIT_PROMPT_DELETED="${PR_RESET}${PR_BOLD_RED}✖${PR_RESET}"
ZSH_THEME_GIT_PROMPT_RENAMED="${PR_RESET}${PR_BOLD_MAGENTA}➜${PR_RESET}"
ZSH_THEME_GIT_PROMPT_UNMERGED="${PR_RESET}${PR_BOLD_YELLOW}═${PR_RESET}"
ZSH_THEME_GIT_PROMPT_UNTRACKED="${PR_RESET}${PR_BOLD_CYAN}✭${PR_RESET}"
# ########## GIT ###########

108
vim/colors/codeschool.vim Normal file
View File

@ -0,0 +1,108 @@
" Vim color file
" Converted from my Textmate Code School theme using Coloration
" http://astonj.com
set background=dark
highlight clear
if exists("syntax_on")
syntax reset
endif
let g:colors_name = "Code School 3"
hi Cursor ctermfg=16 ctermbg=145 cterm=NONE guifg=#182227 guibg=#9ea7a6 gui=NONE
hi Visual ctermfg=NONE ctermbg=59 cterm=NONE guifg=NONE guibg=#3f4b52 gui=NONE
hi CursorLine ctermfg=NONE ctermbg=23 cterm=NONE guifg=NONE guibg=#2e373b gui=NONE
hi CursorColumn ctermfg=NONE ctermbg=23 cterm=NONE guifg=NONE guibg=#2e373b gui=NONE
hi ColorColumn ctermfg=NONE ctermbg=23 cterm=NONE guifg=NONE guibg=#2e373b gui=NONE
hi LineNr ctermfg=102 ctermbg=23 cterm=NONE guifg=#84898c guibg=#2a343a gui=NONE
hi VertSplit ctermfg=59 ctermbg=59 cterm=NONE guifg=#252c31 guibg=#252c31 gui=NONE
hi MatchParen ctermfg=180 ctermbg=NONE cterm=underline guifg=#dda790 guibg=NONE gui=underline
hi StatusLine ctermfg=231 ctermbg=59 cterm=bold guifg=#f0f0f0 guibg=#575e61 gui=bold
hi StatusLineNC ctermfg=231 ctermbg=59 cterm=NONE guifg=#f0f0f0 guibg=#575e61 gui=NONE
hi Pmenu ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi PmenuSel ctermfg=NONE ctermbg=59 cterm=NONE guifg=NONE guibg=#3f4b52 gui=NONE
hi IncSearch ctermfg=16 ctermbg=107 cterm=NONE guifg=#182227 guibg=#8bb664 gui=NONE
hi Search ctermfg=NONE ctermbg=NONE cterm=underline guifg=NONE guibg=NONE gui=underline
hi Directory ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Folded ctermfg=247 ctermbg=16 cterm=NONE guifg=#9a9a9a guibg=#182227 gui=NONE
hi Normal ctermfg=231 ctermbg=16 cterm=NONE guifg=#f0f0f0 guibg=#252c31 gui=NONE
hi Boolean ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Character ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Comment ctermfg=247 ctermbg=NONE cterm=NONE guifg=#9a9a9a guibg=NONE gui=italic
hi Conditional ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi Constant ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Define ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi DiffAdd ctermfg=231 ctermbg=64 cterm=bold guifg=#f0f0f0 guibg=#43820d gui=bold
hi DiffDelete ctermfg=88 ctermbg=NONE cterm=NONE guifg=#880708 guibg=NONE gui=NONE
hi DiffChange ctermfg=231 ctermbg=23 cterm=NONE guifg=#f0f0f0 guibg=#1c3657 gui=NONE
hi DiffText ctermfg=231 ctermbg=24 cterm=bold guifg=#f0f0f0 guibg=#204a87 gui=bold
hi ErrorMsg ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE
hi WarningMsg ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE
hi Float ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Function ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi Identifier ctermfg=113 ctermbg=NONE cterm=NONE guifg=#99cf50 guibg=NONE gui=NONE
hi Keyword ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi Label ctermfg=107 ctermbg=NONE cterm=NONE guifg=#8bb664 guibg=NONE gui=NONE
hi NonText ctermfg=59 ctermbg=17 cterm=NONE guifg=#414e58 guibg=#232c31 gui=NONE
hi Number ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi Operator ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi PreProc ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi Special ctermfg=231 ctermbg=NONE cterm=NONE guifg=#f0f0f0 guibg=NONE gui=NONE
hi SpecialKey ctermfg=59 ctermbg=23 cterm=NONE guifg=#414e58 guibg=#252c31 gui=NONE
hi Statement ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi StorageClass ctermfg=113 ctermbg=NONE cterm=NONE guifg=#99cf50 guibg=NONE gui=NONE
hi String ctermfg=107 ctermbg=NONE cterm=NONE guifg=#8bb664 guibg=NONE gui=NONE
hi Tag ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi Title ctermfg=231 ctermbg=NONE cterm=bold guifg=#f0f0f0 guibg=NONE gui=bold
hi Todo ctermfg=247 ctermbg=NONE cterm=inverse,bold guifg=#9a9a9a guibg=NONE gui=inverse,bold,italic
hi Type ctermfg=153 ctermbg=NONE cterm=NONE guifg=#b5d8f6 guibg=NONE gui=NONE
hi Underlined ctermfg=NONE ctermbg=NONE cterm=underline guifg=NONE guibg=NONE gui=underline
hi rubyClass ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi rubyFunction ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi rubyInterpolationDelimiter ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE
hi rubySymbol ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi rubyConstant ctermfg=146 ctermbg=NONE cterm=NONE guifg=#bfabcb guibg=NONE gui=NONE
hi rubyStringDelimiter ctermfg=107 ctermbg=NONE cterm=NONE guifg=#8bb664 guibg=NONE gui=NONE
hi rubyBlockParameter ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi rubyInstanceVariable ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi rubyInclude ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi rubyGlobalVariable ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi rubyRegexp ctermfg=179 ctermbg=NONE cterm=NONE guifg=#e9c062 guibg=NONE gui=NONE
hi rubyRegexpDelimiter ctermfg=179 ctermbg=NONE cterm=NONE guifg=#e9c062 guibg=NONE gui=NONE
hi rubyEscape ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi rubyControl ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi rubyClassVariable ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi rubyOperator ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi rubyException ctermfg=180 ctermbg=NONE cterm=NONE guifg=#dda790 guibg=NONE gui=NONE
hi rubyPseudoVariable ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi rubyRailsUserClass ctermfg=146 ctermbg=NONE cterm=NONE guifg=#bfabcb guibg=NONE gui=NONE
hi rubyRailsARAssociationMethod ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi rubyRailsARMethod ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi rubyRailsRenderMethod ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi rubyRailsMethod ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi erubyDelimiter ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE
hi erubyComment ctermfg=247 ctermbg=NONE cterm=NONE guifg=#9a9a9a guibg=NONE gui=italic
hi erubyRailsMethod ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi htmlTag ctermfg=111 ctermbg=NONE cterm=NONE guifg=#89bdff guibg=NONE gui=NONE
hi htmlEndTag ctermfg=111 ctermbg=NONE cterm=NONE guifg=#89bdff guibg=NONE gui=NONE
hi htmlTagName ctermfg=111 ctermbg=NONE cterm=NONE guifg=#89bdff guibg=NONE gui=NONE
hi htmlArg ctermfg=111 ctermbg=NONE cterm=NONE guifg=#89bdff guibg=NONE gui=NONE
hi htmlSpecialChar ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi javaScriptFunction ctermfg=113 ctermbg=NONE cterm=NONE guifg=#99cf50 guibg=NONE gui=NONE
hi javaScriptRailsFunction ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi javaScriptBraces ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE
hi yamlKey ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi yamlAnchor ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi yamlAlias ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi yamlDocumentHeader ctermfg=107 ctermbg=NONE cterm=NONE guifg=#8bb664 guibg=NONE gui=NONE
hi cssURL ctermfg=74 ctermbg=NONE cterm=NONE guifg=#68a9eb guibg=NONE gui=NONE
hi cssFunctionName ctermfg=186 ctermbg=NONE cterm=NONE guifg=#dad085 guibg=NONE gui=NONE
hi cssColor ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi cssPseudoClassId ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi cssClassName ctermfg=153 ctermbg=NONE cterm=NONE guifg=#bcdbff guibg=NONE gui=NONE
hi cssValueLength ctermfg=68 ctermbg=NONE cterm=NONE guifg=#3c98d9 guibg=NONE gui=NONE
hi cssCommonAttr ctermfg=151 ctermbg=NONE cterm=NONE guifg=#a7cfa3 guibg=NONE gui=NONE
hi cssBraces ctermfg=NONE ctermbg=NONE cterm=NONE guifg=NONE guibg=NONE gui=NONE

292
vim/colors/eldar.vim Normal file
View File

@ -0,0 +1,292 @@
" ---------------------------------------------------------
" ______ _ _
" | ____| | | |
" | |__ | | __| | __ _ _ __
" | __| | |/ _` |/ _` | '__|
" | |____| | (_| | (_| | |
" |______|_|\__,_|\__,_|_|
"
" ---------------------------------------------------------
"
" Maintainer: Alexander Gude
" Email: alex.public.account@gmail.com
" File: eldar.vim
" URL: github.com/agude/vim-eldar
" License: MIT
"
" ---------------------------------------------------------
"
" Copyright (c) 2016 Alexander Gude
"
" Permission is hereby granted, free of charge, to any per
" son obtaining a copy of this software and associated doc
" umentation files (the “Software”), to deal in the Soft
" ware without restriction, including without limitation
" the rights to use, copy, modify, merge, publish, distrib
" ute, 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 PARTICU
" LAR 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 CON
" TRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CON
" NECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
" THE SOFTWARE.
"
" ---------------------------------------------------------
" Eldar is designed for dark backgrounds
set background=dark
highlight clear
if exists('syntax_on')
syntax reset
endif
let g:colors_name = 'eldar'
" Define colors (Tango is the default)
" GUI colors
let s:red = get(g:, 'eldar_red', '#EF2929')
let s:yellow = get(g:, 'eldar_yellow', '#FCE94F')
let s:green = get(g:, 'eldar_green', '#8AE234')
let s:cyan = get(g:, 'eldar_cyan', '#34E2E2')
let s:blue = get(g:, 'eldar_blue', '#729FCF')
let s:magenta = get(g:, 'eldar_magenta', '#AD7FA8')
let s:gui_text = get(g:, 'eldar_text', 'White')
let s:gui_bg = get(g:, 'eldar_background', 'Black')
" Terminal colors
let s:term_text = get(g:, 'eldar_term_text', 'NONE')
let s:term_bg = get(g:, 'eldar_term_background', 'NONE')
" The ColourAssignment map and function to unpack it are from the bandit
" colorscheme by Al Bunden, available here:
" http://www.cgtk.co.uk/vim-scripts/bandit
let s:ColourAssignment = {}
" Unspecified colours default to NONE, EXCEPT cterm(.*) which default to matching gui(.*)
"
" In most cases, only GUIFG is therefore important unless support for Black and White
" terminals is essential
" Editor settings
" ---------------
let s:ColourAssignment['Normal'] = {'GUIFG': s:gui_text, 'GUIBG': s:gui_bg, 'CTERMBG': s:term_bg, 'CTERMFG': s:term_text}
let s:ColourAssignment['Cursor'] = {'GUI': 'Reverse'}
let s:ColourAssignment['CursorLine'] = {'GUI': 'NONE', 'GUIBG': 'Black'}
let s:ColourAssignment['LineNr'] = {'GUIFG': 'DarkGray'}
let s:ColourAssignment['CursorLineNr'] = {'GUIFG': 'White'}
" Number column
" -------------
let s:ColourAssignment['CursorColumn'] = {'GUIBG': 'DarkGrey'}
let s:ColourAssignment['Folded'] = {'GUIFG': 'Cyan', 'GUIBG': 'DarkGrey'}
let s:ColourAssignment['FoldColumn'] = {'GUIBG': 'DarkGrey'}
highlight! link SignColumn FoldColumn
" Window/Tab delimiters
" ---------------------
let s:ColourAssignment['VertSplit'] = {'GUIFG': 'White', 'GUIBG': 'NONE'}
let s:ColourAssignment['ColorColumn'] = {'GUIBG': 'DarkGray'}
let s:ColourAssignment['TabLine'] = {'GUIFG': 'White', 'GUIBG': 'DarkGray'}
let s:ColourAssignment['TabLineFill'] = {'GUIBG': 'DarkGray'}
let s:ColourAssignment['TabLineSel'] = {'GUIFG': 'Black', 'GUIBG': 'Gray'}
" File Navigation / Searching
" ---------------------------
let s:ColourAssignment['Directory'] = {'GUIFG': s:blue, 'CTERMFG': 'Blue', 'GUI': 'Bold'}
let s:ColourAssignment['Search'] = {'GUIFG': 'Black', 'GUIBG': s:yellow, 'CTERMFG': 'yellow', 'CTERMBG': 'black', 'GUI': 'Bold', 'CTERM': 'Reverse,Bold'}
let s:ColourAssignment['IncSearch'] = {'GUI': 'Reverse'}
" Prompt/Status
" -------------
let s:ColourAssignment['StatusLine'] = {'GUIFG': 'White', 'GUIBG': s:gui_bg, 'GUI': 'Bold,Reverse', 'CTERMFG': 'White', 'CTERMBG': s:term_bg}
let s:ColourAssignment['StatusLineNC'] = {'GUIFG': 'White', 'GUIBG': s:gui_bg, 'GUI': 'Reverse', 'CTERMFG': 'White', 'CTERMBG': s:term_bg}
let s:ColourAssignment['WildMenu'] = {'GUIFG': 'White', 'GUIBG': 'DarkGrey', 'GUI': 'Bold'}
let s:ColourAssignment['Question'] = {'GUIFG': s:blue, 'CTERMFG': 'Blue'}
let s:ColourAssignment['Title'] = {'GUI': 'Bold'}
let s:ColourAssignment['ModeMsg'] = {'GUI': 'Bold'}
let s:ColourAssignment['MoreMsg'] = {'GUIFG': s:green, 'CTERMFG': 'Green'}
" Visual aid
" ----------
let s:ColourAssignment['MatchParen'] = {'GUIBG': s:cyan, 'CTERMBG': 'cyan'}
let s:ColourAssignment['Visual'] = {'GUIBG': 'DarkGrey'}
highlight! link VisualNOS Visual
let s:ColourAssignment['NonText'] = {'GUIFG': s:blue, 'CTERMFG': 'blue'}
let s:ColourAssignment['Todo'] = {'GUIFG': 'Black', 'GUIBG': s:yellow, 'CTERMBG': 'yellow'}
let s:ColourAssignment['Underlined'] = {'GUIFG': s:cyan, 'CTERMFG': 'cyan', 'GUI': 'Underline'}
let s:ColourAssignment['Error'] = {'GUIFG': s:red, 'GUIBG': 'Black', 'CTERMFG': 'red', 'GUI': 'Reverse,Bold'}
let s:ColourAssignment['ErrorMsg'] = {'GUIFG': s:red, 'GUIBG': 'White', 'CTERMFG': 'red', 'GUI': 'Reverse,Bold'}
let s:ColourAssignment['WarningMsg'] = {'GUIFG': s:red, 'CTERMFG': 'red'}
let s:ColourAssignment['Ignore'] = {'GUIFG': 'bg', 'CTERMFG': 'Black'}
let s:ColourAssignment['SpecialKey'] = {'GUIFG': s:cyan, 'CTERMFG': 'Cyan'}
" Variable types
" --------------
let s:ColourAssignment['Constant'] = {'GUIFG': s:magenta, 'CTERMFG': 'magenta'}
let s:ColourAssignment['Number'] = {'GUIFG': s:red, 'CTERMFG': 'red'}
highlight! link String Constant
highlight! link Boolean Constant
highlight! link Float Number
let s:ColourAssignment['Identifier'] = {'GUIFG': s:green, 'CTERMFG': 'green', 'GUI': 'Bold'}
highlight! link Function Identifier
" Comments
" --------
let s:ColourAssignment['Comment'] = {'GUIFG': s:cyan, 'CTERMFG': 'cyan'}
highlight! link SpecialComment Special
" Language constructs
" -------------------
let s:ColourAssignment['Statement'] = {'GUIFG': s:yellow, 'CTERMFG': 'yellow', 'GUI': 'Bold'}
highlight! link Conditional Statement
highlight! link Repeat Statement
highlight! link Label Statement
highlight! link Operator Statement
highlight! link Keyword Statement
highlight! link Exception Statement
let s:ColourAssignment['Special'] = {'GUIFG': s:red, 'CTERMFG': 'red'}
highlight! link SpecialChar Special
highlight! link Tag Special
highlight! link Delimiter Special
highlight! link Debug Special
" C like
" ------
let s:ColourAssignment['PreProc'] = {'GUIFG': s:blue, 'CTERMFG': 'blue', 'GUI': 'Bold'}
highlight! link Include PreProc
highlight! link Define PreProc
highlight! link Macro PreProc
highlight! link PreCondit PreProc
let s:ColourAssignment['Type'] = {'GUIFG': s:green, 'CTERMFG': 'green', 'GUI': 'Bold'}
let s:ColourAssignment['Structure'] = {'GUIFG': s:magenta, 'CTERMFG': 'magenta'}
highlight! link StorageClass Type
highlight! link Typedef Type
" Diff
" ----
let s:ColourAssignment['DiffAdd'] = {'GUIFG': s:green, 'GUIBG': 'Black', 'CTERMFG': 'Green', 'GUI': 'Reverse,Bold'}
let s:ColourAssignment['DiffChange'] = {'GUIFG': 'NONE'}
let s:ColourAssignment['DiffDelete'] = {'GUIFG': s:red, 'GUIBG': 'Black', 'CTERMFG': 'Red', 'GUI': 'Reverse,Bold'}
let s:ColourAssignment['DiffText'] = {'GUIFG': s:blue, 'GUIBG': 'Black', 'CTERMFG': 'Blue', 'GUI': 'Reverse,Bold'}
" Completion menu
" ---------------
let s:ColourAssignment['Pmenu'] = {'GUIFG': 'Black', 'GUIBG': 'Grey'}
let s:ColourAssignment['PmenuSel'] = {'GUIFG': s:yellow, 'GUIBG': 'DarkGrey', 'GUI': 'Bold', 'CTERMFG': 'yellow'}
let s:ColourAssignment['PmenuThumb'] = {'GUIBG': 'DarkGrey'}
highlight! link PmenuSbar Pmenu
" Spelling
" --------
let s:ColourAssignment['SpellBad'] = {'GUIFG': 'NONE', 'GUISP': s:red, 'CTERMFG': 'red', 'GUI': 'undercurl'}
let s:ColourAssignment['SpellCap'] = {'GUIFG': 'NONE', 'GUISP': s:blue, 'CTERMFG': 'blue', 'GUI': 'undercurl'}
let s:ColourAssignment['SpellLocal'] = {'GUIFG': 'NONE', 'GUISP': s:yellow, 'CTERMFG': 'yellow', 'GUI': 'undercurl'}
let s:ColourAssignment['SpellRare'] = {'GUIFG': 'NONE', 'GUISP': s:green, 'CTERMFG': 'green', 'GUI': 'undercurl'}
" Text Formatting
" ---------------
let s:ColourAssignment['Italic'] = {'GUIFG': 'White', 'GUI': 'Italic'}
let s:ColourAssignment['Bold'] = {'GUIFG': 'White', 'GUI': 'Bold'}
let s:ColourAssignment['BoldItalic'] = {'GUIFG': 'White', 'GUI': 'Italic,Bold'}
highlight! link htmlItalic Italic
highlight! link htmlBold Bold
highlight! link htmlBoldItalic BoldItalic
" Function to translate the ColourAssignments to highlight lines
let s:colours = {}
let s:valid_cterm_colours =
\ [
\ 'Black', 'DarkBlue', 'DarkGreen', 'DarkCyan',
\ 'DarkRed', 'DarkMagenta', 'Brown', 'DarkYellow',
\ 'LightGray', 'LightGrey', 'Gray', 'Grey',
\ 'DarkGray', 'DarkGrey', 'Blue', 'LightBlue',
\ 'Green', 'LightGreen', 'Cyan', 'LightCyan',
\ 'Red', 'LightRed', 'Magenta', 'LightMagenta',
\ 'Yellow', 'LightYellow', 'White',
\ ]
for s:key in keys(s:ColourAssignment)
let s:colours = s:ColourAssignment[s:key]
if has_key(s:colours, 'TERM')
let s:term = s:colours['TERM']
else
let s:term = 'NONE'
endif
if has_key(s:colours, 'GUI')
let s:gui = s:colours['GUI']
else
let s:gui = 'NONE'
endif
if has_key(s:colours, 'GUIFG')
let s:guifg = s:colours['GUIFG']
else
let s:guifg = 'NONE'
endif
if has_key(s:colours, 'GUIBG')
let s:guibg = s:colours['GUIBG']
else
let s:guibg = 'NONE'
endif
if has_key(s:colours, 'CTERM')
let s:cterm = s:colours['CTERM']
else
let s:cterm = s:gui
endif
if has_key(s:colours, 'CTERMFG')
let s:ctermfg = s:colours['CTERMFG']
else
if index(s:valid_cterm_colours, s:guifg) != -1
let s:ctermfg = s:guifg
else
let s:ctermfg = 'NONE'
endif
endif
if has_key(s:colours, 'CTERMBG')
let s:ctermbg = s:colours['CTERMBG']
else
if index(s:valid_cterm_colours, s:guibg) != -1
let s:ctermbg = s:guibg
else
let s:ctermbg = 'NONE'
endif
endif
if has_key(s:colours, 'GUISP')
let s:guisp = s:colours['GUISP']
else
let s:guisp = 'NONE'
endif
if s:key =~# '^\k*$'
execute 'highlight '.s:key.' term='.s:term.' cterm='.s:cterm.' gui='.s:gui.' ctermfg='.s:ctermfg.' guifg='.s:guifg.' ctermbg='.s:ctermbg.' guibg='.s:guibg.' guisp='.s:guisp
endif
endfor

307
vim/colors/wombat256i.vim Normal file
View File

@ -0,0 +1,307 @@
" Vim color file
" Maintainer: David Liang (bmdavll at gmail dot com)
" Last Change: November 28 2008
"
" wombat256.vim - a modified version of Wombat by Lars Nielsen that also
" works on xterms with 88 or 256 colors. The algorithm for approximating the
" GUI colors with the xterm palette is from desert256.vim by Henry So Jr.
" Minor changes by Daniel Solstad (http://dsolstad.com)
" - Changed the static background color to terminal default, which makes it transparent (if your terminal is)
" - Changed colors of line numbering
" - Changed non text to nothing. Keeping space you havn't written on yet the same as the rest, and not hard black.
set background=dark
if version > 580
hi clear
if exists("syntax_on")
syntax reset
endif
endif
let g:colors_name = "wombat256i"
if !has("gui_running") && &t_Co != 88 && &t_Co != 256
finish
endif
" functions {{{
" returns an approximate grey index for the given grey level
fun <SID>grey_number(x)
if &t_Co == 88
if a:x < 23
return 0
elseif a:x < 69
return 1
elseif a:x < 103
return 2
elseif a:x < 127
return 3
elseif a:x < 150
return 4
elseif a:x < 173
return 5
elseif a:x < 196
return 6
elseif a:x < 219
return 7
elseif a:x < 243
return 8
else
return 9
endif
else
if a:x < 14
return 0
else
let l:n = (a:x - 8) / 10
let l:m = (a:x - 8) % 10
if l:m < 5
return l:n
else
return l:n + 1
endif
endif
endif
endfun
" returns the actual grey level represented by the grey index
fun <SID>grey_level(n)
if &t_Co == 88
if a:n == 0
return 0
elseif a:n == 1
return 46
elseif a:n == 2
return 92
elseif a:n == 3
return 115
elseif a:n == 4
return 139
elseif a:n == 5
return 162
elseif a:n == 6
return 185
elseif a:n == 7
return 208
elseif a:n == 8
return 231
else
return 255
endif
else
if a:n == 0
return 0
else
return 8 + (a:n * 10)
endif
endif
endfun
" returns the palette index for the given grey index
fun <SID>grey_color(n)
if &t_Co == 88
if a:n == 0
return 16
elseif a:n == 9
return 79
else
return 79 + a:n
endif
else
if a:n == 0
return 16
elseif a:n == 25
return 231
else
return 231 + a:n
endif
endif
endfun
" returns an approximate color index for the given color level
fun <SID>rgb_number(x)
if &t_Co == 88
if a:x < 69
return 0
elseif a:x < 172
return 1
elseif a:x < 230
return 2
else
return 3
endif
else
if a:x < 75
return 0
else
let l:n = (a:x - 55) / 40
let l:m = (a:x - 55) % 40
if l:m < 20
return l:n
else
return l:n + 1
endif
endif
endif
endfun
" returns the actual color level for the given color index
fun <SID>rgb_level(n)
if &t_Co == 88
if a:n == 0
return 0
elseif a:n == 1
return 139
elseif a:n == 2
return 205
else
return 255
endif
else
if a:n == 0
return 0
else
return 55 + (a:n * 40)
endif
endif
endfun
" returns the palette index for the given R/G/B color indices
fun <SID>rgb_color(x, y, z)
if &t_Co == 88
return 16 + (a:x * 16) + (a:y * 4) + a:z
else
return 16 + (a:x * 36) + (a:y * 6) + a:z
endif
endfun
" returns the palette index to approximate the given R/G/B color levels
fun <SID>color(r, g, b)
" get the closest grey
let l:gx = <SID>grey_number(a:r)
let l:gy = <SID>grey_number(a:g)
let l:gz = <SID>grey_number(a:b)
" get the closest color
let l:x = <SID>rgb_number(a:r)
let l:y = <SID>rgb_number(a:g)
let l:z = <SID>rgb_number(a:b)
if l:gx == l:gy && l:gy == l:gz
" there are two possibilities
let l:dgr = <SID>grey_level(l:gx) - a:r
let l:dgg = <SID>grey_level(l:gy) - a:g
let l:dgb = <SID>grey_level(l:gz) - a:b
let l:dgrey = (l:dgr * l:dgr) + (l:dgg * l:dgg) + (l:dgb * l:dgb)
let l:dr = <SID>rgb_level(l:gx) - a:r
let l:dg = <SID>rgb_level(l:gy) - a:g
let l:db = <SID>rgb_level(l:gz) - a:b
let l:drgb = (l:dr * l:dr) + (l:dg * l:dg) + (l:db * l:db)
if l:dgrey < l:drgb
" use the grey
return <SID>grey_color(l:gx)
else
" use the color
return <SID>rgb_color(l:x, l:y, l:z)
endif
else
" only one possibility
return <SID>rgb_color(l:x, l:y, l:z)
endif
endfun
" returns the palette index to approximate the 'rrggbb' hex string
fun <SID>rgb(rgb)
let l:r = ("0x" . strpart(a:rgb, 0, 2)) + 0
let l:g = ("0x" . strpart(a:rgb, 2, 2)) + 0
let l:b = ("0x" . strpart(a:rgb, 4, 2)) + 0
return <SID>color(l:r, l:g, l:b)
endfun
" sets the highlighting for the given group
fun <SID>X(group, fg, bg, attr)
if a:fg != ""
exec "hi ".a:group." guifg=#".a:fg." ctermfg=".<SID>rgb(a:fg)
endif
if a:bg != ""
exec "hi ".a:group." guibg=#".a:bg." ctermbg=".<SID>rgb(a:bg)
endif
if a:attr != ""
if a:attr == 'italic'
exec "hi ".a:group." gui=".a:attr." cterm=none"
else
exec "hi ".a:group." gui=".a:attr." cterm=".a:attr
endif
endif
endfun
" }}}
call <SID>X("Normal", "cccccc", "", "none")
call <SID>X("Cursor", "222222", "ecee90", "none")
call <SID>X("CursorLine", "", "32322e", "none")
call <SID>X("CursorColumn", "", "2d2d2d", "")
"CursorIM
"Question
"IncSearch
call <SID>X("Search", "444444", "af87d7", "")
call <SID>X("MatchParen", "ecee90", "857b6f", "bold")
call <SID>X("SpecialKey", "6c6c6c", "", "none")
call <SID>X("Visual", "ecee90", "597418", "none")
call <SID>X("LineNr", "FFFFFF", "242424", "none")
call <SID>X("Folded", "a0a8b0", "404048", "none")
call <SID>X("Title", "f6f3e8", "", "bold")
call <SID>X("VertSplit", "444444", "444444", "none")
call <SID>X("StatusLine", "f6f3e8", "444444", "italic")
call <SID>X("StatusLineNC", "857b6f", "444444", "none")
"Scrollbar
"Tooltip
"Menu
"WildMenu
call <SID>X("Pmenu", "f6f3e8", "444444", "")
call <SID>X("PmenuSel", "121212", "caeb82", "")
call <SID>X("WarningMsg", "ff0000", "", "")
"ErrorMsg
"ModeMsg
"MoreMsg
"Directory
"DiffAdd
"DiffChange
"DiffDelete
"DiffText
" syntax highlighting
call <SID>X("Number", "e5786d", "", "none")
call <SID>X("Constant", "e5786d", "", "none")
call <SID>X("String", "95e454", "", "italic")
call <SID>X("Comment", "c0bc6c", "", "italic")
call <SID>X("Identifier", "caeb82", "", "none")
call <SID>X("Keyword", "87afff", "", "none")
call <SID>X("Statement", "87afff", "", "none")
call <SID>X("Function", "caeb82", "", "none")
call <SID>X("PreProc", "e5786d", "", "none")
call <SID>X("Type", "caeb82", "", "none")
call <SID>X("Special", "ffdead", "", "none")
call <SID>X("Todo", "857b6f", "", "italic")
"Underlined
"Error
"Ignore
hi! link VisualNOS Visual
hi! link FoldColumn Folded
" delete functions {{{
delf <SID>X
delf <SID>rgb
delf <SID>color
delf <SID>rgb_color
delf <SID>rgb_level
delf <SID>rgb_number
delf <SID>grey_color
delf <SID>grey_level
delf <SID>grey_number
" }}}
" vim:set ts=4 sw=4 noet fdm=marker:

467
vim/colors/zenburn.vim Normal file
View File

@ -0,0 +1,467 @@
" Vim color file
" Maintainer: Jani Nurminen <slinky@iki.fi>
" URL: http://kippura.org/zenburnpage/
" License: GNU GPL <http://www.gnu.org/licenses/gpl.html>
"
" Nothing too fancy, just some alien fruit salad to keep you in the zone.
" This syntax file was designed to be used with dark environments and
" low light situations. Of course, if it works during a daybright office, go
" ahead :)
"
" Owes heavily to other Vim color files! With special mentions
" to "BlackDust", "Camo" and "Desert".
"
" To install, copy to ~/.vim/colors directory.
"
" Alternatively, you can use Vimball installation:
" vim zenburn.vba
" :so %
" :q
"
" For details, see :help vimball
"
" After installation, use it with :colorscheme zenburn.
" See also :help syntax
"
" Credits:
" - Jani Nurminen - original Zenburn, maintainer
" - Steve Hall & Cream posse - higher-contrast Visual selection
" - Kurt Maier - 256 color console coloring, low and high contrast toggle,
" bug fixing
" - Charlie - spotted too bright StatusLine in non-high contrast mode
" - Pablo Castellazzi - CursorLine fix for 256 color mode
" - Tim Smith - force dark background
" - John Gabriele - spotted bad Ignore-group handling
" - Zac Thompson - spotted invisible NonText in low contrast mode
" - Christophe-Marie Duquesne - suggested making a Vimball,
" suggested support for ctags_highlighting.vim
" - Andrew Wagner - noted the CursorColumn bug (guifg was unintentionally set),
" unify CursorColumn colour
" - Martin Langasek - clarify the license, whitespace fixes
" - Marcin Szamotulski - support autocomplete for Zenburn configuration
" parameters
" - Clayton Parker (claytron) - Convinced by Kurt Maier to use Zenburn. Point
" out issues with LineNr, fix directory styles, and their usage in MacVim.
" - Paweł Piekarski - Spotted bad FoldColumn and TabLine. Made better
" FoldColumn colors, fixed TabLine colors.
" - Jim - Fix for missing Include group for terminal
" - Peter (Sakartu) - ColorColumn fixes
" - Please see git log for the others not listed here
"
" CONFIGURABLE PARAMETERS:
"
" You can use the default (don't set any parameters), or you can
" set some parameters to tweak the Zenburn colours.
"
" To use them, put them into your .vimrc file before loading the color scheme,
" example:
" let g:zenburn_high_Contrast=1
" colors zenburn
"
" You can also do ":let g:zenburn" then hit Ctrl-d or Tab to scroll through the
" list of configurable parameters.
"
" * You can now set a darker background for bright environments. To activate, use:
" let g:zenburn_high_Contrast = 1
"
" * For transparent terminals set the background to black with:
" let g:zenburn_transparent = 1
"
" * For example, Vim help files uses the Ignore-group for the pipes in tags
" like "|somelink.txt|". By default, the pipes are not visible, as they
" map to Ignore group. If you wish to enable coloring of the Ignore group,
" set the following parameter to 1. Warning, it might make some syntax files
" look strange.
"
" let g:zenburn_color_also_Ignore = 1
"
" * To get more contrast to the Visual selection, use
"
" let g:zenburn_alternate_Visual = 1
"
" Note: this is enabled only if the old-style Visual
" if used, see g:zenburn_old_Visual
"
" * To use alternate colouring for Error message, use
"
" let g:zenburn_alternate_Error = 1
"
" * The new default for Include is a duller orange. To use the original
" colouring for Include, use
"
" let g:zenburn_alternate_Include = 1
"
" * To disable underlining for Labels, use
"
" let g:zenburn_disable_Label_underline = 1
"
" * Work-around to a Vim bug, it seems to misinterpret ctermfg and 234 and 237
" as light values, and sets background to light for some people. If you have
" this problem, use:
"
" let g:zenburn_force_dark_Background = 1
"
" * By default the CursorColumn is of a lighter colour. I find it more readable
" that way, but some people may want to align it with the darker CursorLine
" color, for visual uniformity. To do so, use:
"
" let g:zenburn_unified_CursorColumn = 1
"
" Note: you can ignore this unless you use
" ":set cursorline cursorcolumn", since otherwise the effect won't be
" seen.
"
" * New (dark) Visual coloring has been introduced.
" The dark Visual is more aligned with the rest of the colour scheme,
" especially if you use line numbers. If you wish to use the
" old Visual coloring, use
"
" let g:zenburn_old_Visual = 1
"
" Default is to use the new Visual.
"
" * EXPERIMENTAL FEATURE: Zenburn would like to support TagHighlight
" (an evolved ctags-highlighter) by Al Budden (homepage:
" http://www.cgtk.co.uk/vim-scripts/taghighlight).
" Current support status is broken: there is no automatic detection of
" TagHighlight, no specific language support; however there is some basic
" support for Python. If you are a user of TagHighlight and want to help,
" please enable:
"
" let g:zenburn_enable_TagHighlight=1
"
" and improve the corresponding block at the end of the file.
"
" NOTE:
"
" * To turn the parameter(s) back to defaults, use UNLET or set them to 0:
"
" unlet g:zenburn_alternate_Include
" or
" let g:zenburn_alternate_Include = 0
"
"
" That's it, enjoy!
"
" TODO
" - Visual alternate color is broken? Try GVim >= 7.0.66 if you have trouble
" - IME colouring (CursorIM)
" Finish if we are in a term lacking 256 color support
if ! has("gui_running") && &t_Co <= 255
finish
endif
" Set defaults, but keep any parameters already set by the user
if ! exists("g:zenburn_high_Contrast")
let g:zenburn_high_Contrast = 0
endif
if ! exists("g:zenburn_transparent")
let g:zenburn_transparent = 0
endif
if ! exists("g:zenburn_color_also_Ignore")
let g:zenburn_color_also_Ignore = 0
endif
if ! exists("g:zenburn_alternate_Error")
let g:zenburn_alternate_Error = 0
endif
if ! exists("g:zenburn_force_dark_Background")
let g:zenburn_force_dark_Background = 0
endif
if ! exists("g:zenburn_alternate_Visual")
let g:zenburn_alternate_Visual = 0
endif
if ! exists("g:zenburn_alternate_Include")
let g:zenburn_alternate_Include = 0
endif
if ! exists("g:zenburn_disable_Label_underline")
let g:zenburn_disable_Label_underline = 0
endif
if ! exists("g:zenburn_unified_CursorColumn")
let g:zenburn_unified_CursorColumn = 0
endif
if ! exists("g:zenburn_old_Visual")
let g:zenburn_old_Visual = 0
endif
if ! exists("g:zenburn_enable_TagHighlight")
let g:zenburn_enable_TagHighlight = 0
endif
" -----------------------------------------------
set background=dark
hi clear
if exists("syntax_on")
syntax reset
endif
let g:colors_name="zenburn"
hi Boolean guifg=#dca3a3 ctermfg=181
hi Character guifg=#dca3a3 gui=bold ctermfg=181 cterm=bold
hi Comment guifg=#7f9f7f gui=italic ctermfg=108
hi Conditional guifg=#f0dfaf gui=bold ctermfg=223 cterm=bold
hi Constant guifg=#dca3a3 gui=bold ctermfg=181 cterm=bold
hi Cursor guifg=#000d18 guibg=#8faf9f gui=bold ctermfg=233 ctermbg=109 cterm=bold
hi Debug guifg=#bca3a3 gui=bold ctermfg=181 cterm=bold
hi Define guifg=#ffcfaf gui=bold ctermfg=223 cterm=bold
hi Delimiter guifg=#8f8f8f ctermfg=245
hi DiffAdd guifg=#709080 guibg=#313c36 gui=bold ctermfg=66 ctermbg=237 cterm=bold
hi DiffChange guibg=#333333 ctermbg=236
hi DiffDelete guifg=#333333 guibg=#464646 ctermfg=236 ctermbg=238
hi DiffText guifg=#ecbcbc guibg=#41363c gui=bold ctermfg=217 ctermbg=237 cterm=bold
hi Directory guifg=#9fafaf gui=bold ctermfg=109 cterm=bold
hi ErrorMsg guifg=#80d4aa guibg=#2f2f2f gui=bold ctermfg=115 ctermbg=236 cterm=bold
hi Exception guifg=#c3bf9f gui=bold ctermfg=249 cterm=bold
hi Float guifg=#c0bed1 ctermfg=251
hi FoldColumn guifg=#93b3a3 guibg=#3f4040
hi Folded guifg=#93b3a3 guibg=#3f4040
hi Function guifg=#efef8f ctermfg=228
hi Identifier guifg=#efdcbc ctermfg=223 cterm=none
hi IncSearch guifg=#f8f893 guibg=#385f38 ctermfg=228 ctermbg=23
hi Keyword guifg=#f0dfaf gui=bold ctermfg=223 cterm=bold
hi Macro guifg=#ffcfaf gui=bold ctermfg=223 cterm=bold
hi ModeMsg guifg=#ffcfaf gui=none ctermfg=223 cterm=none
hi MoreMsg guifg=#ffffff gui=bold ctermfg=231 cterm=bold
hi Number guifg=#8cd0d3 ctermfg=116
hi Operator guifg=#f0efd0 ctermfg=230
hi PmenuSbar guibg=#2e3330 guifg=#000000 ctermfg=16 ctermbg=236
hi PmenuThumb guibg=#a0afa0 guifg=#040404 ctermfg=232 ctermbg=151
hi PreCondit guifg=#dfaf8f gui=bold ctermfg=180 cterm=bold
hi PreProc guifg=#ffcfaf gui=bold ctermfg=223 cterm=bold
hi Question guifg=#ffffff gui=bold ctermfg=231 cterm=bold
hi Repeat guifg=#ffd7a7 gui=bold ctermfg=223 cterm=bold
hi Search guifg=#ffffe0 guibg=#284f28 ctermfg=230 ctermbg=22
hi SignColumn guifg=#9fafaf gui=bold ctermfg=109 cterm=bold
hi SpecialChar guifg=#dca3a3 gui=bold ctermfg=181 cterm=bold
hi SpecialComment guifg=#82a282 gui=bold ctermfg=108 cterm=bold
hi Special guifg=#cfbfaf ctermfg=181
hi SpecialKey guifg=#9ece9e ctermfg=151
hi Statement guifg=#e3ceab gui=none ctermfg=187 cterm=none
hi StatusLine guifg=#313633 guibg=#ccdc90 ctermfg=236 ctermbg=186
hi StatusLineNC guifg=#2e3330 guibg=#88b090 ctermfg=235 ctermbg=108
hi StorageClass guifg=#c3bf9f gui=bold ctermfg=249 cterm=bold
hi String guifg=#cc9393 ctermfg=174
hi Structure guifg=#efefaf gui=bold ctermfg=229 cterm=bold
hi Tag guifg=#e89393 gui=bold ctermfg=181 cterm=bold
hi Title guifg=#efefef gui=bold ctermfg=255 ctermbg=NONE cterm=bold
hi Todo guifg=#dfdfdf guibg=NONE gui=bold ctermfg=254 ctermbg=NONE cterm=bold
hi Typedef guifg=#dfe4cf gui=bold ctermfg=253 cterm=bold
hi Type guifg=#dfdfbf gui=bold ctermfg=187 cterm=bold
hi Underlined guifg=#dcdccc gui=underline ctermfg=188 cterm=underline
hi VertSplit guifg=#2e3330 guibg=#688060 ctermfg=236 ctermbg=65
hi VisualNOS guifg=#333333 guibg=#f18c96 gui=bold,underline ctermfg=236 ctermbg=210 cterm=bold
hi WarningMsg guifg=#ffffff guibg=#333333 gui=bold ctermfg=231 ctermbg=236 cterm=bold
hi WildMenu guifg=#cbecd0 guibg=#2c302d gui=underline ctermfg=194 ctermbg=236 cterm=underline
" spellchecking, always "bright" term background
hi SpellBad guisp=#bc6c4c guifg=#dc8c6c ctermfg=209 ctermbg=237
hi SpellCap guisp=#6c6c9c guifg=#8c8cbc ctermfg=103 ctermbg=237
hi SpellRare guisp=#bc6c9c guifg=#bc8cbc ctermfg=139 ctermbg=237
hi SpellLocal guisp=#7cac7c guifg=#9ccc9c ctermfg=151 ctermbg=237
if exists("g:zenburn_high_Contrast") && g:zenburn_high_Contrast
" use new darker background
hi Normal guifg=#dcdccc guibg=#1f1f1f ctermfg=188 ctermbg=234
hi ColorColumn guibg=#33332f ctermbg=235
hi CursorLine guibg=#121212 gui=bold ctermbg=233 cterm=none
hi CursorLineNr guifg=#f2f3bb guibg=#161616 ctermfg=229 ctermbg=233
if exists("g:zenburn_unified_CursorColumn") && g:zenburn_unified_CursorColumn
hi CursorColumn guibg=#121212 gui=bold ctermbg=233 cterm=none
else
hi CursorColumn guibg=#2b2b2b ctermbg=235 cterm=none
endif
hi FoldColumn guibg=#161616 ctermbg=233 ctermfg=109
hi Folded guibg=#161616 ctermbg=233 ctermfg=109
hi LineNr guifg=#9fafaf guibg=#161616 ctermfg=248 ctermbg=233
hi NonText guifg=#404040 gui=bold ctermfg=238
hi Pmenu guibg=#242424 guifg=#ccccbc ctermfg=251 ctermbg=235
hi PmenuSel guibg=#353a37 guifg=#ccdc90 gui=bold ctermfg=187 ctermbg=236 cterm=bold
hi MatchParen guifg=#f0f0c0 guibg=#383838 gui=bold ctermfg=229 ctermbg=237 cterm=bold
hi SignColumn guibg=#181818 ctermbg=233
hi SpecialKey guibg=#242424
hi TabLine guifg=#88b090 guibg=#313633 gui=none ctermbg=236 ctermfg=108 cterm=none
hi TabLineSel guifg=#ccd990 guibg=#222222 ctermbg=235 ctermfg=186 cterm=bold
hi TabLineFill guifg=#88b090 guibg=#313633 gui=none ctermbg=236 ctermfg=108 cterm=none
else
" Original, lighter background
hi Normal guifg=#dcdccc guibg=#3f3f3f ctermfg=188 ctermbg=237
hi ColorColumn guibg=#484848 ctermbg=238
hi CursorLine guibg=#434443 ctermbg=238 cterm=none
hi CursorLineNr guifg=#d2d39b guibg=#262626 ctermfg=230 ctermbg=235
if exists("g:zenburn_unified_CursorColumn") && g:zenburn_unified_CursorColumn
hi CursorColumn guibg=#434343 ctermbg=238 cterm=none
else
hi CursorColumn guibg=#4f4f4f ctermbg=239 cterm=none
endif
hi FoldColumn guibg=#333333 ctermbg=236 ctermfg=109
hi Folded guibg=#333333 ctermbg=236 ctermfg=109
hi LineNr guifg=#9fafaf guibg=#262626 ctermfg=248 ctermbg=235
hi NonText guifg=#5b605e gui=bold ctermfg=240
hi Pmenu guibg=#2c2e2e guifg=#9f9f9f ctermfg=248 ctermbg=235
hi PmenuSel guibg=#242424 guifg=#d0d0a0 gui=bold ctermfg=187 ctermbg=235 cterm=bold
hi MatchParen guifg=#b2b2a0 guibg=#2e2e2e gui=bold ctermfg=145 ctermbg=236 cterm=bold
hi SignColumn guibg=#343434 ctermbg=236
hi SpecialKey guibg=#444444
hi TabLine guifg=#d0d0b8 guibg=#222222 gui=none ctermbg=235 ctermfg=187 cterm=none
hi TabLineSel guifg=#f0f0b0 guibg=#333333 gui=bold ctermbg=236 ctermfg=229 cterm=bold
hi TabLineFill guifg=#dccdcc guibg=#101010 gui=none ctermbg=233 ctermfg=188 cterm=none
hi StatusLine ctermbg=144
endif
if exists("g:zenburn_force_dark_Background") && g:zenburn_force_dark_Background
" Force dark background, because of a bug in VIM: VIM sets background
" automatically during "hi Normal ctermfg=X"; it misinterprets the high
" value (234 or 237 above) as a light color, and wrongly sets background to
" light. See ":help highlight" for details.
set background=dark
endif
if exists("g:zenburn_transparent") && g:zenburn_transparent
hi Normal ctermbg=0 guibg=#000000
hi Statement ctermbg=NONE
hi Title ctermbg=NONE
hi Todo ctermbg=NONE
hi Underlined ctermbg=NONE
hi DiffAdd ctermbg=NONE
hi DiffText ctermbg=NONE
hi ErrorMsg ctermbg=NONE
hi LineNr ctermbg=NONE
endif
if exists("g:zenburn_old_Visual") && g:zenburn_old_Visual
if exists("g:zenburn_alternate_Visual") && g:zenburn_alternate_Visual
" Visual with more contrast, thanks to Steve Hall & Cream posse
" gui=none fixes weird highlight problem in at least GVim 7.0.66, thanks to Kurt Maier
hi Visual guifg=#000000 guibg=#71d3b4 gui=none ctermfg=16 ctermbg=79 cterm=none
hi VisualNOS guifg=#000000 guibg=#71d3b4 gui=none ctermfg=16 ctermbg=79 cterm=none
else
" use default visual
hi Visual guifg=#233323 guibg=#71d3b4 gui=none ctermfg=235 ctermbg=79 cterm=none
hi VisualNOS guifg=#233323 guibg=#71d3b4 gui=none ctermfg=235 ctermbg=79 cterm=none
endif
else
" new Visual style
if exists("g:zenburn_high_Contrast") && g:zenburn_high_Contrast
" high contrast
"hi Visual guibg=#304a3d
"hi VisualNos guibg=#304a3d
"TODO no nice greenish in console, 65 is closest. use full black instead,
"although i like the green..!
hi Visual guibg=#0f0f0f ctermbg=232
hi VisualNOS guibg=#0f0f0f ctermbg=232
if exists("g:zenburn_transparent") && g:zenburn_transparent
hi Visual ctermbg=235
endif
else
" low contrast
hi Visual guibg=#2f2f2f ctermbg=235
hi VisualNOS guibg=#2f2f2f ctermbg=235
endif
endif
if exists("g:zenburn_alternate_Error") && g:zenburn_alternate_Error
" use more jumpy Error
hi Error guifg=#e37170 guibg=#664040 gui=bold ctermfg=210 ctermbg=52 cterm=bold
else
" default is something more zenburn-compatible
hi Error guifg=#e37170 guibg=#3d3535 gui=bold ctermfg=167 ctermbg=236 cterm=bold
endif
if exists("g:zenburn_alternate_Include") && g:zenburn_alternate_Include
" original setting
hi Include guifg=#ffcfaf gui=bold ctermfg=223 cterm=bold
else
" new, less contrasted one
hi Include guifg=#dfaf8f gui=bold ctermfg=180 cterm=bold
endif
if exists("g:zenburn_disable_Label_underline") && g:zenburn_disable_Label_underline
hi Label guifg=#dfcfaf ctermfg=187
else
hi Label guifg=#dfcfaf gui=underline ctermfg=187 cterm=underline
endif
if exists("g:zenburn_color_also_Ignore") && g:zenburn_color_also_Ignore
" color the Ignore groups
" note: if you get strange coloring for your files, turn this off (unlet)
if exists("g:zenburn_high_Contrast") && g:zenburn_high_Contrast
hi Ignore ctermfg=238
else
hi Ignore guifg=#545a4f ctermfg=240
endif
endif
" EXPERIMENTAL TagHighlight support
" link/set sensible defaults here;
"
" For now I mostly link to subset of Zenburn colors, the linkage is based
" on appearance, not semantics. In later versions I might define more new colours.
"
" HELP NEEDED to make this work properly.
if exists("g:zenburn_enable_TagHighlight") && g:zenburn_enable_TagHighlight
" CTag support may vary, but the first step is to start using it so
" we can fix it!
"
" Consult /plugin/TagHighlight/data/kinds.txt for info on your
" language and what's been defined.
"
" There is potential for language indepedent features here. (Acutally,
" seems it may be required for this to be useful...) This way we can
" implement features depending on how well CTags are currently implemented
" for the language. ie. Global problem for python is annoying. Special
" colors are defined for special language features, etc..
"
" For now all I care about is python supported features:
" c:CTagsClass
" f:CTagsFunction
" i:CTagsImport
" m:CTagsMember
" v:CTagsGlobalVariable
"
" Note: TagHighlight defaults to setting new tags to Keyword
" highlighting.
" TODO conditionally run each section
" BEGIN Python Section
hi link Class Function
hi link Import PythonInclude
hi link Member Function
"Note: Function is already defined
" Highlighter seems to think a lot of things are global variables even
" though they're not. Example: python method-local variable is
" coloured as a global variable. They should not be global, since
" they're not visible outside the method.
" If this is some very bright colour group then things look bad.
" hi link GlobalVariable Identifier
" Because of this problem I am disabling the feature by setting it to
" Normal instead
hi link GlobalVariable Normal
" END Python Section
" Starting point for other languages.
hi link GlobalConstant Constant
hi link EnumerationValue Float
hi link EnumerationName Identifier
hi link DefinedName WarningMsg
hi link LocalVariable WarningMsg
hi link Structure WarningMsg
hi link Union WarningMsg
endif
" TODO check for more obscure syntax groups that they're ok

405
vim/vimrc Normal file
View File

@ -0,0 +1,405 @@
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Maintainer:
" Amir Salihefendic
" http://amix.dk - amix@amix.dk
"
" Version:
" 5.0 - 29/05/12 15:43:36
"
" Blog_post:
" http://amix.dk/blog/post/19691#The-ultimate-Vim-configuration-on-Github
"
" Awesome_version:
" Get this config, nice color schemes and lots of plugins!
"
" Install the awesome version from:
"
" https://github.com/amix/vimrc
"
" Syntax_highlighted:
" http://amix.dk/vim/vimrc.html
"
" Raw_version:
" http://amix.dk/vim/vimrc.txt
"
" Sections:
" -> General
" -> VIM user interface
" -> Colors and Fonts
" -> Files and backups
" -> Text, tab and indent related
" -> Visual mode related
" -> Moving around, tabs and buffers
" -> Status line
" -> Editing mappings
" -> vimgrep searching and cope displaying
" -> Spell checking
" -> Misc
" -> Helper functions
"
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => General
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Sets how many lines of history VIM has to remember
set history=700
" Enable filetype plugins
filetype plugin on
filetype indent on
" Set to auto read when a file is changed from the outside
set autoread
" With a map leader it's possible to do extra key combinations
" like <leader>w saves the current file
let mapleader = ","
let g:mapleader = ","
" Fast saving
nmap <leader>w :w!<cr>
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => VIM user interface
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Set 7 lines to the cursor - when moving vertically using j/k
set so=7
" Turn on the WiLd menu
set wildmenu
" Ignore compiled files
set wildignore=*.o,*~,*.pyc
"Always show current position
set ruler
" Height of the command bar
set cmdheight=2
" A buffer becomes hidden when it is abandoned
set hid
" Configure backspace so it acts as it should act
set backspace=eol,start,indent
set whichwrap+=<,>,h,l
" Ignore case when searching
set ignorecase
" When searching try to be smart about cases
set smartcase
" Highlight search results
set hlsearch
" Makes search act like search in modern browsers
set incsearch
" Don't redraw while executing macros (good performance config)
set lazyredraw
" For regular expressions turn magic on
set magic
" Show matching brackets when text indicator is over them
set showmatch
" How many tenths of a second to blink when matching brackets
set mat=2
" No annoying sound on errors
set noerrorbells
set novisualbell
set t_vb=
set tm=500
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Colors and Fonts
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Enable syntax highlighting
syntax enable
set t_Co=256
"set background=dark
" Set extra options when running in GUI mode
if has("gui_running")
set guioptions-=T
set guioptions+=e
set t_Co=256
set guitablabel=%M\ %t
endif
" Set utf8 as standard encoding and en_US as the standard language
set encoding=utf8
" Use Unix as the standard file type
set ffs=unix,dos,mac
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Files, backups and undo
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Turn backup off, since most stuff is in SVN, git et.c anyway...
set nobackup
set nowb
set noswapfile
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Text, tab and indent related
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Use spaces instead of tabs
set expandtab
" Be smart when using tabs ;)
set smarttab
" 1 tab == 4 spaces
set shiftwidth=4
set tabstop=4
" Linebreak on 500 characters
set lbr
set tw=500
set ai "Auto indent
set si "Smart indent
set wrap "Wrap lines
""""""""""""""""""""""""""""""
" => Visual mode related
""""""""""""""""""""""""""""""
" Visual mode pressing * or # searches for the current selection
" Super useful! From an idea by Michael Naumann
vnoremap <silent> * :call VisualSelection('f')<CR>
vnoremap <silent> # :call VisualSelection('b')<CR>
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Moving around, tabs, windows and buffers
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Treat long lines as break lines (useful when moving around in them)
map j gj
map k gk
" Map <Space> to / (search) and Ctrl-<Space> to ? (backwards search)
map <space> /
map <c-space> ?
" Disable highlight when <leader><cr> is pressed
map <silent> <leader><cr> :noh<cr>
" Smart way to move between windows
map <C-j> <C-W>j
map <C-k> <C-W>k
map <C-h> <C-W>h
map <C-l> <C-W>l
" Close the current buffer
map <leader>bd :Bclose<cr>
" Close all the buffers
map <leader>ba :1,1000 bd!<cr>
" Useful mappings for managing tabs
map <leader>tn :tabnew<cr>
map <leader>to :tabonly<cr>
map <leader>tc :tabclose<cr>
map <leader>tm :tabmove
" Opens a new tab with the current buffer's path
" Super useful when editing files in the same directory
map <leader>te :tabedit <c-r>=expand("%:p:h")<cr>/
" Switch CWD to the directory of the open buffer
map <leader>cd :cd %:p:h<cr>:pwd<cr>
" Specify the behavior when switching between buffers
try
set switchbuf=useopen,usetab,newtab
set stal=2
catch
endtry
" Return to last edit position when opening files (You want this!)
autocmd BufReadPost *
\ if line("'\"") > 0 && line("'\"") <= line("$") |
\ exe "normal! g`\"" |
\ endif
" Remember info about open buffers on close
set viminfo^=%
""""""""""""""""""""""""""""""
" => Status line
""""""""""""""""""""""""""""""
" Always show the status line
set laststatus=2
" Format the status line
set statusline=\ %{HasPaste()}%F%m%r%h\ %w\ \ CWD:\ %r%{getcwd()}%h\ \ \ Line:\ %l
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Editing mappings
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Remap VIM 0 to first non-blank character
map 0 ^
" Move a line of text using ALT+[jk] or Comamnd+[jk] on mac
nmap <M-j> mz:m+<cr>`z
nmap <M-k> mz:m-2<cr>`z
vmap <M-j> :m'>+<cr>`<my`>mzgv`yo`z
vmap <M-k> :m'<-2<cr>`>my`<mzgv`yo`z
if has("mac") || has("macunix")
nmap <D-j> <M-j>
nmap <D-k> <M-k>
vmap <D-j> <M-j>
vmap <D-k> <M-k>
endif
" Delete trailing white space on save, useful for Python and CoffeeScript ;)
func! DeleteTrailingWS()
exe "normal mz"
%s/\s\+$//ge
exe "normal `z"
endfunc
autocmd BufWrite *.py :call DeleteTrailingWS()
autocmd BufWrite *.coffee :call DeleteTrailingWS()
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => vimgrep searching and cope displaying
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" When you press gv you vimgrep after the selected text
vnoremap <silent> gv :call VisualSelection('gv')<CR>
" Open vimgrep and put the cursor in the right position
map <leader>g :vimgrep // **/*.<left><left><left><left><left><left><left>
" Vimgreps in the current file
map <leader><space> :vimgrep // <C-R>%<C-A><right><right><right><right><right><right><right><right><right>
" When you press <leader>r you can search and replace the selected text
vnoremap <silent> <leader>r :call VisualSelection('replace')<CR>
" Do :help cope if you are unsure what cope is. It's super useful!
"
" When you search with vimgrep, display your results in cope by doing:
" <leader>cc
"
" To go to the next search result do:
" <leader>n
"
" To go to the previous search results do:
" <leader>p
"
map <leader>cc :botright cope<cr>
map <leader>co ggVGy:tabnew<cr>:set syntax=qf<cr>pgg
map <leader>n :cn<cr>
map <leader>p :cp<cr>
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Spell checking
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Pressing ,ss will toggle and untoggle spell checking
map <leader>ss :setlocal spell!<cr>
" Shortcuts using <leader>
map <leader>sn ]s
map <leader>sp [s
map <leader>sa zg
map <leader>s? z=
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Misc
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" Remove the Windows ^M - when the encodings gets messed up
noremap <Leader>m mmHmt:%s/<C-V><cr>//ge<cr>'tzt'm
" Quickly open a buffer for scripbble
map <leader>q :e ~/buffer<cr>
" Toggle paste mode on and off
map <leader>pp :setlocal paste!<cr>
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" => Helper functions
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
function! CmdLine(str)
exe "menu Foo.Bar :" . a:str
emenu Foo.Bar
unmenu Foo
endfunction
function! VisualSelection(direction) range
let l:saved_reg = @"
execute "normal! vgvy"
let l:pattern = escape(@", '\\/.*$^~[]')
let l:pattern = substitute(l:pattern, "\n$", "", "")
if a:direction == 'b'
execute "normal ?" . l:pattern . "^M"
elseif a:direction == 'gv'
call CmdLine("vimgrep " . '/'. l:pattern . '/' . ' **/*.')
elseif a:direction == 'replace'
call CmdLine("%s" . '/'. l:pattern . '/')
elseif a:direction == 'f'
execute "normal /" . l:pattern . "^M"
endif
let @/ = l:pattern
let @" = l:saved_reg
endfunction
" Returns true if paste mode is enabled
function! HasPaste()
if &paste
return 'PASTE MODE '
en
return ''
endfunction
" Don't close window, when deleting a buffer
command! Bclose call <SID>BufcloseCloseIt()
function! <SID>BufcloseCloseIt()
let l:currentBufNum = bufnr("%")
let l:alternateBufNum = bufnr("#")
if buflisted(l:alternateBufNum)
buffer #
else
bnext
endif
if bufnr("%") == l:currentBufNum
new
endif
if buflisted(l:currentBufNum)
execute("bdelete! ".l:currentBufNum)
endif
endfunction
" colorscheme zenburn
" colorscheme eldar
if v:version < 802
packadd! dracula
endif
syntax enable
colorscheme dracula

44
xinitrc Executable file
View File

@ -0,0 +1,44 @@
#!/bin/sh
userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap
# merge in defaults and keymaps
if [ -f $sysresources ]; then
xrdb -merge $sysresources
fi
if [ -f $sysmodmap ]; then
xmodmap $sysmodmap
fi
if [ -f "$userresources" ]; then
xrdb -merge "$userresources"
fi
if [ -f "$usermodmap" ]; then
xmodmap "$usermodmap"
fi
# start some nice programs
if [ -d /etc/X11/xinit/xinitrc.d ] ; then
for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
[ -x "$f" ] && . "$f"
done
unset f
fi
#twm &
#xclock -geometry 50x50-1+1 &
#xterm -geometry 80x50+494+51 &
#xterm -geometry 80x20+494-0 &
#exec xterm -geometry 80x66+0+0 -name login
xrandr --output HDMI-0 --mode 1920x1080 --pos 0x0 --rotate normal --output DP-0 --primary --mode 1920x1080 --pos 1920x0 --rotate normal --output DP-1 --off --output HDMI-1 --off --output DP-2 --mode 1920x1080 --pos 3840x0 --rotate normal --output DP-3 --off --output None-1-1 --off
#exec awesome
export XDG_XSESSION_TYPE=x11
export XDG_BACKEND=x11
exec awesome > ~/.xsession.log 2>&1

170
zsh/zshrc Normal file
View File

@ -0,0 +1,170 @@
# Path to your oh-my-zsh installation.
export ZSH=$HOME/.oh-my-zsh
# Set name of the theme to load.
# Look in ~/.oh-my-zsh/themes/
# Optionally, if you set this to "random", it'll load a random theme each
# time that oh-my-zsh is loaded.
#ZSH_THEME="moe"
#ZSH_THEME="fishy"
ZSH_THEME="dracula"
# Uncomment the following line to use case-sensitive completion.
# CASE_SENSITIVE="true"
# Uncomment the following line to use hyphen-insensitive completion. Case
# sensitive completion must be off. _ and - will be interchangeable.
# HYPHEN_INSENSITIVE="true"
# Uncomment the following line to disable bi-weekly auto-update checks.
# DISABLE_AUTO_UPDATE="true"
# Uncomment the following line to change how often to auto-update (in days).
# export UPDATE_ZSH_DAYS=13
# Uncomment the following line to disable colors in ls.
# DISABLE_LS_COLORS="true"
# Uncomment the following line to disable auto-setting terminal title.
# DISABLE_AUTO_TITLE="true"
# Uncomment the following line to enable command auto-correction.
# ENABLE_CORRECTION="true"
# Uncomment the following line to display red dots whilst waiting for completion.
# COMPLETION_WAITING_DOTS="true"
# Uncomment the following line if you want to disable marking untracked files
# under VCS as dirty. This makes repository status check for large repositories
# much, much faster.
# DISABLE_UNTRACKED_FILES_DIRTY="true"
# Uncomment the following line if you want to change the command execution time
# stamp shown in the history command output.
# The optional three formats: "mm/dd/yyyy"|"dd.mm.yyyy"|"yyyy-mm-dd"
# HIST_STAMPS="mm/dd/yyyy"
# Would you like to use another custom folder than $ZSH/custom?
# ZSH_CUSTOM=/path/to/new-custom-folder
# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*)
# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/
# Example format: plugins=(rails git textmate ruby lighthouse)
# Add wisely, as too many plugins slow down shell startup.
plugins=(git svn)
# User configuration
export PATH="/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/lib/jvm/default/bin:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl:/bin/:${PATH}"
# export MANPATH="/usr/local/man:$MANPATH"
source $ZSH/oh-my-zsh.sh
# You may need to manually set your language environment
# export LANG=en_US.UTF-8
# Preferred editor for local and remote sessions
if [[ -n $SSH_CONNECTION ]]; then
export EDITOR='vim'
else
export EDITOR='vim'
fi
# Compilation flags
# export ARCHFLAGS="-arch x86_64"
# ssh
# export SSH_KEY_PATH="~/.ssh/dsa_id"
# Set personal aliases, overriding those provided by oh-my-zsh libs,
# plugins, and themes. Aliases can be placed here, though oh-my-zsh
# users are encouraged to define aliases within the ZSH_CUSTOM folder.
# For a full list of active aliases, run `alias`.
#
# Example aliases
# alias zshconfig="mate ~/.zshrc"
# alias ohmyzsh="mate ~/.oh-my-zsh"
#source ~/.zshrc_aliases
#if [ -e /usr/share/terminfo/x/xterm-256color ] && [ "$COLORTERM" = "xfce4-terminal" ]; then
# export TERM=xterm-256color
#fi
#if [[ -n "$DISPLAY" && "$TERM" = "xterm" ]]; then
# export TERM=xterm-256color
#fis
if [ -f /usr/bin/lsb_release ]; then
DISTRO=$(lsb_release -si)
fi
if [[ $DISTRO = 'Debian' ]]; then
alias archey='screenfetch'
fi
# Fun / Games
#alias aquarium='asciiquarium'
#alias sudoku='nsudoku'
#alias tetris='bastet'
#alias mario='mupen64plus --windowed ~/ROMs/N64/SuperMario64.v64'
#alias kart='mupen64plus --windowed ~/ROMs/N64/MarioKart64.v64'
#alias zelda='mupen64plus --windowed ~/ROMs/N64/Zelda64.rom'
#alias zeldamajora='mupen64plus --windowed ~/ROMs/N64/ZeldaMajorasMask.z'
#alias ps2='pcsx2'
#System
alias shutdown='sudo shutdown -P now'
alias update='sudo apt-get update'
alias upgrade='sudo apt-get upgrade'
alias dist-upgrade='sudo apt-get dist-upgrade'
alias autoremove='sudo apt-get autoremove'
alias ainstall='sudo apt-get install'
alias search='sudo apt-cache search'
# Default to human readable figures
alias df='df -h'
alias du='du -h'
# Interactive operation...
# alias rm='rm -i'
# alias cp='cp -i'
# alias mv='mv -i'
# Misc :)
alias less='less -r' # raw control characters
alias grep='grep --color' # show differences in colour
alias egrep='egrep --color=auto' # show differences in colour
alias fgrep='fgrep --color=auto' # show differences in colour
# Some shortcuts for different directory listings
alias ls='ls -hF --color=auto' # classify files in colour
alias dir='ls --color=auto --format=vertical'
alias vdir='ls --color=auto --format=long'
alias ll='ls -l' # long list
alias la='ls -A' # all but . and ..
alias l='ls -CF'
alias k='exit'
alias D='cd ~/Downloads'
## Vim Stuff
alias eV='vim ~/.vim/vimrc'
alias e='vim'
#ZSH Stuff
alias eZ='vim ~/.zshrc'
alias eZA='atom ~/.zshrc'
alias eA='vim ~/.zshrc_aliases'
alias eAA='atom ~/.zshrc_aliases'
alias Z='source ~/.zshrc'
## News and Music
alias news='newsbeuter'
alias nix='cortex linux'
alias twit='turses'
## Net
alias irc='weechat-curses'
alias ST='speedtest-cli'
#alias ssh='TERM=xterm-256color; ssh'
alias mutt='TERM=xterm-256color; neomutt'
#alias UM='imapfilter; offlineimap'
alias home='ssh -p 2222 moe@home.comprofix.com'