From c83f71d8459555465ebf1f77fdae918357b6523d Mon Sep 17 00:00:00 2001 From: Wiktor Zykubek Date: Sun, 24 May 2020 13:09:11 +0200 Subject: [PATCH] Add autistic Xresources "support" for rofi --- .config/Xresources | 3 +++ .config/rofi/config.rasi | 16 ++++++------- .profile | 50 ++++++++++++++++++++++++++++------------ 3 files changed, 46 insertions(+), 23 deletions(-) diff --git a/.config/Xresources b/.config/Xresources index e1f61f8..974290a 100644 --- a/.config/Xresources +++ b/.config/Xresources @@ -1,5 +1,8 @@ #define bg #0e0f14 #define sbg #282a38 +#define asbg #20232b /* darker sbg (rofi) */ +#define sel #363b47 /* selected (rofi) */ +#define asel #555a63 /* alt sel (rofi) */ #define fg #dfdfdf #define sfg #eeeeee diff --git a/.config/rofi/config.rasi b/.config/rofi/config.rasi index 4eaf111..7366728 100644 --- a/.config/rofi/config.rasi +++ b/.config/rofi/config.rasi @@ -9,15 +9,15 @@ configuration { } * { - maincolor: #282a38; - urgentcolor: #dfdfdf; - prompt-background: #20232b; - scrollbar-handle: #555a63; - foreground: #dfdfdf; - highlight: bold #6e99bf; + maincolor: ${SBG}; + urgentcolor: ${FG}; + prompt-background: ${ASBG}; + scrollbar-handle: ${ASEL}; + foreground: ${FG}; + highlight: bold ${C12}; background: @maincolor; - background-color: @background; - blackselect: #363b47; + background-color: @maincolor; + blackselect: ${SEL}; } window { diff --git a/.profile b/.profile index 7c99855..6b8582e 100644 --- a/.profile +++ b/.profile @@ -1,17 +1,6 @@ -#!/usr/bin/env bash -# -# ████ ██ ██ -# ██████ ░██░ ░░ ░██ -# ░██░░░██ ██████ ██████ ██████ ██ ░██ █████ -# ░██ ░██░░██░░█ ██░░░░██░░░██░ ░██ ░██ ██░░░██ -# ░██████ ░██ ░ ░██ ░██ ░██ ░██ ░██░███████ -# ░██░░░ ░██ ░██ ░██ ░██ ░██ ░██░██░░░░ -# ░██ ░███ ░░██████ ░██ ░██ ███░░██████ -# ░░ ░░░ ░░░░░░ ░░ ░░ ░░░ ░░░░░░ +#!/bin/sh -#~~~~~~~~~~~~~~ # Default Apps -#~~~~~~~~~~~~~~ export EDITOR="nvim" export BROWSER="firefox" export TERMINAL="st" @@ -27,13 +16,12 @@ export WGETRC="$XDG_CONFIG_HOME/wget/wgetrc" export GNUPGHOME="$XDG_DATA_HOME/gnupg" export LESSHISTFILE="-" -#~~~~~~ # PATH -#~~~~~~ export GOPATH=$HOME/.local/go export NPM_PACKAGES="$HOME/.yarn/bin/" export PATH="$PATH:$HOME/.local/bin/:$HOME/.local/bin/scripts/:$NPM_PACKAGES:$GOROOT/bin:$GOPATH/bin" +# Colors export LS_COLORS="no=00:fi=00:di=01;34:ln=01;36:pi=40;33:so=00;93:do=00;93:bd=40;33;01:cd=40;33;01:or=40;31;01:mi=01;05;37;41:su=37;41:sg=30;43:ca=30;41:tw=30;42:ow=1;34:st=37;44:ex=01;32:*.tar=01;36:*.tgz=01;36:*.svgz=00;93:*.arj=01;36:*.taz=01;36:*.lzh=01;36:*.lzma=01;36:*.zip=01;36:*.z=01;36:*.Z=01;36:*.dz=01;36:*.gz=01;36:*.bz2=01;36:*.tbz2=01;36:*.bz=01;36:*.tz=01;36:*.deb=01;36:*.rpm=01;36:*.jar=01;36:*.rar=01;36:*.ace=01;36:*.zoo=01;36:*.cpio=01;36:*.7z=01;36:*.rz=01;36:*.jpg=00;93:*.jpeg=00;93:*.gif=00;93:*.bmp=00;93:*.pbm=00;93:*.pgm=00;93:*.ppm=00;93:*.tga=00;93:*.xbm=00;93:*.xpm=00;93:*.tif=00;93:*.tiff=00;93:*.png=00;93:*.mng=00;93:*.pcx=00;93:*.mov=00;93:*.mpg=00;93:*.mpeg=00;93:*.m2v=00;93:*.mkv=00;93:*.ogm=00;93:*.mp4=00;93:*.m4v=00;93:*.mp4v=00;93:*.vob=00;93:*.qt=00;93:*.nuv=00;93:*.wmv=00;93:*.asf=00;93:*.rm=00;93:*.rmvb=00;93:*.flc=00;93:*.avi=00;93:*.fli=00;93:*.gl=00;93:*.dl=00;93:*.xcf=00;93:*.xwd=00;93:*.yuv=00;93:*.svg=00;93:*.aac=00;36:*.au=00;36:*.flac=00;35:*.mid=00;35:*.midi=00;35:*.mka=00;35:*.mp3=00;35:*.mpc=00;35:*.ogg=00;35:*.ra=00;35:*.wav=00;35:*.opus=00;35:" export FZF_DEFAULT_OPTS=' @@ -41,8 +29,40 @@ export FZF_DEFAULT_OPTS=' --color info:108,prompt:109,spinner:108,pointer:168,marker:168 ' -export _JAVA_AWT_WM_NONREPARENTING=1 +export BG="$(awk '/define bg/ { print $3 }' ~/.config/Xresources)" +export SBG="$(awk '/define sbg/ { print $3 }' ~/.config/Xresources)" +export ASBG="$(awk '/define asbg/ { print $3 }' ~/.config/Xresources)" +export FG="$(awk '/define fg/ { print $3 }' ~/.config/Xresources)" +export SFG="$(awk '/define sfg/ { print $3 }' ~/.config/Xresources)" +export SEL="$(awk '/define sel/ { print $3 }' ~/.config/Xresources)" +export ASEL="$(awk '/define asel/ { print $3 }' ~/.config/Xresources)" +# Unfortunetly shell is loading to slow when I do that :C +# input="$HOME/.config/Xresources" +# for i in $(seq 12); do +# export C$i="$(awk '/color$i/ { print $2 }' "$input")" +# done + +# export C1="$(awk '/color1/ { print $2 }' ~/.config/Xresources)" +# export C2="$(awk '/color2/ { print $2 }' ~/.config/Xresources)" +# export C3="$(awk '/color3/ { print $2 }' ~/.config/Xresources)" +# export C4="$(awk '/color4/ { print $2 }' ~/.config/Xresources)" +# export C5="$(awk '/color5/ { print $2 }' ~/.config/Xresources)" +# export C6="$(awk '/color6/ { print $2 }' ~/.config/Xresources)" +# export C7="$(awk '/color7/ { print $2 }' ~/.config/Xresources)" +# export C8="$(awk '/color8/ { print $2 }' ~/.config/Xresources)" +# export C9="$(awk '/color9/ { print $2 }' ~/.config/Xresources)" +# export C10="$(awk '/color10/ { print $2 }' ~/.config/Xresources)" +# export C11="$(awk '/color11/ { print $2 }' ~/.config/Xresources)" +export C12="$(awk '/color12/ { print $2 }' ~/.config/Xresources)" +# export C13="$(awk '/color13/ { print $2 }' ~/.config/Xresources)" +# export C14="$(awk '/color14/ { print $2 }' ~/.config/Xresources)" +# export C15="$(awk '/color15/ { print $2 }' ~/.config/Xresources)" +# export C16="$(awk '/color16/ { print $2 }' ~/.config/Xresources)" + +# Other +export _JAVA_AWT_WM_NONREPARENTING=1 export GPG_TTY=$(tty) +# Start X automatic on tty1 [ "$(tty)" = "/dev/tty1" ] && ! pgrep -x Xorg >/dev/null && exec startx