Update terminal colors, additions to the vimrc

This commit is contained in:
natemaia 2018-11-04 22:19:12 -08:00
parent 749193ba48
commit a0b18cc1c8
12 changed files with 235 additions and 44 deletions

View File

@ -1,7 +1,7 @@
! Base colors ! Base colors
*.foreground: #E1E1E1 *.foreground: #E1E1E1
*.background: #1c2023 *.background: #1c2023
*.cursorColor: #707880 *.cursorColor: #778899
*.color0: #1c2023 *.color0: #1c2023
*.color1: #bf616a *.color1: #bf616a
@ -11,7 +11,7 @@
*.color5: #b48ead *.color5: #b48ead
*.color6: #96b5b4 *.color6: #96b5b4
*.color7: #E1E1E1 *.color7: #E1E1E1
*.color8: #1c2023 *.color8: #919ba0
*.color9: #bf616a *.color9: #bf616a
*.color10: #a3be8c *.color10: #a3be8c
*.color11: #ebcb8b *.color11: #ebcb8b

View File

@ -32,8 +32,8 @@ default_gauge_height = 25,
default_gauge_width =40, default_gauge_width =40,
default_graph_height = 40, default_graph_height = 40,
default_graph_width = 153, default_graph_width = 153,
default_shade_color = '#000000', default_shade_color = '#1c2023',
default_outline_color = '#000000', default_outline_color = '#1c2023',
draw_borders = false, draw_borders = false,
draw_graph_borders = true, draw_graph_borders = true,
draw_shades = false, draw_shades = false,
@ -59,7 +59,7 @@ own_window = true,
own_window_argb_value = 250, own_window_argb_value = 250,
own_window_argb_visual = true, own_window_argb_visual = true,
own_window_class = 'Conky', own_window_class = 'Conky',
own_window_colour = '#000000', own_window_colour = '#1c2023',
own_window_hints = 'undecorated,below,above,sticky,skip_taskbar,skip_pager', own_window_hints = 'undecorated,below,above,sticky,skip_taskbar,skip_pager',
own_window_transparent = true, own_window_transparent = true,
own_window_title = 'system_conky', own_window_title = 'system_conky',
@ -97,8 +97,8 @@ ${hr}
[S] + t${alignr}Terminal [S] + t${alignr}Terminal
[S] + e${alignr}Text Editor [S] + e${alignr}Text Editor
[S] + f${alignr}File Manager [S] + f${alignr}File Manager
[S] + m${alignr}Music Player
[S] + w${alignr}Web Browser [S] + w${alignr}Web Browser
[S] + m${alignr}Music Player
[S] + v${alignr}Audio Control [S] + v${alignr}Audio Control
[S] + x${alignr}Logout [S] + x${alignr}Logout
]]; ]];

View File

@ -1,5 +1,5 @@
[dmenu] [dmenu]
dmenu_command = rofi -location 3 -yoffset 35 -xoffset -10 -width 37 -font "DejaVu Sans Mono 11" -padding 20 -line-padding 4 -hide-scrollbar -password dmenu_command = rofi -location 3 -yoffset 35 -xoffset -10 -width 37 -font "DejaVu Sans Mono 11" -padding 20 -line-padding 4 -password
[editor] [editor]
terminal = termite terminal = termite

View File

