From fdd76fc572da832be1ed186c6dc1396117b10c4c Mon Sep 17 00:00:00 2001 From: danix Date: Sun, 7 Jun 2020 10:22:59 +0200 Subject: [PATCH 1/1] first push of my config files --- README.html | 1132 +++++++++++++++++ README.md | 85 ++ Xresources | 80 ++ bash_profile | 6 + bashrc | 108 ++ bin/blackpearl-appsmenu.sh | 4 + bin/blackpearl-powermenu.sh | 38 + bin/blackpearl-runner.sh | 4 + bin/blackpearl-scrotmenu.sh | 24 + bin/blackpearl-sshmenu.sh | 4 + bin/blackpearl-utilsmenu.sh | 20 + bin/blackpearl-window.sh | 12 + bin/executors/caps | 42 + bin/executors/inet | 24 + bin/executors/mail-check | 103 ++ bin/executors/psuinfo.py | 483 +++++++ bin/executors/wifi-name | 28 + bin/i3-exit | 24 + bin/i3-scrot | 80 ++ bin/i3lock-blur | 8 + bin/i3lock-fancy | 60 + bin/i3suspend | 7 + bin/is_installed | 123 ++ bin/vt-color-scheme.py | 59 + bin/wallpaper.sh | 42 + compton.conf | 55 + conky/qlocktwo.conkyrc | 50 + .../is_installed.bash-completion | 41 + etc/issue.blackpearl | 22 + etc/issue.buildbox | 18 + etc/profile.d/blackpearl.sh | 57 + i3/config | 316 +++++ rofi/blackpearl/appmenu.rasi | 73 ++ rofi/blackpearl/i3exit.rasi | 65 + rofi/blackpearl/powermenu.rasi | 49 + rofi/blackpearl/runner.rasi | 61 + rofi/blackpearl/scrotmenu.rasi | 48 + rofi/blackpearl/shared/reset.rasi | 28 + rofi/blackpearl/shared/settings.rasi | 19 + rofi/blackpearl/utilsmenu.rasi | 48 + tint2/.i3status.tint2rc.un~ | Bin 0 -> 4994 bytes tint2/i3status.tint2rc | 387 ++++++ tint2/i3status.tint2rc~ | 387 ++++++ tint2/minima.tint2rc | 362 ++++++ tmux/tmux.conf.danix | 208 +++ xinitrc | 22 + xprofile | 16 + 47 files changed, 4932 insertions(+) create mode 100644 README.html create mode 100644 README.md create mode 100644 Xresources create mode 100644 bash_profile create mode 100644 bashrc create mode 100755 bin/blackpearl-appsmenu.sh create mode 100755 bin/blackpearl-powermenu.sh create mode 100755 bin/blackpearl-runner.sh create mode 100755 bin/blackpearl-scrotmenu.sh create mode 100755 bin/blackpearl-sshmenu.sh create mode 100755 bin/blackpearl-utilsmenu.sh create mode 100755 bin/blackpearl-window.sh create mode 100755 bin/executors/caps create mode 100755 bin/executors/inet create mode 100755 bin/executors/mail-check create mode 100755 bin/executors/psuinfo.py create mode 100755 bin/executors/wifi-name create mode 100755 bin/i3-exit create mode 100755 bin/i3-scrot create mode 100755 bin/i3lock-blur create mode 100755 bin/i3lock-fancy create mode 100755 bin/i3suspend create mode 100755 bin/is_installed create mode 100644 bin/vt-color-scheme.py create mode 100755 bin/wallpaper.sh create mode 100644 compton.conf create mode 100644 conky/qlocktwo.conkyrc create mode 100644 etc/bash_completion.d/is_installed.bash-completion create mode 100644 etc/issue.blackpearl create mode 100644 etc/issue.buildbox create mode 100644 etc/profile.d/blackpearl.sh create mode 100644 i3/config create mode 100644 rofi/blackpearl/appmenu.rasi create mode 100644 rofi/blackpearl/i3exit.rasi create mode 100644 rofi/blackpearl/powermenu.rasi create mode 100644 rofi/blackpearl/runner.rasi create mode 100644 rofi/blackpearl/scrotmenu.rasi create mode 100644 rofi/blackpearl/shared/reset.rasi create mode 100644 rofi/blackpearl/shared/settings.rasi create mode 100644 rofi/blackpearl/utilsmenu.rasi create mode 100644 tint2/.i3status.tint2rc.un~ create mode 100644 tint2/i3status.tint2rc create mode 100644 tint2/i3status.tint2rc~ create mode 100644 tint2/minima.tint2rc create mode 100644 tmux/tmux.conf.danix create mode 100644 xinitrc create mode 100644 xprofile diff --git a/README.html b/README.html new file mode 100644 index 0000000..af6792e --- /dev/null +++ b/README.html @@ -0,0 +1,1132 @@ +README

My Dotfiles

+

This is the collection of dotfiles that I use on my laptop for ricing pourposes

+

Some screenshots

+

+

Getting Started

+

All of these files will go in your home directory. See Installing for a brief description of where to put each file in this repository.

+

Prerequisites

+

You should know how linux works at least a little bit, but you can use this setup as your starting point, so Bash is a must. +I work on Slackware since 2006, so you’ll have to adapt everything if you’re using another distro. As for the software used here you have it:

+ +

Installing

+

The bin directory is where we’ll store all executables, so you may want to add it to your path, otherwhise you could use something like /usr/local/bin, but make sure to fix every reference to your executables in the other files.

+

i3, conky, rofi and tint2 directories must go inside your ~/.config directory, this is standard and you shouldn’t have any problems with it.

+

Xresources, bash_profile, bashrc and xinitrc are all hidden files and you should place them in your home prepending a dot to their names, so everything should look like this: +

$> ls /home/danix
+.Xresources
+.bash_profile
+.bashrc
+.xinitrc
+[...]
+
+Here’s how it looks for me on a fresh install: +
$> tree /home/danix
+├── .Xresources
+├── .bash_profile
+├── .bashrc
+├── bin/
+│   ├── blackpearl-appsmenu.sh
+│   ├── blackpearl-powermenu.sh
+│   ├── blackpearl-runner.sh
+│   ├── blackpearl-scrotmenu.sh
+│   ├── blackpearl-sshmenu.sh
+│   ├── blackpearl-utilsmenu.sh
+│   ├── blackpearl-window.sh
+│   └── executors/
+│       ├── caps
+│       ├── inet
+│       ├── mail-check
+│       ├── psuinfo.py
+│       └── wifi-name
+├── .config/
+│   ├── compton.conf
+│   ├── i3/
+│   |   └── config
+│   ├── conky/
+│   |   └── qlocktwo.conkyrc
+│   ├── rofi/
+│   |   └── blackpearl/
+│   |       ├── appmenu.rasi
+│   |       ├── i3exit.rasi
+│   |       ├── powermenu.rasi
+│   |       ├── runner.rasi
+│   |       ├── scrotmenu.rasi
+│   |       ├── shared/
+│   |       │   ├── reset.rasi
+│   |       │   └── settings.rasi
+│   |       └── utilsmenu.rasi
+│   └── tint2/
+│       ├── i3status.tint2rc
+│       └── minima.tint2rc
+└── .xinitrc
+

+

Authors

+ +

License and Acknowledgments

+

This project is free to use as it is, if you need help you can contact me on my site and I’ll try and help you, but you maybe luckier asking your questions on the unixporn thread on reddit, which is where I found the inspiration and most of the links to make all this work.

\ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..4747cd6 --- /dev/null +++ b/README.md @@ -0,0 +1,85 @@ +# My Dotfiles + +This is the collection of dotfiles that I use on my laptop for ricing pourposes + +## Getting Started + +All of these files will go in your home directory. See [Installing](#installing) for a brief description of where to put each file in this repository. + +### Prerequisites + +You should know how linux works at least a little bit, but you can use this setup as your starting point, so Bash is a must. +I work on [Slackware](http://www.slackware.com/) since 2006, so you'll have to adapt everything if you're using another distro. As for the software used here you have it: + +* [i3-gaps](https://github.com/Airblader/i3) - My window manager of choice. +* [feh](https://feh.finalrewind.org/) - wallpaper setter. Fast and lightweight. +* [conky](https://github.com/brndnmtthws/conky) - system monitor, I use it for my desk clock, but it can do so so much more. +* [rofi](https://github.com/davatorium/rofi) - Extremely customizable dmenu replacement, I use the git version. +* [tint2](https://gitlab.com/o9000/tint2) - Great lightweight bar that can run custom scripts. +* [compton](https://github.com/chjj/compton) - Lightweight compositor. + +### Installing + +The **bin** directory is where we'll store all executables, so you may want to add it to your path, otherwhise you could use something like `/usr/local/bin`, but make sure to fix every reference to your executables in the other files. + +**i3**, **conky**, **rofi** and **tint2** directories must go inside your `~/.config` directory, this is standard and you shouldn't have any problems with it. + +**Xresources**, **bash_profile**, **bashrc** and **xinitrc** are all hidden files and you should place them in your home prepending a dot to their names, so everything should look like this: +``` +$> ls /home/danix +.Xresources +.bash_profile +.bashrc +.xinitrc +[...] +``` +Here's how it looks for me on a fresh install: +``` +$> tree /home/danix +├── .Xresources +├── .bash_profile +├── .bashrc +├── bin/ +│   ├── blackpearl-appsmenu.sh +│   ├── blackpearl-powermenu.sh +│   ├── blackpearl-runner.sh +│   ├── blackpearl-scrotmenu.sh +│   ├── blackpearl-sshmenu.sh +│   ├── blackpearl-utilsmenu.sh +│   ├── blackpearl-window.sh +│   └── executors/ +│   ├── caps +│   ├── inet +│   ├── mail-check +│   ├── psuinfo.py +│   └── wifi-name +├── .config/ +│   ├── compton.conf +│   ├── i3/ +│   |   └── config +│   ├── conky/ +│   |   └── qlocktwo.conkyrc +│   ├── rofi/ +│   |   └── blackpearl/ +│   |   ├── appmenu.rasi +│   |   ├── i3exit.rasi +│   |   ├── powermenu.rasi +│   |   ├── runner.rasi +│   |   ├── scrotmenu.rasi +│   |   ├── shared/ +│   |   │   ├── reset.rasi +│   |   │   └── settings.rasi +│   |   └── utilsmenu.rasi +│   └── tint2/ +│      ├── i3status.tint2rc +│      └── minima.tint2rc +└── .xinitrc +``` + +## Authors + +* **danix** - [danix.xyz](https://danix.xyz) + +## License and Acknowledgments + +This project is free to use as it is, if you need help you can contact me on my site and I'll try and help you, but you maybe luckier asking your questions on the [unixporn thread on reddit](https://www.reddit.com/r/unixporn/), which is where I found the inspiration and most of the links to make all this work. diff --git a/Xresources b/Xresources new file mode 100644 index 0000000..e147af6 --- /dev/null +++ b/Xresources @@ -0,0 +1,80 @@ +Xft.dpi: 96 +Xft.antialias: true +Xft.hinting: true +Xft.rgba: rgb +Xft.autohint: false +Xft.hintstyle: hintslight +Xft.lcdfilter: lcddefault + +XTerm*pointerColor: #16A085 +XTerm*faceName: Fixed +XTerm*faceSize: 11 + +*background: #272827 +*foreground: #657b83 +*fading: 15 +*fadeColor: black +*cursorColor: #16A085 +*pointerColorBackground:#2B2C2B +*pointerColorForeground:#16A085 + +! special +*.foreground: #f5f5f5 +*.background: #303030 +*.cursorColor: #f5f5f5 + +! black +*.color0: #303030 +*.color8: #424242 + +! red +*.color1: #d32f2f +*.color9: #e57373 + +! green +*.color2: #388e3c +*.color10: #81c784 + +! yellow +*.color3: #f57c00 +*.color11: #ffb74d + +! blue +*.color4: #303f9f +*.color12: #7986cb + +! magenta +*.color5: #c51162 +*.color13: #ff4081 + +! cyan +*.color6: #1976d2 +*.color14: #64b5f6 + +! white +*.color7: #bdbdbd +*.color15: #f5f5f5 + + +XTerm*background: #303030 +XTerm*foreground: #f5f5f5 +XTerm*reverseVideo: on +XTerm*selectToClipboard: true + +URxvt*termName: rxvt-256color +URxvt.font: xft:Droid Sans Mono for Powerline:size=10,style=regular +URxvt.geometry: 120x30 +URxvt.depth: 32 +URxvt.background: [80]#303030 +URxvt*scrollBar: false +URxvt*mouseWheelScrollPage: false +URxvt*cursorBlink: true +URxvt*cursorUnderline: true +URxvt*.foreground: #f5f5f5 +URxvt*cursorColor: #f5f5f5 +URxvt*saveLines: 5000 +URxvt.internalBorder: 1 + +URxvt.colorIT: #81c784 +URxvt.colorBD: #f5f5f5 +URxvt.colorUL: #7986cb diff --git a/bash_profile b/bash_profile new file mode 100644 index 0000000..d05411c --- /dev/null +++ b/bash_profile @@ -0,0 +1,6 @@ +#! /bin/bash + +if [ -f ~/.bashrc ]; then + source ~/.bashrc +fi + diff --git a/bashrc b/bashrc new file mode 100644 index 0000000..776707b --- /dev/null +++ b/bashrc @@ -0,0 +1,108 @@ +export GIT_PS1_SHOWCOLORHINTS=true +export GIT_PS1_SHOWUNTRACKEDFILES=true +export GIT_PS1_SHOWDIRTYSTATE=true +export GIT_PS1_SHOWSTASHSTATE=true + +# turns on bash autocompletion +if [ -f /etc/profile.d/bash_completion.sh ]; then + . /etc/profile.d/bash_completion.sh +fi + +# actual theme "MATERIAL DARK" +#if [ "$TERM" = "linux" ]; then +# echo -en "\e]P0303030" +# echo -en "\e]P1d32f2f" +# echo -en "\e]P2388e3c" +# echo -en "\e]P3f57c00" +# echo -en "\e]P4303f9f" +# echo -en "\e]P5c51162" +# echo -en "\e]P61976d2" +# echo -en "\e]P7bdbdbd" +# echo -en "\e]P8424242" +# echo -en "\e]P9e57373" +# echo -en "\e]PA81c784" +# echo -en "\e]PBffb74d" +# echo -en "\e]PC7986cb" +# echo -en "\e]PDff4081" +# echo -en "\e]PE64b5f6" +# echo -en "\e]PFf5f5f5" +# clear +#fi + +user_color=32m +if [ ${UID} -eq 0 ] +then + user_color=31m +fi + +PS1='[\[\e[$user_color\]\u\[\e[37m\]@\[\e[34m\]\h \[\e[37m\]- \w] \d \t\n$(__git_ps1)\\$ ' + +case "$TERM" in + xterm*|*rxvt*) + PROMPT_COMMAND='echo -ne "\033]0;${USER}@`echo $HOSTNAME|cut -d"." -f1`: ${PWD}\007"' + ;; + *) + PROMPT_COMMAND="" + ;; +esac + +alias su="su -" +alias ls="ls --color -lh" +alias cp="cp -v" +alias rm="rm -v" +alias mv="mv -v" +alias chmod="chmod -v" +alias chown="chown -v" +alias apropos="wtf is" +alias free="free -m" +alias df="df -h" +alias du="du -sh" +alias diff='diff --color=auto' +alias grep='grep --color=auto' + + +export PATH=~/.local/bin:~/bin:$PATH +export INTEL_BATCH=1 +export QT_QPA_PLATFORMTHEME="lxqt" +export QT_STYLE_OVERRIDE="kvantum-dark" +export XDG_DATA_DIRS="/usr/local/share/:/usr/share/" + +# Tailoring LESS +alias more='less' +export LESS='-R' +export LESSOPEN='|~/.lessfilter %s' +export PAGER=less +export SVN_EDITOR=vim +export LESSCHARSET='latin1' + +man() { + LESS_TERMCAP_md=$'\e[01;31m' \ + LESS_TERMCAP_me=$'\e[0m' \ + LESS_TERMCAP_se=$'\e[0m' \ + LESS_TERMCAP_so=$'\e[01;44;33m' \ + LESS_TERMCAP_ue=$'\e[0m' \ + LESS_TERMCAP_us=$'\e[01;32m' \ + command man "$@" +} + +# sudo password helper +export SUDO_ASKPASS=/usr/bin/lxsudo + +# logdate appends a date to a script output +logdate() { + while IFS= read -r line; do + echo "$(date +"%F_%R.%S") $line" + done +} + +unset GPG_AGENT_INFO +unset SSH_AGENT_PID +if [ "${gnupg_SSH_AUTH_SOCK_by:-0}" -ne $$ ]; then + export SSH_AUTH_SOCK="${HOME}/.gnupg/S.gpg-agent.ssh" +fi +GPG_TTY=$(tty) +export GPG_TTY +if [ -x "$(which gpg-connect-agent)" ]; then + gpg-connect-agent updatestartuptty /bye >& /dev/null +fi + diff --git a/bin/blackpearl-appsmenu.sh b/bin/blackpearl-appsmenu.sh new file mode 100755 index 0000000..207165c --- /dev/null +++ b/bin/blackpearl-appsmenu.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +rofi -no-lazy-grab -show drun -theme blackpearl/appmenu + diff --git a/bin/blackpearl-powermenu.sh b/bin/blackpearl-powermenu.sh new file mode 100755 index 0000000..aa203e3 --- /dev/null +++ b/bin/blackpearl-powermenu.sh @@ -0,0 +1,38 @@ +#!/bin/bash + +rofi_command="rofi -theme blackpearl/powermenu.rasi" + +### Options ### +power_off="" +reboot="" +lock="" +suspend="鈴" +log_out="" +# Variable passed to rofi +options="$power_off\n$reboot\n$lock\n$suspend\n$log_out" + +chosen="$(echo -e "$options" | $rofi_command -dmenu -selected-row 2)" +case $chosen in + $power_off) + notify-send 'shutting down' 'the system is going to shutdown now' + sleep 1 + sudo /sbin/shutdown -h now + ;; + $reboot) + notify-send 'rebooting the system' 'the system is going to reboot now' + sleep 1 + sudo /sbin/shutdown -r now + ;; + $lock) + sleep 1 + i3lock-blur + ;; + $suspend) + sleep 1 + i3suspend + ;; + $log_out) + i3-exit + ;; +esac + diff --git a/bin/blackpearl-runner.sh b/bin/blackpearl-runner.sh new file mode 100755 index 0000000..687e3a8 --- /dev/null +++ b/bin/blackpearl-runner.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +rofi -no-lazy-grab -show run -theme blackpearl/runner + diff --git a/bin/blackpearl-scrotmenu.sh b/bin/blackpearl-scrotmenu.sh new file mode 100755 index 0000000..18bec3d --- /dev/null +++ b/bin/blackpearl-scrotmenu.sh @@ -0,0 +1,24 @@ +#!/bin/bash + +rofi_command="rofi -theme blackpearl/scrotmenu.rasi" + +### Options ### +screen="" +area="" +window="" +# Variable passed to rofi +options="$screen\n$area\n$window" + +chosen="$(echo -e "$options" | $rofi_command -dmenu -selected-row 1)" +case $chosen in + $screen) + sleep 1; i3-scrot + ;; + $area) + i3-scrot -s + ;; + $window) + sleep 1; i3-scrot -u + ;; +esac + diff --git a/bin/blackpearl-sshmenu.sh b/bin/blackpearl-sshmenu.sh new file mode 100755 index 0000000..d8c879e --- /dev/null +++ b/bin/blackpearl-sshmenu.sh @@ -0,0 +1,4 @@ +#!/bin/sh + +rofi -no-lazy-grab -show ssh -no-parse-known-hosts -theme blackpearl/appmenu.rasi + diff --git a/bin/blackpearl-utilsmenu.sh b/bin/blackpearl-utilsmenu.sh new file mode 100755 index 0000000..a2f8052 --- /dev/null +++ b/bin/blackpearl-utilsmenu.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +rofi_command="rofi -theme blackpearl/utilsmenu.rasi" + +### Options ### +wpaper="" +webdevel="" +# Variable passed to rofi +options="$wpaper\n$webdevel" + +chosen="$(echo -e "$options" | $rofi_command -dmenu -selected-row 1)" +case $chosen in + $wpaper) + change_wallpaper.sh + ;; + $webdevel) + webdevel + ;; +esac + diff --git a/bin/blackpearl-window.sh b/bin/blackpearl-window.sh new file mode 100755 index 0000000..81b28b4 --- /dev/null +++ b/bin/blackpearl-window.sh @@ -0,0 +1,12 @@ +#!/bin/sh + +case $1 in + all ) + rofi -no-lazy-grab -show window -theme blackpearl/appmenu.rasi + ;; + desktop ) + rofi -no-lazy-grab -show windowcd -theme blackpearl/appmenu.rasi + ;; +esac + + diff --git a/bin/executors/caps b/bin/executors/caps new file mode 100755 index 0000000..5bdc727 --- /dev/null +++ b/bin/executors/caps @@ -0,0 +1,42 @@ +#! /bin/bash + +# Check caps lock and numlock status and display using icons + + +CAPS=$(xset -q |grep Caps |awk -F ' ' '{ print $4 }') +NUMS=$(xset -q |grep Caps |awk -F ' ' '{ print $8 }') + +function num_lock () { + if [[ $NUMS == "on" ]]; then + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/num-lock-on.svg" + else + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/num-lock-off.svg" + fi +} + +function caps_lock () { + if [[ $CAPS == "on" ]]; then + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/caps-lock-on.svg" + else + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/caps-lock-off.svg" + fi +} + +case $1 in + -n ) + num_lock + ;; + -c ) + caps_lock + ;; +esac + + + + + + +if [[ $CLOCK == "true" && $NLOCK == "true" ]]; then + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/caps-lock-on.svg" + echo "/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/num-lock-on.svg" +fi diff --git a/bin/executors/inet b/bin/executors/inet new file mode 100755 index 0000000..276a357 --- /dev/null +++ b/bin/executors/inet @@ -0,0 +1,24 @@ +#!/bin/sh + +# This script displays Internet DL/UL speed, external and internal IP address in a single row +# Dependencies: `speedtest-cli`, `bind-tools` (Arch) or `dnsutils` (Debian) + +# Author: Piotr Miller +# e-mail: nwg.piotr@gmail.com +# Website: http://nwg.pl +# Project: https://github.com/nwg-piotr/tint2-executors +# License: GPL3 + +IP="sudo /usr/sbin/ip" +spd=$(speedtest-cli --simple) +dl=$(echo $spd | awk '{print $5}') +ul=$(echo $spd | awk '{print $8}') + +#w=$(dig +short myip.opendns.com @resolver1.opendns.com) +#l=$($IP addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/') + +notify-send "$spd" + +# Log results to the text file +date "+%d-%m-%y %H:%M" >> ~/Documents/speedtest.log +echo $spd >> ~/Documents/speedtest.log \ No newline at end of file diff --git a/bin/executors/mail-check b/bin/executors/mail-check new file mode 100755 index 0000000..95797c6 --- /dev/null +++ b/bin/executors/mail-check @@ -0,0 +1,103 @@ +#!/usr/bin/env python3 + +""" +A very simple imap e-mail notifier. +Tested (and working) with Debian 8 (Jessie) + Xfce. +""" + +import imaplib +import re +import time +import sys +import os +import argparse + + +def MainProgram(): + server_error = 0 + status = "" + unread = 0 + + parser = argparse.ArgumentParser(description='Check your email.') + parser.add_argument("-g", "--gmail", help="connect to gmail imap server", action="store_true") + parser.add_argument("-c", "--custom", help="connect to custom imap server", type=str, default=argparse.SUPPRESS) + parser.add_argument("-u", "--user", help="Username", type=str, required=True) + parser.add_argument("-p", "--pword", help="Password", type=str, required=True) + parser.add_argument("-r", "--port", help="Port to connect to", default="993", type=int) + parser.add_argument("-d", "--display", help="Display Name", type=str) + + args = parser.parse_args() + + if args.gmail: + imapServer = "imap.gmail.com" + else: + if args.custom: + imapServer = args.custom + + if args.display: + displayName = args.display + else: + displayName = imapUserName + + try: + imapUserName = args.user + except Exception as e: + raise + + try: + imapPass = args.pword + except Exception as e: + raise + + try: + imapPort = args.port + except Exception as e: + raise + + + # # Enter your imap settings below + # imapServer = "imap.gmail.com" + # # imapUserName = "danixland@gmail.com" + # imapUserName = "it.danilo.macri@gmail.com" + # # imapPass = "jxibrnebktqbkhmx" + # imapPass = "udykutvueszpxfkd" + # imapPort = 993 + # # displayName = "gmail - danixland" + # displayName = "gmail - Danilo Macri" + + # Try to connect to imap server + try: + server = imaplib.IMAP4_SSL(imapServer, imapPort) + server.login(imapUserName, imapPass) + status, unread = server.status('INBOX', "(UNSEEN)") + except Exception: + pass + + if status != "OK": + server_error = 1 + + # Retry a couple of times even though we got wrong response from server + while server_error >= 1 and server_error < 4: + time.sleep(2) + if status == "OK": + server_error = 0 + else: + server_error += 1 + MainProgram() # Try to connect again + + CHECK_UNREAD = str(unread) + NO_OF_UNREAD = re.sub(r'\D', "", CHECK_UNREAD) + + if server_error > 3: + # os.system('notify-send "Problem connecting to imap server"') + print("Problem connecting to imap server") + elif int(NO_OF_UNREAD) > 0: + # os.system('notify-send "You have new mail"') + print("/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/new-messages-red.svg") + print("{}: {} new mail".format(displayName, NO_OF_UNREAD)) + elif int(NO_OF_UNREAD) == 0: + print("/usr/share/icons/MB-Mango-Suru-GLOW/panel/16/applications-email-panel.svg") + print("{}: No new mail".format(displayName)) + + +MainProgram() diff --git a/bin/executors/psuinfo.py b/bin/executors/psuinfo.py new file mode 100755 index 0000000..40b6907 --- /dev/null +++ b/bin/executors/psuinfo.py @@ -0,0 +1,483 @@ +#!/usr/bin/env python3 +# _*_ coding: utf-8 _*_ + +""" +A psutil-based command to display customizable system usage info in a single line, intended for Tint2 executors + +Author: Piotr Miller +e-mail: nwg.piotr@gmail.com +Website: http://nwg.pl +Project: https://github.com/nwg-piotr/psuinfo +License: GPL3 + +Inspired by https://github.com/tknomanzr/scripts/blob/master/tint2/executors/cpu.py by William Bradley (@tknomanzr) +""" + +import sys +import psutil +import time +import os + + +def main(): + fahrenheit = False + names = False + testing = False + time_start = None + components = "gStfM" + separator = " " + home = os.getenv("HOME") + draw_icons = False + + pcpu, avg, speed, freqs, temp, fans, b_time, memory, swap, disks_usage, which, ul, dl, xfer_start, xfer_finish, \ + path_to_icon, c_name= None, None, None, None, None, None, None, None, None, None, None, None, None, None, \ + None, None, None + + for i in range(1, len(sys.argv)): + if sys.argv[i] == "-h" or sys.argv[i] == "--help": + print_help() + exit(0) + + if sys.argv[i] == "-F": + fahrenheit = True + + if sys.argv[i] == "-N": + names = True + + if sys.argv[i] == "-T": + testing = True + + if sys.argv[i].startswith("-C"): + components = sys.argv[i][2::] + + if sys.argv[i].startswith("-S"): + try: + # if number given + spacing = int(sys.argv[i][2::]) + separator = " " * spacing + except ValueError: + # string given + separator = sys.argv[i][2::] + + if sys.argv[i].startswith("-W"): + try: + which = int(sys.argv[i][2::]) + except ValueError: + pass + + if sys.argv[i].upper() == "-ALL": + components = "gpaQStfMcWDUk" + names = True + testing = True + + if sys.argv[i].startswith("-I"): + draw_icons = True + # We can only have one icon per executor, so let's strip components to the first one + components = sys.argv[i][2] + # exception for UL/DL speed; to assign an icon to it we need to calculate speeds first + if components != "k": + path_to_icon = icon_path(home, components) + + if sys.argv[i].startswith("-M"): + # We can only have a custom name for a single component + components = components[0] + names = True + c_name = sys.argv[i][2::] + + if testing: + time_start = int(round(time.time() * 1000)) + + output = "" + + # Prepare ONLY requested data, ONLY once + if "g" or "p" in components: + try: + pcpu = psutil.cpu_percent(interval=1, percpu=True) + except: + pass + + if "a" in components: + try: + avg = str(psutil.cpu_percent(interval=1)) + if len(avg) < 4: + avg = " " + avg + except: + pass + + if "s" or "S" in components: + try: + speed = psutil.cpu_freq(False) + except: + pass + + if "q" or "Q" in components: + try: + freqs = psutil.cpu_freq(True) + if len(freqs) == 0: + freqs = None + except: + pass + + if "t" in components: + try: + temp = psutil.sensors_temperatures(fahrenheit) + except: + pass + + if "f" in components: + try: + fans = psutil.sensors_fans() + except: + pass + + if "m" or "M" or "z" or "Z" in components: + try: + memory = psutil.virtual_memory() + except: + pass + + if "w" or "W" or "x" in components: + try: + swap = psutil.swap_memory() + except: + pass + + if "k" in components: + try: + xfer_start = psutil.net_io_counters() + time.sleep(1) + xfer_finish = psutil.net_io_counters() + ul = (xfer_finish[0] - xfer_start[0]) / 1024 + dl = (xfer_finish[1] - xfer_start[1]) / 1024 + # We've not selected an icon previously. Now we have enough data. + if draw_icons: + path_to_icon = net_icon(home, ul, dl) + except: + pass + + drives = [] + # Find drive names, mountpoints + if "d" or "D" or "n" or "N" in components: + try: + d = psutil.disk_partitions() + # This will store name, mountpoint + for entry in d: + n = entry[0].split("/") + name = n[len(n) - 1] + # name, mountpoint + drive = name, entry[1] + drives.append(drive) + except: + pass + + if "d" or "D" in components: + try: + disks_usage = [] + for drive in drives: + # Search drives by path + data = psutil.disk_usage(drive[1]) + # Store name, used, total, percent + essential = drive[0].upper(), data[1], data[0], data[3] + disks_usage.append(essential) + except: + pass + + if "n" in components or "N" in components: + try: + disks_usage = [] + for drive in drives: + # Search drives by path + data = psutil.disk_usage(drive[1]) + # Store mountpoint, used, total, percent + essential = drive[1], data[1], data[0], data[3] + disks_usage.append(essential) + except: + pass + + if "u" or "U" in components: + try: + b_time = psutil.boot_time() + except: + pass + + # Build output component after component + output += separator + + for char in components: + if char == "g" and pcpu is not None: + if c_name: + output += c_name + output += graph_per_cpu(pcpu) + separator + + if char == "p" and pcpu is not None: + if names: + output += c_name if c_name else "CPU: " + output += per_cpu(pcpu) + separator + + if char == "a" and avg is not None: + if names: + output += c_name if c_name else "avCPU: " + output += avg + "%" + separator + + if char == "q" and freqs is not None: + if names: + output += c_name if c_name else "CPU: " + output += freq_per_cpu(freqs)[0][:-1] + " GHz" + separator + + if char == "Q" and freqs is not None: + if names: + output += c_name if c_name else "CPU: " + result = freq_per_cpu(freqs) + output += result[0][:-1] + "/" + str(result[1]) + " GHz" + separator + + if char == "s" and speed is not None: + if names: + output += c_name if c_name else "SPD: " + output += str(round(speed[0] / 1000, 1)) + " GHz" + separator + + if char == "S" and speed is not None: + if names: + output += c_name if c_name else "avSPD: " + output += str(round(speed[0] / 1000, 1)) + "/" + str(round(speed[2] / 1000, 1)) + " GHz" + separator + + if char == "t" and temp is not None and len(temp) > 0: + if names: + output += c_name if c_name else "CORE: " + if "k10temp" in temp.keys(): + # ryzen, multiple Die temperatures for threadripper/Epyc + ryzen_die_temps = [sensor.current for sensor in temp["k10temp"] if sensor.label == 'Tdie'] + output += str(int(max(ryzen_die_temps))) + if "coretemp" in temp.keys(): + # intel + output += str(int(temp["coretemp"][0][1])) + output += "℉" if fahrenheit else "℃" + output += separator + + if char == "f" and fans is not None and len(fans) > 0: + if names: + output += c_name if c_name else "FAN: " + fan0 = next(iter(fans.values())) + output += str(fan0[0][1]) + "/m" + separator + + if char == 'm' and memory is not None: + if names: + output += c_name if c_name else "MEM: " + output += str(round((memory[0] - memory[1]) / 1073741824, 1)) + " GB" + separator + + if char == 'M' and memory is not None: + if names: + output += c_name if c_name else "MEM: " + output += str(round((memory[3]) / 1073741824, 1)) + "/" + str( + round(memory[0] / 1073741824, 1)) + " GB" + separator + + if char == 'c' and memory is not None: + if names: + output += c_name if c_name else "MEM: " + output += str(memory[2]) + "%" + separator + + if char == 'C' and memory is not None: + if names: + output += c_name if c_name else "MEM: " + output += str(100 - memory[2]) + "%" + separator + + if char == 'u' and b_time is not None: + up_time = int(time.time()) - b_time + m, s = divmod(up_time, 60) + h, m = divmod(m, 60) + if names: + output += c_name if c_name else "UP: " + output += "%d:%02d" % (h, m) + separator + + if char == 'U' and b_time is not None: + up_time = int(time.time()) - b_time + m, s = divmod(up_time, 60) + h, m = divmod(m, 60) + if names: + output += c_name if c_name else "UP: " + output += "%d:%02d:%02d" % (h, m, s) + separator + + if char == "w" and swap is not None: + if names: + output += c_name if c_name else "SWAP: " + output += str(round(swap[1] / 1073741824, 1)) + " GB" + separator + + if char == "W" and swap is not None: + if names: + output += c_name if c_name else "SWAP: " + output += str(round(swap[1] / 1073741824, 1)) + "/" + output += str(round(swap[0] / 1073741824, 1)) + " GB" + separator + + if char == "x" and swap is not None: + if names: + output += c_name if c_name else "SWAP: " + output += str(swap[3]) + "%" + separator + + if char == "d" or char == "n" and disks_usage is not None: + if which is not None: + try: + entry = disks_usage[which] + output += entry[0] + ": " + output += str(entry[3]) + "%" + separator + except IndexError: + pass + else: + for entry in disks_usage: + output += entry[0] + ": " + output += str(entry[3]) + "%" + separator + + if char == "D" or char == "N" and disks_usage is not None: + if c_name: + output += c_name + if which is not None: + try: + entry = disks_usage[which] + output += entry[0] + ": " + output += str(round(entry[1] / 1073741824, 1)) + "/" + output += str(round(entry[2] / 1073741824, 1)) + " GB" + separator + except IndexError: + pass + else: + for entry in disks_usage: + output += entry[0] + ": " + output += str(round(entry[1] / 1073741824, 1)) + "/" + output += str(round(entry[2] / 1073741824, 1)) + " GB" + separator + + if char == "k": + if names and xfer_start is not None and xfer_finish is not None: + output += c_name if c_name else "Net: " + output += '{:0.2f}'.format((xfer_finish[0] - xfer_start[0]) / 1024) + ' {:0.2f} kB/s'.format( + (xfer_finish[1] - xfer_start[1]) / 1024) + separator + + if testing: + output += "[" + str(int((round(time.time() * 1000)) - time_start) / 1000) + "s]" + separator + + # remove leading and trailing separator + l = len(separator) + if l > 0: + output = output[l:-l] + + if draw_icons: + print(path_to_icon) + + print(output) + + +def per_cpu(result): + string = "" + for val in result: + proc = str(int(round(val, 1))) + if len(proc) < 2: + proc = " " + proc + string += proc + "% " + return string + + +def freq_per_cpu(result): + string = "" + max_freq = 0 + for val in result: + freq = str(round(val[0] / 1000, 1)) + string += freq + "|" + max_freq = str(round(val[2] / 1000, 1)) + + return string, max_freq + + +def graph_per_cpu(result): + graph = "_▁▂▃▄▅▆▇███" + + string = "" + for val in result: + proc = int(round(val / 10, 0)) + string += graph[proc] + return string + + +def print_help(): + + print("\npsuinfo [-C{components}] | [-I{component}] [-F] [-N] [-S] | [-S] [-T] [-W{number}] [-all] [-h] [--help]") + + print("\n-C defines multiple components. -I defines a single component. If none given, -CgStfM argument will be used by default.\n") + print(" g - (g)raphical CPU load bar") + print(" p - (p)ercentage for each core (text)") + print(" a - (a)verage CPU load (text)") + print(" q - fre(q)ency for each thread") + print(" Q - fre(Q)ency for each thread/max frequency") + print(" s - current CPU (s)peed") + print(" S - current/max CPU (S)peed") + print(" t - CPU (t)emperature") + print(" f - (f)an speed") + print(" m - (m)emory in use") + print(" M - (M)emory in use/total") + print(" c - used memory per(c)entage") + print(" C - free memory per(C)entage") + print(" w - s(w)ap memory in use") + print(" W - s(W)ap memory in use/total") + print(" x - swap usage in %") + print(" d - (d)rives as names usage in %") + print(" D - (D)rives as names used/total") + print(" n - drives as mou(n)tpoints usage in %") + print(" N - drives as mou(N)tpoints used/total") + print(" u - (u)ptime HH:MM") + print(" U - (U)ptime HH:MM:SS") + print(" k - current networ(k) traffic as upload/download in kB/s") + + print("\n-F - use Fahrenheit instead of ℃") + print("-N - display field names (except for (g)raphical CPU load bar)") + print("-S - number of spaces between components (-S2 if none given)") + print("-S for custom separator (use \' | \' to include spaces)") + print("-M for custom component name (\'My custom name: \')") + print("-T - test execution time") + print("-all - display all possible data (for use in terminal)\n") + + print("-I - show an icon before text; 1 component per executor allowed") + print("-W - select 0 to n-th element from multiple output (drives, mountpoints)\n") + + +def icon_path(home, component): + icons = {'g': '', + 'p': 'cpu.svg', + 'a': 'cpu.svg', + 'q': 'cpu.svg', + 'Q': 'cpu.svg', + 's': 'cpu.svg', + 'S': 'cpu.svg', + 't': 'temp.svg', + 'f': 'fan.svg', + 'm': 'network-card.svg', + 'M': 'network-card.svg', + 'c': 'network-card.svg', + 'C': 'network-card.svg', + 'w': 'swap.svg', + 'W': 'swap.svg', + 'x': 'swap.svg', + 'd': 'drive-harddisk.svg', + 'D': 'drive-harddisk.svg', + 'n': 'drive-harddisk.svg', + 'N': 'drive-harddisk.svg', + 'u': 'system.svg', + 'U': 'system.svg'} + try: + f_name = icons[component] + except KeyError: + return "" + + return icon_to_use(home, f_name) + + +def net_icon(home, ul, dl): + f_name = "knemo-monitor-transmit.svg" + return icon_to_use(home, f_name) + + +def icon_to_use(home, f_name): + icon_custom = home + '/.local/share/psuinfo/' + f_name + icon_default = "/usr/share/icons/MB-Mango-Suru-GLOW/devices/16/" + f_name + if os.path.isfile(icon_custom): + return icon_custom + else: + return icon_default + + +if __name__ == "__main__": + main() diff --git a/bin/executors/wifi-name b/bin/executors/wifi-name new file mode 100755 index 0000000..06a45c8 --- /dev/null +++ b/bin/executors/wifi-name @@ -0,0 +1,28 @@ +#!/bin/sh + +# This script displays battery icon according to the charge level and charging state + +# Author: Piotr Miller +# e-mail: nwg.piotr@gmail.com +# Website: http://nwg.pl +# Project: https://github.com/nwg-piotr/tint2-executors +# Icon by @edskeye + +# Dependencies: `wireless_tools` +# Arguments: [-N] ("Wi-Fi: " instead of icon) | [-M'custom name'] +IWGETID="sudo /sbin/iwgetid" +NAME="none" + +wifi=$($IWGETID | awk -F '"' '{ print $2 }') +if [[ ! -z "$wifi" ]]; then + NAME="$wifi" +fi + +if [[ $1 == -N* ]]; then + echo "Wi-Fi: $NAME" +elif [[ $1 == -M* ]]; then + echo "$(echo $1 | cut -c3-) $NAME" +else + echo /usr/share/icons/MB-Mango-Suru-GLOW/devices/16/network-wireless.svg + echo " ${NAME}" +fi diff --git a/bin/i3-exit b/bin/i3-exit new file mode 100755 index 0000000..b942ab2 --- /dev/null +++ b/bin/i3-exit @@ -0,0 +1,24 @@ +#!/bin/bash +rofi_command="rofi -theme blackpearl/i3exit.rasi" + +NO="ﰸ" +YES="" + +options="$YES\n$NO" +chosen="$(echo -e "$options" | $rofi_command -dmenu -selected-row 1)" +case $chosen in + "$YES") + # take wallpaper.sh down with you + for pid in $(cat /tmp/wallpaper.pid); do + # sending all term signals. hopefully one of them will work! + kill -15 $pid + kill -1 $pid + kill -9 $pid + done + rm /tmp/wallpaper.pid + i3-msg exit + ;; + "$NO") + exit 0 + ;; +esac diff --git a/bin/i3-scrot b/bin/i3-scrot new file mode 100755 index 0000000..27e60bd --- /dev/null +++ b/bin/i3-scrot @@ -0,0 +1,80 @@ +#!/bin/sh +# /usr/bin/i3-scrot +# +# simple screenshot-script using scrot for manjaro-i3 by oberon@manjaro.org + +_conf=$HOME/.config/i3-scrot.conf + +if ! [ -f $_conf ]; then + echo "scrot_dir=$(xdg-user-dir PICTURES)" > $_conf +fi + +source $_conf + +if ! [ -d $scrot_dir ]; then + mkdir -p $scrot_dir +fi + +if ! [[ -z "$2" ]]; then + cmd="scrot -d $2" +else + cmd='scrot' +fi + +case "$1" in + --desk|-d|$NULL) + cd $scrot_dir + $cmd && + sleep 1 && + notify-send "screenshot has been saved in $scrot_dir" + ;; + --window|-w) + cd $scrot_dir + $cmd -u && + sleep 1 && + notify-send "screenshot has been saved in $scrot_dir" + ;; + --select|-s) + cd $scrot_dir + notify-send 'select an area for the screenshot' & + $cmd -s && + sleep 1 && notify-send "screenshot has been saved in $scrot_dir" + ;; + --help|-h) + echo " +available options: +-d | --desk full screen +-w | --window active window +-s | --select selection +-h | --help display this information + +The -d or -w options can be used with a delay +by adding the number of seconds, like for example: +'i3-scrot -w 5' + +Default option is 'full screen'. + +The file destination can be set in ${_conf}. +Default is $scrot_dir +" + ;; + *) + echo " +== ! i3-scrot: missing or wrong argument ! == + +available options: +-d | --desk full screen +-w | --window active window +-s | --select selection +-h | --help display this information + +Default option is 'full screen'. + +The file destination can be set in ${_conf}. +Default is $scrot_dir +" + + exit 2 +esac + +exit 0 diff --git a/bin/i3lock-blur b/bin/i3lock-blur new file mode 100755 index 0000000..1156bcc --- /dev/null +++ b/bin/i3lock-blur @@ -0,0 +1,8 @@ +#!/bin/bash +TMPBG=/tmp/screen.png +LOCK=~/.round.face +RES=$(xrandr | grep 'current' | sed -E 's/.*current\s([0-9]+)\sx\s([0-9]+).*/\1x\2/') + +ffmpeg -f x11grab -video_size $RES -y -i $DISPLAY -i $LOCK -filter_complex "boxblur=5:1,overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2" -vframes 1 $TMPBG -loglevel quiet +i3lock -u -i $TMPBG +rm $TMPBG diff --git a/bin/i3lock-fancy b/bin/i3lock-fancy new file mode 100755 index 0000000..0ad7e9c --- /dev/null +++ b/bin/i3lock-fancy @@ -0,0 +1,60 @@ +#! /bin/bash + +CACHE=$HOME/.cache/i3lockblur +TMPBG=$CACHE/screen.png +NOW=$(date +'%d %b %Y') +FACE=~/.face +USER=$CACHE/face.png +RES=$(xrandr | grep 'current' | sed -E 's/.*current\s([0-9]+)\sx\s([0-9]+).*/\1x\2/') + +if [[ ! -d $CACHE ]]; then + mkdir -p $CACHE +fi + +convert $FACE -resize 100x100 -alpha set \( \ + +clone -distort DePolar 0 -virtual-pixel HorizontalTile \ + -background None -distort Polar 0\ + \) -compose Dst_In -composite -trim +repage $USER + +ffmpeg -f x11grab -video_size $RES -y -i $DISPLAY -i $USER \ + -filter_complex "boxblur=7:15,overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2" \ + -vframes 1 $TMPBG -loglevel quiet + +slowfade () { + dis=$(echo -n "$DISPLAY" | tr -c '[:alnum:]' _) + ifc='com.github.chjj.compton' + obj='/com/github/chjj/compton' + if [[ "$1" == "start" ]]; then + dbus-send --print-reply --dest=$ifc.$dis \ + $obj $ifc.opts_set string:fade_in_step double:0.02 + dbus-send --print-reply --dest=$ifc.$dis \ + $obj $ifc.opts_set string:fade_out_step double:0.02 + else + dbus-send --print-reply --dest=$ifc.$dis \ + $obj $ifc.opts_set string:fade_in_step double:0.1 + dbus-send --print-reply --dest=$ifc.$dis \ + $obj $ifc.opts_set string:fade_out_step double:0.1 + fi +} + +FG_COLOR=fefefeff #fefefeff +RING_COLOR=31313aff #31313aff +WRONG_COLOR=f82a11aa #f82a11aa +HLIGHT_COLOR=ffbf00ff #ffbf00ff +VERIF_COLOR=fefefe66 #fefefe66 + +slowfade start +i3lock -n --force-clock -i $TMPBG \ + --indpos="w/2:h/2" --timepos="w/2:h/2-170" --datepos="w/2:h/2-100" --greeterpos="w/2:h/2-70" \ + --insidevercolor=$VERIF_COLOR --insidewrongcolor=$WRONG_COLOR --insidecolor=fefefe00 \ + --ringvercolor=$VERIF_COLOR --ringwrongcolor=$WRONG_COLOR --ringcolor=$RING_COLOR \ + --keyhlcolor=$HLIGHT_COLOR --bshlcolor=$HLIGHT_COLOR --separatorcolor=00000000 \ + --datecolor=$FG_COLOR --timecolor=$FG_COLOR --greetercolor=$FG_COLOR \ + --timestr="%H" --timesize=70 \ + --datestr="%M" --datesize=70 \ + --greetertext="$NOW" --greetersize=25\ + --line-uses-inside --radius 50 --ring-width 2 --indicator \ + --veriftext="" --wrongtext="" --noinputtext="" \ + --clock --date-font="Roboto" --time-font="Roboto" +sleep 1 +slowfade end diff --git a/bin/i3suspend b/bin/i3suspend new file mode 100755 index 0000000..373ff43 --- /dev/null +++ b/bin/i3suspend @@ -0,0 +1,7 @@ +#! /bin/sh + +i3lock-blur & +sleep 3 +dbus-send --system --print-reply --dest="org.freedesktop.UPower" /org/freedesktop/UPower org.freedesktop.UPower.Suspend +exit + diff --git a/bin/is_installed b/bin/is_installed new file mode 100755 index 0000000..70df65a --- /dev/null +++ b/bin/is_installed @@ -0,0 +1,123 @@ +#! /bin/bash +# +# is_installed - a script to find if a package +# is currently installed on Slackware and derivates + +# var +SHOWHELP=69 +E_NOPKGFOUND=70 +E_NOARGS=71 +PKGS_PATH="/var/log/packages" + +PROG=$(basename $0) + + +# colors +RED='\033[1;31m' +ORANGE='\033[1;33m' +GREEN='\033[1;32m' +MAGENTA='\033[1;35m' +NC='\033[0m' + +function search_file () { + SEARCH=$1 + if [ -z $1 ]; then + #we don't have a string to search + echo -e "Usage: ${MAGENTA}$PROG ${NC}[file-search] ${GREEN}< filename >" + echo -e "${RED}exiting${NC}" + exit $E_NOARGS + fi + finding=$(grep -Hi "$SEARCH" ${PKGS_PATH}/*) + if [[ ! -z $finding ]]; then + old_IFS=$IFS + IFS=$'\n' + old_pkgname="" + for line in $finding; do + pkgname=$(echo $line | cut -d":" -f 1) + match=$(echo $line | cut -d":" -f 2) + if [[ $pkgname != $old_pkgname ]]; then + echo -e "${ORANGE}$(basename $pkgname)${NC}" + fi + old_pkgname=$pkgname + echo -en "\t${GREEN}$match${NC}\n" + done + IFS=${old_IFS} + else + echo -e "${ORANGE}no match for pattern ${GREEN}'$SEARCH' ${ORANGE}found" + echo -e "${RED}exiting${NC}" + exit $E_NOPKGFOUND + fi +} + +function search_package () { + SEARCH=$1 + if [ -z $1 ]; then + #we don't have a string to search + echo -e "Usage: ${MAGENTA}$PROG ${GREEN}" + echo -e "${RED}exiting${NC}" + exit $E_NOARGS + fi + finding=$(/bin/ls -1 $PKGS_PATH |grep -i "$SEARCH") + if [[ ! -z $finding ]]; then + echo -en "${GREEN}$finding\n" + echo -e "${NC}" + else + echo -e "${ORANGE}no package matching ${GREEN}'$SEARCH' ${ORANGE}found" + echo -e "${RED}exiting${NC}" + exit $E_NOPKGFOUND + fi +} + +function info () { + SEARCH=$1 + if [ -z $1 ]; then + #we don't have a string to search + echo -e "Usage: ${MAGENTA}$PROG ${ORANGE}info ${GREEN}" + echo -e "${RED}exiting${NC}" + exit $E_NOARGS + fi + finding=$(/bin/ls -1 $PKGS_PATH |grep -i "$SEARCH") + if [[ ! -z $finding ]]; then + less $PKGS_PATH/$finding + else + echo -e "${ORANGE}no package matching ${GREEN}'$SEARCH' ${ORANGE}found" + echo -e "${RED}exiting${NC}" + exit $E_NOPKGFOUND + fi +} + +function help () { + echo + echo -e "${MAGENTA}$PROG${NC} -\tSearch for installed packages in the system" + echo -e "\t\tand show which package contains a specific file." + echo -e "${GREEN}USAGE:" + echo -e "\t${MAGENTA}$PROG ${ORANGE}[ file-search ] [ help ] ${GREEN}< item >" + echo -e "\t${MAGENTA}$PROG ${GREEN}${NC} - Search between all installed packages for ${GREEN}item${NC}." + echo -e "\t${MAGENTA}$PROG ${ORANGE}file-search ${GREEN}${NC} - Search for ${GREEN}item${NC} inside every package installed." + echo -e "\t${MAGENTA}$PROG ${ORANGE}help${NC} - Show this help and exit." + echo -e "${NC}" +} +# controlla se vengono passati parametri +if [ -z $1 ]; then + help + exit $E_NOARGS +else + case $1 in + "file-search" ) + search_file $2 + ;; + "info" ) + info $2 + ;; + "help" ) + help + exit $SHOWHELP + ;; + * ) + search_package $1 + ;; + esac +fi + + +exit diff --git a/bin/vt-color-scheme.py b/bin/vt-color-scheme.py new file mode 100644 index 0000000..de7116d --- /dev/null +++ b/bin/vt-color-scheme.py @@ -0,0 +1,59 @@ +#!/usr/bin/env python +# -*- coding: utf-8 -*- +# +# Usage: +# 1. Save as `vt-color-scheme.py` +# 2. Make executable +# 3. Go to https://terminal.sexy and make your own color scheme +# 4. Export as JSON (easier to work with) and edit TANGO_SCHEME +# with the colors you chose +# 5. Run this script (redirect to text file if it's easier for you) +# 6. Paste the output as boot option in Lilo / Elilo etc. + +KERNEL_PARAMS = ['vt.default_red', 'vt.default_grn', 'vt.default_blu', ] + +# MATERIAL DARK theme +# https://material-ui.com/customization/default-theme/ +TANGO_SCHEME = [ + "#303030", + "#d32f2f", + "#388e3c", + "#f57c00", + "#303f9f", + "#c51162", + "#1976d2", + "#bdbdbd", + "#424242", + "#e57373", + "#81c784", + "#ffb74d", + "#7986cb", + "#ff4081", + "#64b5f6", + "#f5f5f5" + ] + +def color_scheme_to_rgb_channel_data(color_scheme): + """ + [ '#r1g1b1', '#r2g2b2', ... ] => [ [r1, r2, ...], [g1, g2, ...], [b1, b2, ...], ] + """ + + def split_to_rgb(color): + # rgb str -> [red, green, blue] + hex_value = int(color, 16) + return [hex_value >> 16 & 255, hex_value >> 8 & 255, hex_value & 255] + + return zip(*[split_to_rgb(color.strip('#')) for color in color_scheme]) + + +def prepare_param(param, channel_data): + return '{param}={values}'.format(param=param, values=','.join(hex(byte) for byte in channel_data)) + + +def main(colors): + print(' '.join(prepare_param(param, channel) for param, channel in \ + zip(KERNEL_PARAMS, color_scheme_to_rgb_channel_data(colors)))) + + +if __name__ == '__main__': + main(TANGO_SCHEME) diff --git a/bin/wallpaper.sh b/bin/wallpaper.sh new file mode 100755 index 0000000..6369a65 --- /dev/null +++ b/bin/wallpaper.sh @@ -0,0 +1,42 @@ +#!/bin/bash +PIDFILE=${PIDFILE:-/tmp/wallpaper.pid} + +trap "rm -f $PIDFILE" SIGUSR1 + +# set background function (requires input) +function wpapers () { + if [[ -f $1 ]]; then + # We have a single file as input + feh --bg-fill --no-fehbg $1 + exit 0 + elif [[ -d $1 ]]; then + # directory as input + while true; do + BGIMG=$(find $1 -type f -print | shuf -n1) + feh --bg-fill --no-fehbg $BGIMG + sleep 5m + done + fi +} + +if [[ -f $PIDFILE ]]; then + # PIDFILE exists, so I guess there's already an instance running + # let's kill it and run again + kill $(cat $PIDFILE) > /dev/null 2>&1 + rm $PIDFILE +fi + +# create PIDFILE +echo $$ > $PIDFILE + +## MAIN ## +# do we have input? +if [[ ! -z $1 ]]; then + WPAPERS=$1 +else + # No input. We'll use our predefined directory + WPAPERS="/home/danix/Pictures/wallpapers/black" +fi + +wpapers $WPAPERS + diff --git a/compton.conf b/compton.conf new file mode 100644 index 0000000..14242ba --- /dev/null +++ b/compton.conf @@ -0,0 +1,55 @@ +shadow = true; +no-dnd-shadow = true; +no-dock-shadow = true; +clear-shadow = true; +shadow-radius = 7; +shadow-offset-x = -7; +shadow-offset-y = -7; +shadow-opacity = 0.7; +shadow-red = 0.0; +shadow-green = 0.0; +shadow-blue = 0.0; +shadow-exclude = [ "name = 'Notification'", "class_g = 'Conky'","class_g = 'qlocktwo'", "class_g ?= 'Notify-osd'", "class_g = 'Cairo-clock'", "argb && (_NET_WM_WINDOW_TYPE@:a *= 'MENU' || _NET_WM_WINDOW_TYPE@:a *= 'COMBO')" ]; +shadow-ignore-shaped = false; +xinerama-shadow-crop = false; +menu-opacity = 0.8; +inactive-opacity = 0.8; +active-opacity = 1.0; +frame-opacity = 0.7; +inactive-opacity-override = false; +alpha-step = 0.06; +inactive-dim = 0.0; +blur-kern = "3x3box"; +blur-background-exclude = [ "window_type = 'dock'", "window_type = 'desktop'", "(_NET_WM_WINDOW_TYPE@:a *= 'MENU' || _NET_WM_WINDOW_TYPE@:a *= 'COMBO')" ]; +fading = true; +fade-in-step = 0.03; +fade-out-step = 0.03; +fade-exclude = [ ]; +backend = "xrender"; +mark-wmwin-focused = true; +mark-ovredir-focused = true; +detect-rounded-corners = true; +detect-client-opacity = true; +refresh-rate = 0; +vsync = "none"; +dbe = false; +paint-on-overlay = true; +focus-exclude = [ "class_g = 'Cairo-clock'" ]; +detect-transient = true; +detect-client-leader = true; +invert-color-include = [ ]; +glx-copy-from-front = false; +glx-swap-method = "undefined"; +wintypes : +{ + tooltip : + { + fade = true; + shadow = false; + opacity = 0.75; + focus = true; + }; +}; +blur-background = true; +blur-background-frame = true; +no-fading-openclose = false; diff --git a/conky/qlocktwo.conkyrc b/conky/qlocktwo.conkyrc new file mode 100644 index 0000000..034795b --- /dev/null +++ b/conky/qlocktwo.conkyrc @@ -0,0 +1,50 @@ +conky.config = { + background = true, + own_window = true, + own_window_type = 'override', + own_window_transparent = true, + own_window_hints = 'undecorated,sticky,skip_taskbar,skip_pager,below', + own_window_argb_visual = true, + own_window_argb_value = 0, + own_window_class = 'qlocktwo', + own_window_title = 'qlocktwo', + alignment = 'top_left', + gap_x = 0, + gap_y = 30, + use_xft = true, + font = 'Roboto2012892015:size=18', + xftalpha = 0.1, + update_interval = 15.0, + uppercase = true, + double_buffer = true, + draw_shades = false, + -- default_shade_color = '000000', + default_color = 'ffbf00', + color1 = '1d1d1d' +-- #2d2d2d +-- #4A2B45 +-- #382536 +-- #3F2E2F +-- #000000 +}; + +conky.text = [[ + ${alignc}${color}I T ${color1}L ${color}I S ${color1}A S T I M E + ${alignc}${if_match ${exec date +'%M'} < 35}${if_match ${exec date +'%M'} >= 15}${if_match ${exec date +'%M'} < 20}${color}${endif}${endif}A ${color1}C ${if_match ${exec date +'%M'} >= 15}${if_match ${exec date +'%M'} < 20}${color}${endif}${endif}Q U A R T E R ${color1}D C + ${alignc}${if_match ${exec date +'%M'} >= 20}${if_match ${exec date +'%M'} < 30}${color}${endif}${endif}T W E N T Y ${if_match ${exec date +'%M'} >= 25}${if_match ${exec date +'%M'} < 30}${color}${endif}${else}${color1}${endif}${if_match ${exec date +'%M'} >= 5}${if_match ${exec date +'%M'} < 10}${color}${endif}${endif}F I V E ${color1}X + ${alignc}${if_match ${exec date +'%M'} >= 30}${if_match ${exec date +'%M'} < 35}${color}${endif}${endif}H A L F ${color1}B ${if_match ${exec date +'%M'} >= 10}${if_match ${exec date +'%M'} < 15}${color}${endif}${endif}T E N ${color1}F T O + ${alignc}${else}${if_match ${exec date +'%M'} >= 45}${if_match ${exec date +'%M'} < 50}${color}${endif}${endif}A ${color1}C ${if_match ${exec date +'%M'} >= 45}${if_match ${exec date +'%M'} < 50}${color}${endif}${endif}Q U A R T E R ${color1}D C + ${alignc}${if_match ${exec date +'%M'} >= 35}${if_match ${exec date +'%M'} < 45}${color}${endif}${endif}T W E N T Y ${if_match ${exec date +'%M'} < 40}${if_match ${exec date +'%M'} >= 35}${color}${endif}${else}${color1}${endif}${if_match ${exec date +'%M'} >= 55}${color}${endif}F I V E ${color1}X + ${alignc}H A L F B ${if_match ${exec date +'%M'} >= 50}${if_match ${exec date +'%M'} < 55}${color}${endif}${endif}T E N ${color1}F ${color}T O${color1} + ${alignc}${endif}${if_match ${exec date +'%M'} < 35}${if_match ${exec date +'%M'} >= 5}${color}${endif}${endif}P A S T ${color1}E R U ${if_match ${exec date +'%M'} < 35}${if_match ${exec date +'%I'} == 9}${color}${else}${color1}${endif}N I N E + ${alignc}${if_match ${exec date +'%I'} == 1}${color}${else}${color1}${endif}O N E ${if_match ${exec date +'%I'} == 6}${color}${else}${color1}${endif}S I X ${if_match ${exec date +'%I'} == 3}${color}${else}${color1}${endif}T H R E E + ${alignc}${if_match ${exec date +'%I'} == 4}${color}${else}${color1}${endif}F O U R ${if_match ${exec date +'%I'} == 5}${color}${else}${color1}${endif}F I V E ${if_match ${exec date +'%I'} == 2}${color}${else}${color1}${endif}T W O + ${alignc}${if_match ${exec date +'%I'} == 8}${color}${else}${color1}${endif}E I G H T ${if_match ${exec date +'%I'} == 11}${color}${else}${color1}${endif}E L E V E N + ${alignc}${if_match ${exec date +'%I'} == 7}${color}${else}${color1}${endif}S E V E N ${if_match ${exec date +'%I'} == 12}${color}${else}${color1}${endif}T W E L V E + ${alignc}${if_match ${exec date +'%I'} == 10}${color}${else}${color1}${endif}T E N ${else}${if_match ${exec date +'%I'} == 8}${color}${else}${color1}${endif}N I N E + ${alignc}${if_match ${exec date +'%I'} == 12}${color}${else}${color1}${endif}O N E ${if_match ${exec date +'%I'} == 5}${color}${else}${color1}${endif}S I X ${if_match ${exec date +'%I'} == 2}${color}${else}${color1}${endif}T H R E E + ${alignc}${if_match ${exec date +'%I'} == 3}${color}${else}${color1}${endif}F O U R ${if_match ${exec date +'%I'} == 4}${color}${else}${color1}${endif}F I V E ${if_match ${exec date +'%I'} == 1}${color}${else}${color1}${endif}T W O + ${alignc}${if_match ${exec date +'%I'} == 7}${color}${else}${color1}${endif}E I G H T${if_match ${exec date +'%I'} == 10}${color}${else}${color1}${endif} E L E V E N + ${alignc}${if_match ${exec date +'%I'} == 6}${color}${else}${color1}${endif}S E V E N${if_match ${exec date +'%I'} == 11}${color}${else}${color1}${endif} T W E L V E + ${alignc}${if_match ${exec date +'%I'} == 9}${color}${else}${color1}${endif}T E N ${endif}${color1}S E ${if_match ${exec date +'%M'} < 5}${color}${endif}O C L O C K +]] diff --git a/etc/bash_completion.d/is_installed.bash-completion b/etc/bash_completion.d/is_installed.bash-completion new file mode 100644 index 0000000..183bc75 --- /dev/null +++ b/etc/bash_completion.d/is_installed.bash-completion @@ -0,0 +1,41 @@ +# bash completion for is_installed -*- shell-script -*- + +_is_installed() +{ + local cur prev words cword + _init_completion -n = || return + + local split=false + + local i action + for (( i=1; i<${#words[@]}; i++ )); do + if [[ "${words[i]}" != -* ]]; then + action="${words[i]}" + break + fi + done + + case "$action" in + help) + # no argument required + return + ;; + info) + COMPREPLY=( $(cd /var/log/packages; compgen -f -- "$cur") ) + return + ;; + file-search) + # argument required but no way to help + return + ;; + *) + COMPREPLY+=( $(compgen -W 'help info file-search' -- "$cur") ) + return + ;; + esac + +} + +complete -F _is_installed is_installed + +# ex: filetype=sh diff --git a/etc/issue.blackpearl b/etc/issue.blackpearl new file mode 100644 index 0000000..c979b42 --- /dev/null +++ b/etc/issue.blackpearl @@ -0,0 +1,22 @@ + + + .. .. .. .. +. uW8" x .d88" < .z@8"` x .d88" +`t888 5888R !@88E .d`` .u . 5888R + 8888 . '888R u . '888E u @8Ne. .u .u u .d88B :@8c '888R + 9888.z88N 888R us888u. .udR88N 888E u@8NL %8888:u@88N ud8888. us888u. ="8888f8888r 888R + 9888 888E 888R .@88 "8888" <888'888k 888E`"88*" `888I 888. :888'8888. .@88 "8888" 4888>'88" 888R + 9888 888E 888R 9888 9888 9888 'Y" 888E .dN. 888I 888I d888 '88%" 9888 9888 4888> ' 888R + 9888 888E 888R 9888 9888 9888 888E~8888 888I 888I 8888.+" 9888 9888 4888> 888R + 9888 888E 888R 9888 9888 9888 888E '888& uW888L 888' 8888L 9888 9888 .d888L .+ 888R +.8888 888" .888B . 9888 9888 ?8888u../ 888E 9888. '*88888Nu88P '8888c. .+ 9888 9888 ^"8888*" .888B . + `%888*%" ^*888% "888*""888" "8888P' '"888*" 4888" ~ '88888F` "88888% "888*""888" "Y" ^*888% + "` "% ^Y" ^Y' "P' "" "" 888 ^ "YP' ^Y" ^Y' "% + *8E + '8> + " + +Ahoy!! Welcome aboard \n running \s v. \r for \m +Today is \d and this is \l + + diff --git a/etc/issue.buildbox b/etc/issue.buildbox new file mode 100644 index 0000000..ef691bd --- /dev/null +++ b/etc/issue.buildbox @@ -0,0 +1,18 @@ + + + .. . .. .. .. +. uW8" @88> x .d88" dF . uW8" +`t888 x. . %8P 5888R '88bu. `t888 u. uL .. + 8888 . .@88k z88u . '888R '*88888bu 8888 . ...ue888b .@88b @88R + 9888.z88N ~"8888 ^8888 .@88u 888R ^"*8888N 9888.z88N 888R Y888r '"Y888k/"*P + 9888 888E 8888 888R ''888E` 888R beWE "888L 9888 888E 888R I888> Y888L + 9888 888E 8888 888R 888E 888R 888E 888E 9888 888E 888R I888> 8888 + 9888 888E 8888 888R 888E 888R 888E 888E 9888 888E 888R I888> `888N + 9888 888E 8888 ,888B . 888E 888R 888E 888F 9888 888E u8888cJ888 .u./"888& +.8888 888" "8888Y 8888" 888& .888B . .888N..888 .8888 888" "*888*P" d888" Y888*" + `%888*%" `Y" 'YP R888" ^*888% `"888*"" `%888*%" 'Y" ` "Y Y" + "` "" "% "" "` +You are on BUILDBOX!! +We are running \s v. \r for \m +Today is \d + diff --git a/etc/profile.d/blackpearl.sh b/etc/profile.d/blackpearl.sh new file mode 100644 index 0000000..d503bf8 --- /dev/null +++ b/etc/profile.d/blackpearl.sh @@ -0,0 +1,57 @@ +#! /bin/bash +# Print info and a logo for interactive shells: + +function OUTPUT () { + # Define our variables + HOST=$(echo $HOSTNAME |cut -d"." -f1) + K_v=$(uname -r) + K_ar=$(uname -m) + OS=$(cat /etc/slackware-version) + LOAD=$(uptime |cut -d " " -f12-) + PKGS=$(/bin/ls -1 /var/log/packages/ |wc -l) + DE=$(env |grep DESKTOP_SESSION |cut -d "/" -f5) + + # Define or colors + CYAN="\e[1;36m" + ORANGE="\e[1;33m" + MAGENTA="\e[1;35m" + BLUE="\e[1;34m" + RED="\e[1;31m" + GREEN="\e[1;32m" + WHITE="\e[1;37m" + CLEAR="\e[0;0m" + + USER_COLOR=$GREEN + if [ ${UID} -eq 0 ] + then + USER_COLOR=$RED + fi + + + echo -e "$ORANGE" + echo -e " . ${CYAN}/> /${ORANGE}" + echo -e " oW ${CYAN}/ /${ORANGE}" + echo -e " c0; .... .;cdo. ${CYAN}/ /${ORANGE}" + echo -e " ,M, .;dx. ${CYAN}/ /\t ${MAGENTA}KERNEL:\t${WHITE}$K_v - $K_ar${ORANGE}" + echo -e " xW x . .'ldc. 'Wd ${CYAN}/ /\t ${MAGENTA}PACKAGES:\t${WHITE}${PKGS}${ORANGE}" + echo -e " .Ml.d.:; .;kXo. .. ${CYAN}/ /\t ${MAGENTA}DE:\t\t${WHITE}${DE}${ORANGE}" + echo -e " .0xdxxd' ${CYAN}/ / ${ORANGE}" + echo -e " .. ${CYAN}/ {generic}";*/ + drun-display-format: "{icon} {name}"; + display-drun: "Apps"; + show-icons: true; + icon-theme: "breeze-dark"; + hide-scrollbar: true; + cycle: true; + fullscreen: true; + sidebar-mode: false; + terminal: "urxvt"; + ssh-client: "ssh"; + ssh-command: "{terminal} -e {ssh-client} {host}"; + run-command: "{cmd}"; + run-shell-command: "{terminal} -e {cmd}"; + cache-dir: "/home/danix/.cache/"; +} diff --git a/rofi/blackpearl/utilsmenu.rasi b/rofi/blackpearl/utilsmenu.rasi new file mode 100644 index 0000000..ecfd069 --- /dev/null +++ b/rofi/blackpearl/utilsmenu.rasi @@ -0,0 +1,48 @@ +/* + * BLACKPEARL appsmenu rofi theme + * tested on a 1366x768 screen + */ + +/* IMPORTS */ +@import "shared/settings.rasi" +@import "shared/reset.rasi" + + +#scrollbar { + enabled: false; +} +#window { + font: "Hurmit Nerd Font Mono 75"; + fullscreen: true; + transparency: "real"; + background-color: @bg-trans; +} +#mainbox { + children: [ listview ]; + border: 0; + padding: 0; +} +#listview { + columns: 3; + lines: 1; + expand: false; + spacing: 90px; + padding: 284px 453px; + orientation: horizontal; +} +#element { + border: 1; + border-radius: 24; + border-color: @accent; + text-color: @accent; + background-color: @bg; + orientation: vertical; + padding: -30 60 30; + horizontal-align: 0.5; + vertical-align: 0.5; +} +#element.selected { + text-color: @bg; + background-color: @accent; +} + diff --git a/tint2/.i3status.tint2rc.un~ b/tint2/.i3status.tint2rc.un~ new file mode 100644 index 0000000000000000000000000000000000000000..27567c265e833d7916ce4506ae18ca4411dfb832 GIT binary patch literal 4994 zcmeI0ziSjh6vtisfyxF@v+-r*^`GHJ5 zfAR9&my5@9*O%UJZ1=ame!47QAGP03zmoH(N&D%2LaZl*kcj2Xi`G0DhK}&*4f?3% za?!%kER}K63LW0Jy&m%dYImufQJyw^NASLEhK?8W#V$V4gcnddqM1Jkvh-oblC3CT z4}5C-w4p!VfbaI;yAsR-n*+m!_rgf$&B4J8&RS&c1ZSa54R7iSQ`T+pu3+yQH1#Sq zWiDs004&EXwH$uit6I;_6JN0=e0nA z3`IkTV}=GznOa<+ftS%BCQl9HGz?@GCt1Yegn2PbBPU5VW&E?`94i_yJzUV@1wcl1 zsDVNgrXCld*wLZrg8Uq;C?Ws*G2}-riFsmH3mFhmSafjA5Ss50xa;~U; zI_1KZ`2xk-qc~w;q9_ig7&j22sJMw8Lj|f(X9FsB%c$5qTPkGQgFWOA8_93z(DMb# q0Hi277O`XKKo#n2K*zqK!y5jL_;o88{4*WHGGn2rIxFz;@$fqxI}ES@ literal 0 HcmV?d00001 diff --git a/tint2/i3status.tint2rc b/tint2/i3status.tint2rc new file mode 100644 index 0000000..d218030 --- /dev/null +++ b/tint2/i3status.tint2rc @@ -0,0 +1,387 @@ +#---- Generated by tint2conf 4042 ---- +# See https://gitlab.com/o9000/tint2/wikis/Configure for +# full documentation of the configuration options. +#------------------------------------- +# Gradients +#------------------------------------- +# Backgrounds +# Background 1: Active desktop name, Active task, Default task, Executor, Inactive desktop name, Systray +rounded = 0 +border_width = 2 +border_sides = T +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #ffbf00 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 2: Panel, Tooltip +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 79 +border_color = #ffbf00 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 3: +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 0 +border_color = #ffbf00 0 +gradient_id = 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +#------------------------------------- +# Panel +panel_items = EEEEEEEEEFS +panel_size = 100% 25 +panel_margin = 0 25 +panel_padding = 2 0 8 +panel_background_id = 2 +wm_menu = 1 +panel_dock = 0 +panel_pivot_struts = 0 +panel_position = top center horizontal +panel_layer = bottom +panel_monitor = all +panel_shrink = 0 +autohide = 0 +autohide_show_timeout = 0 +autohide_hide_timeout = 0.5 +autohide_height = 2 +strut_policy = none +panel_window_name = tint2-i3status +disable_transparency = 0 +mouse_effects = 1 +font_shadow = 0 +mouse_hover_icon_asb = 100 0 10 +mouse_pressed_icon_asb = 100 0 0 +scale_relative_to_dpi = 0 +scale_relative_to_screen_height = 0 + +#------------------------------------- +# Taskbar +taskbar_mode = multi_desktop +taskbar_hide_if_empty = 0 +taskbar_padding = 0 0 4 +taskbar_background_id = 0 +taskbar_active_background_id = 0 +taskbar_name = 1 +taskbar_hide_inactive_tasks = 0 +taskbar_hide_different_monitor = 0 +taskbar_hide_different_desktop = 0 +taskbar_always_show_all_desktop_tasks = 1 +taskbar_name_padding = 4 2 +taskbar_name_background_id = 1 +taskbar_name_active_background_id = 1 +taskbar_name_font = Roboto2012892015 Bold 8 +taskbar_name_font_color = #e3e3e3 100 +taskbar_name_active_font_color = #ffffff 100 +taskbar_distribute_size = 1 +taskbar_sort_order = mru +task_align = left + +#------------------------------------- +# Task +task_text = 1 +task_icon = 0 +task_centered = 1 +urgent_nb_of_blink = 100000 +task_maximum_size = 150 34 +task_padding = 3 2 0 +task_font = Roboto2012892015 10 +task_tooltip = 1 +task_thumbnail = 1 +task_thumbnail_size = 210 +task_font_color = #ffffff 100 +task_active_font_color = #ffbf00 100 +task_iconified_font_color = #b3b3b3 100 +task_background_id = 1 +task_active_background_id = 1 +task_urgent_background_id = 0 +task_iconified_background_id = 0 +mouse_left = toggle_iconify +mouse_middle = none +mouse_right = close +mouse_scroll_up = toggle +mouse_scroll_down = iconify + +#------------------------------------- +# System tray (notification area) +systray_padding = 2 4 4 +systray_background_id = 1 +systray_sort = ascending +systray_icon_size = 24 +systray_icon_asb = 100 0 0 +systray_monitor = 1 +systray_name_filter = + +#------------------------------------- +# Launcher +launcher_padding = 0 0 0 +launcher_background_id = 0 +launcher_icon_background_id = 0 +launcher_icon_size = 0 +launcher_icon_asb = 100 0 0 +launcher_icon_theme_override = 0 +startup_notifications = 0 +launcher_tooltip = 0 + +#------------------------------------- +# Clock +time1_format = +time2_format = +time1_timezone = +time2_timezone = +clock_font_color = #000000 100 +clock_padding = 0 0 +clock_background_id = 0 +clock_tooltip = +clock_tooltip_timezone = +clock_lclick_command = +clock_rclick_command = +clock_mclick_command = +clock_uwheel_command = +clock_dwheel_command = + +#------------------------------------- +# Battery +battery_tooltip = 1 +battery_low_status = 0 +battery_low_cmd = +battery_full_cmd = +battery_font_color = #000000 100 +bat1_format = +bat2_format = +battery_padding = 0 0 +battery_background_id = 0 +battery_hide = 101 +battery_lclick_command = +battery_rclick_command = +battery_mclick_command = +battery_uwheel_command = +battery_dwheel_command = +ac_connected_cmd = +ac_disconnected_cmd = + +#------------------------------------- +# Executor 1 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IU +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 2 +execp = new +execp_command = ~/bin/executors/psuinfo.py -Ia +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 3 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IM +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 4 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IN -W0 +execp_interval = 900 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 5 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IN -W1 +execp_interval = 900 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 6 +execp = new +execp_command = ~/bin/executors/psuinfo.py -Ik +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = ~/bin/executors/inet +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 7 +execp = new +execp_command = ~/bin/slack-updates +execp_interval = 7200 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = ~/bin/slack-updates -n +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 8 +execp = new +execp_command = ~/bin/executors/mail-check -g -u username@domain.com -p yoursupersecretpassword -d "inbox name" +execp_interval = 300 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 9 +execp = new +execp_command = ~/bin/executors/mail-check -g -u other-username@domain2.com -p othersupersecretpassword -d "inbox2 name" +execp_interval = 300 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Tooltip +tooltip_show_timeout = 0.5 +tooltip_hide_timeout = 0.1 +tooltip_padding = 2 2 +tooltip_background_id = 2 +tooltip_font_color = #f5f8f6 100 +tooltip_font = Droid Sans Mono 10 + diff --git a/tint2/i3status.tint2rc~ b/tint2/i3status.tint2rc~ new file mode 100644 index 0000000..56f4a78 --- /dev/null +++ b/tint2/i3status.tint2rc~ @@ -0,0 +1,387 @@ +#---- Generated by tint2conf 4042 ---- +# See https://gitlab.com/o9000/tint2/wikis/Configure for +# full documentation of the configuration options. +#------------------------------------- +# Gradients +#------------------------------------- +# Backgrounds +# Background 1: Active desktop name, Active task, Default task, Executor, Inactive desktop name, Systray +rounded = 0 +border_width = 2 +border_sides = T +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #ffbf00 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 2: Panel, Tooltip +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 79 +border_color = #ffbf00 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 3: +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 0 +border_color = #ffbf00 0 +gradient_id = 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +#------------------------------------- +# Panel +panel_items = EEEEEEEEEFS +panel_size = 100% 25 +panel_margin = 0 25 +panel_padding = 2 0 8 +panel_background_id = 2 +wm_menu = 1 +panel_dock = 0 +panel_pivot_struts = 0 +panel_position = top center horizontal +panel_layer = bottom +panel_monitor = all +panel_shrink = 0 +autohide = 0 +autohide_show_timeout = 0 +autohide_hide_timeout = 0.5 +autohide_height = 2 +strut_policy = none +panel_window_name = tint2-i3status +disable_transparency = 0 +mouse_effects = 1 +font_shadow = 0 +mouse_hover_icon_asb = 100 0 10 +mouse_pressed_icon_asb = 100 0 0 +scale_relative_to_dpi = 0 +scale_relative_to_screen_height = 0 + +#------------------------------------- +# Taskbar +taskbar_mode = multi_desktop +taskbar_hide_if_empty = 0 +taskbar_padding = 0 0 4 +taskbar_background_id = 0 +taskbar_active_background_id = 0 +taskbar_name = 1 +taskbar_hide_inactive_tasks = 0 +taskbar_hide_different_monitor = 0 +taskbar_hide_different_desktop = 0 +taskbar_always_show_all_desktop_tasks = 1 +taskbar_name_padding = 4 2 +taskbar_name_background_id = 1 +taskbar_name_active_background_id = 1 +taskbar_name_font = Roboto2012892015 Bold 8 +taskbar_name_font_color = #e3e3e3 100 +taskbar_name_active_font_color = #ffffff 100 +taskbar_distribute_size = 1 +taskbar_sort_order = mru +task_align = left + +#------------------------------------- +# Task +task_text = 1 +task_icon = 0 +task_centered = 1 +urgent_nb_of_blink = 100000 +task_maximum_size = 150 34 +task_padding = 3 2 0 +task_font = Roboto2012892015 10 +task_tooltip = 1 +task_thumbnail = 1 +task_thumbnail_size = 210 +task_font_color = #ffffff 100 +task_active_font_color = #ffbf00 100 +task_iconified_font_color = #b3b3b3 100 +task_background_id = 1 +task_active_background_id = 1 +task_urgent_background_id = 0 +task_iconified_background_id = 0 +mouse_left = toggle_iconify +mouse_middle = none +mouse_right = close +mouse_scroll_up = toggle +mouse_scroll_down = iconify + +#------------------------------------- +# System tray (notification area) +systray_padding = 2 4 4 +systray_background_id = 1 +systray_sort = ascending +systray_icon_size = 24 +systray_icon_asb = 100 0 0 +systray_monitor = 1 +systray_name_filter = + +#------------------------------------- +# Launcher +launcher_padding = 0 0 0 +launcher_background_id = 0 +launcher_icon_background_id = 0 +launcher_icon_size = 0 +launcher_icon_asb = 100 0 0 +launcher_icon_theme_override = 0 +startup_notifications = 0 +launcher_tooltip = 0 + +#------------------------------------- +# Clock +time1_format = +time2_format = +time1_timezone = +time2_timezone = +clock_font_color = #000000 100 +clock_padding = 0 0 +clock_background_id = 0 +clock_tooltip = +clock_tooltip_timezone = +clock_lclick_command = +clock_rclick_command = +clock_mclick_command = +clock_uwheel_command = +clock_dwheel_command = + +#------------------------------------- +# Battery +battery_tooltip = 1 +battery_low_status = 0 +battery_low_cmd = +battery_full_cmd = +battery_font_color = #000000 100 +bat1_format = +bat2_format = +battery_padding = 0 0 +battery_background_id = 0 +battery_hide = 101 +battery_lclick_command = +battery_rclick_command = +battery_mclick_command = +battery_uwheel_command = +battery_dwheel_command = +ac_connected_cmd = +ac_disconnected_cmd = + +#------------------------------------- +# Executor 1 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IU +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 2 +execp = new +execp_command = ~/bin/executors/psuinfo.py -Ia +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 3 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IM +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 4 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IN -W0 +execp_interval = 900 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 5 +execp = new +execp_command = ~/bin/executors/psuinfo.py -IN -W1 +execp_interval = 900 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 6 +execp = new +execp_command = ~/bin/executors/psuinfo.py -Ik +execp_interval = 3 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = ~/bin/executors/inet +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 7 +execp = new +execp_command = ~/bin/slack-updates +execp_interval = 7200 +execp_has_icon = 1 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = ~/bin/slack-updates -n +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 8 +execp = new +execp_command = ~/bin/executors/mail-check -g -u danixland@gmail.com -p jxibrnebktqbkhmx -d "danixland" +execp_interval = 300 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 9 +execp = new +execp_command = ~/bin/executors/mail-check -g -u it.danilo.macri@gmail.com -p udykutvueszpxfkd -d "danilo.macri" +execp_interval = 300 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 1 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Tooltip +tooltip_show_timeout = 0.5 +tooltip_hide_timeout = 0.1 +tooltip_padding = 2 2 +tooltip_background_id = 2 +tooltip_font_color = #f5f8f6 100 +tooltip_font = Droid Sans Mono 10 + diff --git a/tint2/minima.tint2rc b/tint2/minima.tint2rc new file mode 100644 index 0000000..ee619d2 --- /dev/null +++ b/tint2/minima.tint2rc @@ -0,0 +1,362 @@ +#---- Generated by tint2conf 8aa2 ---- +# See https://gitlab.com/o9000/tint2/wikis/Configure for +# full documentation of the configuration options. +#------------------------------------- +# Gradients +#------------------------------------- +# Backgrounds +# Background 1: Battery +rounded = 0 +border_width = 2 +border_sides = B +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #93e5cc 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 2: +rounded = 0 +border_width = 2 +border_sides = B +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #e3788f 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 3: Urgent task +rounded = 4 +border_width = 1 +border_sides = TBLR +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #aa4400 100 +border_color = #aa7733 100 +background_color_hover = #cc7700 100 +border_color_hover = #aa7733 100 +background_color_pressed = #555555 4 +border_color_pressed = #aa7733 100 + +# Background 4: +rounded = 0 +border_width = 0 +border_sides = TBLR +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #2f343f 100 +border_color = #000000 0 +background_color_hover = #2f343f 100 +border_color_hover = #000000 100 +background_color_pressed = #2f343f 100 +border_color_pressed = #000000 0 + +# Background 5: +rounded = 0 +border_width = 2 +border_sides = B +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #fcd49f 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 6: +rounded = 0 +border_width = 2 +border_sides = B +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #c0b3d1 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 7: Active desktop name, Active task, Clock, Default task, Inactive desktop name, Launcher, Systray +rounded = 0 +border_width = 2 +border_sides = B +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #777777 0 +border_color = #ffbf00 100 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 8: Panel, Tooltip +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 79 +border_color = #ffbf00 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +# Background 9: Launcher icon +rounded = 0 +border_width = 0 +border_sides = +border_content_tint_weight = 0 +background_content_tint_weight = 0 +background_color = #1f1f1f 0 +border_color = #ffbf00 0 +gradient_id = 0 +background_color_hover = #aaaaaa 22 +border_color_hover = #eaeaea 44 +background_color_pressed = #555555 4 +border_color_pressed = #eaeaea 44 + +#------------------------------------- +# Panel +panel_items = TECEE +panel_size = 100% 40 +panel_margin = 0 40 +panel_padding = 2 0 8 +panel_background_id = 8 +wm_menu = 1 +panel_dock = 0 +panel_pivot_struts = 0 +panel_position = bottom center horizontal +panel_layer = bottom +panel_monitor = all +panel_shrink = 0 +autohide = 0 +autohide_show_timeout = 0 +autohide_hide_timeout = 0.5 +autohide_height = 2 +strut_policy = none +panel_window_name = tint2-top +disable_transparency = 0 +mouse_effects = 1 +font_shadow = 0 +mouse_hover_icon_asb = 100 0 10 +mouse_pressed_icon_asb = 100 0 0 +scale_relative_to_dpi = 0 +scale_relative_to_screen_height = 0 + +#------------------------------------- +# Taskbar +taskbar_mode = multi_desktop +taskbar_hide_if_empty = 0 +taskbar_padding = 0 0 4 +taskbar_background_id = 0 +taskbar_active_background_id = 0 +taskbar_name = 1 +taskbar_hide_inactive_tasks = 0 +taskbar_hide_different_monitor = 0 +taskbar_hide_different_desktop = 0 +taskbar_always_show_all_desktop_tasks = 1 +taskbar_name_padding = 4 2 +taskbar_name_background_id = 7 +taskbar_name_active_background_id = 7 +taskbar_name_font = Roboto2012892015 Bold 8 +taskbar_name_font_color = #e3e3e3 100 +taskbar_name_active_font_color = #ffffff 100 +taskbar_distribute_size = 1 +taskbar_sort_order = mru +task_align = left + +#------------------------------------- +# Task +task_text = 1 +task_icon = 0 +task_centered = 1 +urgent_nb_of_blink = 100000 +task_maximum_size = 150 34 +task_padding = 3 2 0 +task_font = Roboto2012892015 10 +task_tooltip = 1 +task_thumbnail = 1 +task_thumbnail_size = 210 +task_font_color = #ffffff 100 +task_active_font_color = #ffbf00 100 +task_iconified_font_color = #b3b3b3 100 +task_background_id = 7 +task_active_background_id = 7 +task_urgent_background_id = 3 +task_iconified_background_id = 0 +mouse_left = toggle_iconify +mouse_middle = none +mouse_right = close +mouse_scroll_up = toggle +mouse_scroll_down = iconify + +#------------------------------------- +# System tray (notification area) +systray_padding = 2 4 4 +systray_background_id = 7 +systray_sort = ascending +systray_icon_size = 24 +systray_icon_asb = 100 0 0 +systray_monitor = 1 +systray_name_filter = + +#------------------------------------- +# Launcher +launcher_padding = 2 4 2 +launcher_background_id = 7 +launcher_icon_background_id = 9 +launcher_icon_size = 24 +launcher_icon_asb = 100 0 0 +launcher_icon_theme = MB-Mango-Suru-GLOW +launcher_icon_theme_override = 0 +startup_notifications = 1 +launcher_tooltip = 1 +launcher_item_app = /usr/share/applications/chromium.desktop +launcher_item_app = /usr/share/applications/pcmanfm-qt.desktop +launcher_item_app = /usr/share/applications/sublime_text.desktop +launcher_item_app = ~/.local/share/applications/telegramdesktop.desktop +launcher_apps_dir = ~/bin/passgen + +#------------------------------------- +# Clock +time1_format = %H:%M +time2_format = %d/%m/%Y +time1_font = Roboto2012892015 10 +time1_timezone = +time2_timezone = +time2_font = Roboto2012892015 10 +clock_font_color = #ffffff 100 +clock_padding = 4 1 +clock_background_id = 7 +clock_tooltip = +clock_tooltip_timezone = +clock_lclick_command = qarma --calendar +clock_rclick_command = +clock_mclick_command = +clock_uwheel_command = +clock_dwheel_command = + +#------------------------------------- +# Battery +battery_tooltip = 1 +battery_low_status = 20 +battery_low_cmd = notify-send "battery low" +battery_full_cmd = +bat1_font = Droid Sans Mono 8 +bat2_font = Droid Sans Mono 8 +battery_font_color = #ffffff 100 +bat1_format = +bat2_format = +battery_padding = 1 0 +battery_background_id = 1 +battery_hide = 101 +battery_lclick_command = +battery_rclick_command = +battery_mclick_command = +battery_uwheel_command = +battery_dwheel_command = +ac_connected_cmd = notify-send "a/c cable connected" +ac_disconnected_cmd = notify-send "a/c cable disconnected" + +#------------------------------------- +# Executor 1 +execp = new +execp_command = ~/bin/weather.sh -i +execp_interval = 7200 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font = Roboto2012892015 10 +execp_font_color = #ffffff 100 +execp_padding = 0 0 +execp_background_id = 7 +execp_centered = 1 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 2 +execp = new +execp_command = ~/bin/executors/caps -c +execp_interval = 1 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font_color = #000000 100 +execp_padding = 0 0 +execp_background_id = 7 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 3 +execp = new +execp_command = ~/bin/executors/caps -n +execp_interval = 1 +execp_has_icon = 1 +execp_cache_icon = 0 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font_color = #000000 100 +execp_padding = 0 0 +execp_background_id = 7 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Executor 4 +execp = new +execp_command = +execp_interval = 0 +execp_has_icon = 0 +execp_cache_icon = 1 +execp_continuous = 0 +execp_markup = 1 +execp_lclick_command = +execp_rclick_command = +execp_mclick_command = +execp_uwheel_command = +execp_dwheel_command = +execp_font_color = #000000 100 +execp_padding = 0 0 +execp_background_id = 0 +execp_centered = 0 +execp_icon_w = 0 +execp_icon_h = 0 + +#------------------------------------- +# Tooltip +tooltip_show_timeout = 0.5 +tooltip_hide_timeout = 0.1 +tooltip_padding = 2 2 +tooltip_background_id = 8 +tooltip_font_color = #f5f8f6 100 +tooltip_font = Droid Sans Mono 10 + diff --git a/tmux/tmux.conf.danix b/tmux/tmux.conf.danix new file mode 100644 index 0000000..55484ea --- /dev/null +++ b/tmux/tmux.conf.danix @@ -0,0 +1,208 @@ +# -- general ------------------------------------------------------------------- +# scrollback size +set -g history-limit 10000 + +## set the default TERM +set -g default-terminal screen +## update the TERM variable of terminal emulator when creating a new session or attaching a existing session +set -g update-environment 'DISPLAY SSH_ASKPASS SSH_AGENT_PID SSH_CONNECTION WINDOWID XAUTHORITY TERM' +## determine if we should enable 256-colour support +if "[[ ${TERM} =~ 256color || ${TERM} == fbterm ]]" 'set -g default-terminal screen-256color' + +setw -g xterm-keys on +# faster command sequences +set -s escape-time 10 +# increase repeat timeout +set -sg repeat-time 600 +set -s focus-events on +# rename window to reflect current program +setw -g automatic-rename on +# renumber windows when a window is closed +set -g renumber-windows on +# set terminal title +set -g set-titles on +# slightly longer pane indicators display time +set -g display-panes-time 800 +# slightly longer status messages display time +set -g display-time 1000 +# redraw status line every 5 seconds +set -g status-interval 5 + +# -- bindings ------------------------------------------------------------------ +# Changing ctrl b to ctrl Space as the command button +unbind C-b +set -g prefix C-Space + +# set first window to index 1 (not 0) to map more to the keyboard layout +set -g base-index 1 +set -g pane-base-index 1 + +# Keep your finger on ctrl, or don't, same result +bind-key C-d detach-client +# bind-key C-p paste-buffer + +# reload tmux config with ctrl + a + r + unbind r + bind-key r \ + source-file ~/.tmux.conf \;\ + display 'Reloaded tmux config.' + +# Vertical splits with v or C-v +unbind g +unbind C-g +bind-key v split-window -h +bind-key C-v split-window -h + +# Horizontal splits with h or C-h +unbind h +unbind C-h +bind-key h split-window +bind-key C-h split-window + +# F8 rename window +# unbind F8 +# unbind C-F8 +bind-key -n F8 command-prompt 'rename-window %%' + +# Ctrl - t or t new window +# unbind t +# unbind C-t +# bind-key t new-window +bind-key -n C-t new-window + +# Ctrl - w or w to kill panes +# unbind w +# unbind C-w +# bind-key w kill-pane +bind-key -n C-w kill-pane + +# C + control q to kill session +# unbind q +# unbind C-q +# bind-key q kill-session +bind-key -n C-q kill-session + +# Switching panes with Ctrl +bind-key -n C-Left select-pane -L +bind-key -n C-Right select-pane -R +bind-key -n C-Up select-pane -U +bind-key -n C-Down select-pane -D + +# Ctrl + a + n : New session +unbind n +unbind C-n +bind-key n new-session +bind-key C-n new-session + +# Ctrl + a + Pagedown : Next window +unbind Pagedown +bind-key -n C-Pagedown next-window + +# Ctrl + a + Pagup : Previous window +unbind Pageup +bind-key -n C-Pageup previous-window + +# Visual Activity Monitoring between windows +setw -g monitor-activity on +set -g visual-activity off + +# -- default session ----------------------------------------------------------- +new -s local -n danix +neww -n root su - +neww -n top htop +neww -n syswatch tail -f /var/log/messages +splitw -v -p 50 -t 1 /home/danix/bin/my_netstat +selectw -t 2 +selectp -t 1 + +# -- copy mode ----------------------------------------------------------------- + +bind-key Enter copy-mode # enter copy mode + +run -b 'tmux bind -t vi-copy v begin-selection 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi v send -X begin-selection 2> /dev/null || true' +run -b 'tmux bind -t vi-copy C-v rectangle-toggle 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi C-v send -X rectangle-toggle 2> /dev/null || true' +run -b 'tmux bind -t vi-copy y copy-selection 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi y send -X copy-selection-and-cancel 2> /dev/null || true' +run -b 'tmux bind -t vi-copy Escape cancel 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi Escape send -X cancel 2> /dev/null || true' +run -b 'tmux bind -t vi-copy H start-of-line 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi H send -X start-of-line 2> /dev/null || true' +run -b 'tmux bind -t vi-copy L end-of-line 2> /dev/null || true' +run -b 'tmux bind -T copy-mode-vi L send -X end-of-line 2> /dev/null || true' + +# copy to X11 clipboard (needs xclip) +if -b 'command -v xclip > /dev/null 2>&1' 'bind y run -b "tmux save-buffer - | xclip -i -selection clipboard >/dev/null 2>&1"' + + +# -- buffers ------------------------------------------------------------------- + +bind-key b list-buffers # list paste buffers +bind-key p paste-buffer # paste from the top paste buffer +bind-key P choose-buffer # choose which buffer to paste from + + +# --theme ---------------------------------------------------------------------- + +# set -goqF @blackpearl-console-background colour59 +# set -goqF @blackpearl-console-orange colour11 +# set -goqF @blackpearl-console-dark-grey colour102 + +set -goqF @blackpearl-standard-background colour0 +set -goqF @blackpearl-orange colour3 +set -goqF @blackpearl-dark-grey colour8 + +set -goqF @theme-clock-mode-colour "#{@blackpearl-orange}" +set -goq @theme-clock-mode-style 24 + + +set -goq @blackpearl-status-left-area-left-format "\[ #h \]" +set -goq @blackpearl-status-left-area-middle-format "#(whoami)" +set -goq @blackpearl-status-left-area-right-format "" + +set -goq @blackpearl-status-right-area-left-format "" +set -goq @blackpearl-status-right-area-middle-format "[ %d-%b-%y ]" +set -goq @blackpearl-status-right-area-right-format "[ %H:%M:%S ]" + +set -goq @blackpearl-window-status-current-format "( #I:#W )" +set -goq @blackpearl-window-status-format "#I:#W" + +set -goqF @theme-status-left "#{@blackpearl-status-left-area-left-format} #{@blackpearl-status-left-area-middle-format} #{@blackpearl-status-left-area-right-format}" +set -goqF @theme-status-right "#{@blackpearl-status-right-area-left-format} #{@blackpearl-status-right-area-middle-format} #{@blackpearl-status-right-area-right-format}" +set -gqF @theme-window-status-current-format "#{@blackpearl-window-status-current-format}" +set -gqF @theme-window-status-format "#{@blackpearl-window-status-format}" + +set -gF status-justify centre +# empty part of the status bar +set -gF status-style "fg=#{@blackpearl-orange},bg=#{@blackpearl-standard-background}" + +set -gF status-left-length "40" +set -gF status-right-length "150" +set -gF status-left "#{@theme-status-left}" +# set -gF status-left "[ #h ] ♥ #(cat /etc/slackware-version)" +set -gF status-left-style "fg=#{@blackpearl-orange},bg=#{@blackpearl-standard-background}" +set -gF status-right "#{@theme-status-right}" +# set -gF status-right "%d-%b-%y | %H:%M:%S" +set -gF status-right-style "fg=#{@blackpearl-orange},bg=#{@blackpearl-standard-background}" + +set -gwF window-status-current-format "#{@theme-window-status-current-format}" +set -gwF window-status-format "#{@theme-window-status-format}" +set -gwF window-status-activity-style "fg=#{@blackpearl-orange},bg=#{@blackpearl-standard-background}" +set -gwF window-status-current-style "fg=#{@blackpearl-dark-grey},bg=#{@blackpearl-orange}" + +set -gF message-command-style "fg=#{@blackpearl-dark-grey},bg=#{@blackpearl-orange}" +set -gF message-style "fg=#{@blackpearl-dark-grey},bg=#{@blackpearl-orange}" +set -gwF clock-mode-colour "#{@theme-clock-mode-colour}" +set -gwF clock-mode-style "#{@theme-clock-mode-style}" + +# set-option -g status-style bg=colour220,fg=colour233 +# set-option -g pane-active-border-bg "#ff0000" +# set -gq @themepack-status-left-area-right-format "" +# set -gq @themepack-status-right-area-middle-format "#h" +# set -gq @themepack-status-right-area-right-format "%d-%b-%y" +# set -gq @powerline-status-bg "ffbf00" +# set -g @themepack 'powerline/block/yellow' + +# run tmux-plugin-manager +# run -b '~/.tmux/plugins/tpm/tpm' diff --git a/xinitrc b/xinitrc new file mode 100644 index 0000000..cf28ecf --- /dev/null +++ b/xinitrc @@ -0,0 +1,22 @@ +#!/bin/sh + +userresources=$HOME/.Xresources +usermodmap=$HOME/.Xmodmap +userxprofile=$HOME/.xprofile +sysresources=/etc/X11/xinit/.Xresources +sysmodmap=/etc/X11/xinit/.Xmodmap + +# Merge in defaults and keymaps +[ -f $sysresources ] && /usr/bin/xrdb -merge $sysresources +[ -f $sysmodmap ] && /usr/bin/xmodmap $sysmodmap +[ -f $userresources ] && /usr/bin/xrdb -merge $userresources +[ -f $usermodmap ] && /usr/bin/xmodmap $usermodmap +[ -f $userxprofile ] && . $userxprofile + + +# Start i3 +if [ -z "$DESKTOP_SESSION" -a -x /usr/bin/ck-launch-session ]; then + exec ck-launch-session dbus-launch --exit-with-session /usr/bin/i3 +else + exec /usr/bin/i3 +fi diff --git a/xprofile b/xprofile new file mode 100644 index 0000000..d0f961e --- /dev/null +++ b/xprofile @@ -0,0 +1,16 @@ +#! /bin/sh + +xbacklight -set 100 & +# ~/.fehbg & +~/bin/wallpaper.sh & +#wicd-client --tray & +#lxqt-powermanagement & +setxkbmap -layout it & +numlockx & +syndaemon -k -i 2 -d & +#xautolock -time 10 -locker i3lock-wrapper -notify 30 -notifier "notify-send 'locking the system' '30 seconds before locking system.' --icon=dialog-warning" & +compton --dbus --config ~/.config/compton.conf & +conky -c ~/.config/conky/qlocktwo.conkyrc & +xdg-user-dirs-update & + + -- 2.20.1