@ -0,0 +1,149 @@
"""
A ranger color scheme
Made to be eye catchy while maintaining visibility, and base 0-7 colours.
Inspired by themes like Tomorrow, Dracula, Atom, and Spacemacs, but with my own twists
"""
from ranger.gui.colorscheme import ColorScheme
from ranger.gui.color import *
class jinx(ColorScheme):
"""
Defines colours used when colourscheme is enabled
"""
progress_bar_color = 96
def use(self, context):
"""
Main colour block with individual definitions
"""
fg, bg, attr = default_colors
if context.reset:
return default_colors
elif context.in_browser:
if context.selected:
attr = reverse
else:
attr = normal
if context.empty or context.error:
fg = 131
if context.border:
fg = 247
if context.image:
fg = 179
if context.video:
fg = 96
if context.audio:
fg = 117
if context.document:
fg = 38
if context.container:
fg = 108
if context.directory:
fg = 103
elif context.executable and not \
any((context.media, context.fifo, context.container, context.socket)):
fg = 67
if context.socket:
fg = 179
attr |= bold
if context.fifo or context.device:
fg = 214
attr |= bold
if context.link:
fg = 38 if context.good else 131
if context.tag_marker and not context.selected:
fg = 96
attr |= bold
if not context.selected and (context.cut or context.copied):
fg = 247
attr |= underline
if context.main_column:
if context.marked:
attr |= underline
fg = 131
if context.selected:
attr |= normal
if context.badinfo:
if attr & reverse:
bg = 96
else:
fg = 203
elif context.in_titlebar:
attr |= bold
if context.hostname:
fg = 203 if context.bad else 67
elif context.directory:
fg = 96
elif context.tab:
if context.good:
bg = 96
elif context.link:
fg = 117
elif context.in_statusbar:
if context.permissions:
if context.good:
fg = 67
elif context.bad:
fg = 203
if context.marked:
attr |= bold | reverse
fg = 96
if context.message:
if context.bad:
attr |= bold
fg = 96
if context.loaded:
bg = self.progress_bar_color
if context.vcsinfo:
fg = 38
attr &= ~bold
if context.vcscommit:
fg = 108
attr &= ~bold
if context.text:
fg = 254
if context.highlight:
attr |= reverse
if context.in_taskview:
if context.title:
fg = 67
if context.selected:
attr |= reverse
if context.loaded:
if context.selected:
fg = self.progress_bar_color
else:
bg = self.progress_bar_color
if context.vcsfile and not context.selected:
attr &= ~bold
if context.vcsconflict:
fg = 203
elif context.vcschanged:
fg = 174
elif context.vcsunknown:
fg = 174
elif context.vcsstaged:
fg = 108
elif context.vcssync:
fg = 108
elif context.vcsignored:
fg = default
elif context.vcsremote and not context.selected:
attr &= ~bold
if context.vcssync:
fg = 108
elif context.vcsbehind:
fg = 174
elif context.vcsahead:
fg = 67
elif context.vcsdiverged:
fg = 203
elif context.vcsunknown:
fg = 174
return fg, bg, attr

View File

@ -32,7 +32,7 @@ color4 = #8fa1b3
color5 = #b48ead color5 = #b48ead
color6 = #96b5b4 color6 = #96b5b4
color7 = #E1E1E1 color7 = #E1E1E1
color8 = #1c2023 color8 = #919ba0
color9 = #bf616a color9 = #bf616a
color10 = #a3be8c color10 = #a3be8c
color11 = #ebcb8b color11 = #ebcb8b

View File

@ -20,14 +20,11 @@
<a href="https://archlabsblog.wordpress.com">Official Website</a> <a href="https://archlabsblog.wordpress.com">Official Website</a>
</span> </span>
<span class="item"> <span class="item">
<a href="https://plus.google.com/u/0/communities/111177505820810068511">ArchLabs G+</a> <a href="https://forum.archlabslinux.com/">ArchLabs Forum</a>
</span> </span>
<span class="item"> <span class="item">
<a href="https://www.reddit.com/r/ArchLabsLinux/">ArchLabs Reddit</a> <a href="https://www.reddit.com/r/ArchLabsLinux/">ArchLabs Reddit</a>
</span> </span>
<span class="item">
<a href="https://forum.archlabslinux.com/">ArchLabs Forum</a>
</span>
<span class="item"> <span class="item">
<a href="https://twitter.com/ArchLabsLinux">ArchLabs Twitter</a> <a href="https://twitter.com/ArchLabsLinux">ArchLabs Twitter</a>
</span> </span>
@ -70,14 +67,14 @@
<div class="stripe" style="background-color:#BA386F"> <div class="stripe" style="background-color:#BA386F">
<div class="title"> <div class="title">
<span>GetArchLabs</span> <span>ArchLabs</span>
</div> </div>
<div class="content"> <div class="content">
<span class="item"> <span class="item">
<a href="https://sourceforge.net/projects/archlabs-linux-minimo/">Official Download</a> <a href="https://bitbucket.org/archlabslinux/iso/issues/new">Got an Issue?</a>
</span> </span>
<span class="item"> <span class="item">
<a href="https://forum.archlabslinux.com/c/bug-reports">Got a suggestion?</a> <a href="https://forum.archlabslinux.com/">Got a Suggestion?</a>
</span> </span>
</div> </div>
</div> </div>

View File

@ -127,6 +127,7 @@ input[type=text]:focus {
top: 50%; top: 50%;
transform: translateY(-50%); transform: translateY(-50%);
} }
.stripe .content span { .stripe .content span {
line-height: calc(25vh - 50px); line-height: calc(25vh - 50px);
display: none; display: none;

View File

@ -22,8 +22,7 @@ let g:netrw_browse_split = 3
" ------ leader mapping ------ " ------ leader mapping ------
let g:mapleader = ',' let g:mapleader = "\<Space>"
map <Space> ,
" ------ enable additional features ------ " ------ enable additional features ------
@ -173,6 +172,63 @@ endif
" ------ adv maps ------ " ------ adv maps ------
" visual quote surround
vnoremap ;' <Esc>:call QuickWrap("'")<CR>
vnoremap ;" <Esc>:call QuickWrap('"')<CR>
" quote 'surround'
nnoremap ;' ciW''<Esc>P
nnoremap ;'' ciw''<Esc>P
nnoremap ;" ciW""<Esc>P
nnoremap ;"" ciw""<Esc>P
" Smart Quotes
inoremap <expr> ' strpart(getline('.'), col('.')-1, 1) == "\'" ? "\<C-g>U\<Right>" : "''\<C-g>U\<Left>"
inoremap '' '
inoremap <expr> " strpart(getline('.'), col('.')-1, 1) == "\"" ? "\<C-g>U\<Right>" : '""'."\<C-g>U\<Left>"
inoremap "" "
" Smart Parens
"inoremap <expr> <BS> strpart(getline('.'), col('.')-1, 1) == ")" | "}" ? "\<Right><BS><BS>" : "<BS>"
inoremap <expr> ) strpart(getline('.'), col('.')-1, 1) == ")" ? "\<C-g>U\<Right>" : ")"
inoremap ( ()<C-g>U<Left>
inoremap (<CR> (<CR>)<Esc>O
inoremap (( (
inoremap () ()
" Smart Braces
inoremap <expr> } strpart(getline('.'), col('.')-1, 1) == "}" ? "\<C-g>U\<Right>" : "}"
inoremap { {}<C-g>U<Left>
inoremap {<CR> {<CR>}<Esc>O
inoremap {{ {
inoremap {} {}
" Smart Brackets
inoremap <expr> ] strpart(getline('.'), col('.')-1, 1) == "]" ? "\<C-g>U\<Right>" : "]"
inoremap [ []<C-g>U<Left>
inoremap [<CR> [<CR>]<Esc>O
inoremap [[ [
inoremap [] []
" Smart Brackets
inoremap <expr> > strpart(getline('.'), col('.')-1, 1) == ">" ? "\<C-g>U\<Right>" : ">"
inoremap < <><C-g>U<Left>
inoremap </ </><C-g>U<Left>
inoremap << <
inoremap <> <>
" Quote wrapper function
function! QuickWrap(wrapper)
let l:w = a:wrapper
let l:inside_or_around = (&selection ==? 'exclusive') ? ('i') : ('a')
normal `>
execute "normal " . inside_or_around . escape(w, '\')
normal `<
execute "normal i" . escape(w, '\')
normal `<
endfunction
" toggle line numbers, nn (no number) " toggle line numbers, nn (no number)
nnoremap <silent> <Leader>nn nnoremap <silent> <Leader>nn
\ :if &number <Bar> \ :if &number <Bar>
@ -217,6 +273,7 @@ vnoremap <Leader>cw "hy
\ execute '%s/'.b:rep.'/'.b:sub.'/gc' <Bar> \ execute '%s/'.b:rep.'/'.b:sub.'/gc' <Bar>
\ unlet b:sub b:rep <Bar> \ unlet b:sub b:rep <Bar>
\ endif <CR> \ endif <CR>
nnoremap <Leader>cw nnoremap <Leader>cw
\ :let b:sub = input('interactive replacement: ') <Bar> \ :let b:sub = input('interactive replacement: ') <Bar>
\ if b:sub !=? '' <Bar> \ if b:sub !=? '' <Bar>

View File

@ -1,6 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
count=0
disconnected="/" disconnected="/"
disconnected2="\\" disconnected2="\\"
wireless_connected="" wireless_connected=""
@ -9,14 +8,9 @@ ethernet_connected=""
ID="$(ip link | awk '/state UP/ {print $2}')" ID="$(ip link | awk '/state UP/ {print $2}')"
while true; do while true; do
if (ping -c 1 archlabslinux.com || ping -c 1 google.com || ping -c 1 bitbucket.org || ping -c 1 github.com || ping -c 1 sourceforge.net) &>/dev/null; then if (ping -c 1 archlabslinux.com || ping -c 1 google.com || ping -c 1 bitbucket.org || ping -c 1 github.com || ping -c 1 sourceforge.net) >/dev/null 2>&1; then
if [[ $ID == e* ]]; then [[ $ID == e* ]] && { echo "$ethernet_connected"; sleep 25; } || { echo "$wireless_connected"; sleep 25; }
echo "$ethernet_connected" ; sleep 25
else else
echo "$wireless_connected" ; sleep 25 echo "$disconnected"; sleep 0.6; echo "$disconnected2"; sleep 0.6
fi
else
echo "$disconnected" ; sleep 0.6
echo "$disconnected2" ; sleep 0.6
fi fi
done done

View File

@ -1,6 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
TRASH_DIRECTORY="$BLOCK_INSTANCE" TRASH_DIRECTORY="$BLOCK_INSTANCE"
if [[ $TRASH_DIRECTORY = "" ]]; then if [[ $TRASH_DIRECTORY = "" ]]; then

View File

@ -26,7 +26,8 @@ usage() {
-l,--logout Session logout dialog -l,--logout Session logout dialog
Without any options -r,--run will be opened.
Without any options the run dialog will be opened.
EOF EOF
} }

View File

@ -6,32 +6,26 @@ NOTIFY_ICON=/usr/share/icons/gnome/32x32/apps/system-software-update.png
get_total_updates() { UPDATES=$(checkupdates 2>/dev/null | wc -l); } get_total_updates() { UPDATES=$(checkupdates 2>/dev/null | wc -l); }
while true; do while true; do
# print the icon first to avoid gibberish in polybar
echo $BAR_ICON
get_total_updates get_total_updates
# notify user of updates # notify user of updates
if hash notify-send &>/dev/null; then if hash notify-send >/dev/null 2>&1; then
if (( UPDATES > 50 )); then if (( UPDATES > 50 )); then
notify-send -u critical -i $NOTIFY_ICON \ notify-send -u critical -i $NOTIFY_ICON "Updates Available" "$UPDATES packages"
"You really need to update!!" "$UPDATES New packages"
elif (( UPDATES > 25 )); then elif (( UPDATES > 25 )); then
notify-send -u normal -i $NOTIFY_ICON \ notify-send -u normal -i $NOTIFY_ICON "Updates Available" "$UPDATES packages"
"You should update soon" "$UPDATES New packages"
elif (( UPDATES > 2 )); then elif (( UPDATES > 2 )); then
notify-send -u low -i $NOTIFY_ICON \ notify-send -u low -i $NOTIFY_ICON "Updates Available" "$UPDATES packages"
"$UPDATES New packages"
fi fi
fi fi
# when there are updates available # when there are updates available
# every 10 seconds another check for updates is done # every 10 seconds another check for updates is done
while (( UPDATES > 0 )); do while (( UPDATES > 0 )); do
if (( UPDATES == 1 )); then (( UPDATES == 1 )) && echo "$UPDATES Update" || { (( UPDATES > 1 )) && echo "$UPDATES Updates"; }
echo "$UPDATES Update"
elif (( UPDATES > 1 )); then
echo "$UPDATES Updates"
else
echo $BAR_ICON
fi
sleep 10 sleep 10
get_total_updates get_total_updates
done done
@ -39,7 +33,6 @@ while true; do
# when no updates are available, use a longer loop, this saves on CPU # when no updates are available, use a longer loop, this saves on CPU
# and network uptime, only checking once every 30 min for new updates # and network uptime, only checking once every 30 min for new updates
while (( UPDATES == 0 )); do while (( UPDATES == 0 )); do
echo $BAR_ICON
sleep 1800 sleep 1800
get_total_updates get_total_updates
done done