sistema_progs

Programas para customizar o meu entorno de traballo nos meus equipos persoais
Log | Files | Refs

commit 2af0bb719f4ed3298e028f2c57db4de14bc926b7
parent 03827eae54c06c1805d044481a90e4f2a3603042
Author: x0tero <gxoelotero@gmail.com>
Date:   Mon,  9 Oct 2023 00:25:04 +0200

axustes post-formateo

Diffstat:
AMononoki/LICENSE.txt | 94+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
AMononoki/MononokiNerdFont-Bold.ttf | 0
AMononoki/MononokiNerdFont-BoldItalic.ttf | 0
AMononoki/MononokiNerdFont-Italic.ttf | 0
AMononoki/MononokiNerdFont-Regular.ttf | 0
AMononoki/MononokiNerdFontMono-Bold.ttf | 0
AMononoki/MononokiNerdFontMono-BoldItalic.ttf | 0
AMononoki/MononokiNerdFontMono-Italic.ttf | 0
AMononoki/MononokiNerdFontMono-Regular.ttf | 0
AMononoki/MononokiNerdFontPropo-Bold.ttf | 0
AMononoki/MononokiNerdFontPropo-BoldItalic.ttf | 0
AMononoki/MononokiNerdFontPropo-Italic.ttf | 0
AMononoki/MononokiNerdFontPropo-Regular.ttf | 0
AMononoki/readme.md | 8++++++++
Able.sh | 1+
Mdmenu/dmenu | 0
Mdmenu/dmenu.o | 0
Mdmenu/drw.o | 0
Mdmenu/stest | 0
Mdmenu/stest.o | 0
Mdmenu/util.o | 0
Agcolors/.gitignore | 1+
Agcolors/README.md | 80+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Agcolors/change.sh | 15+++++++++++++++
Agcolors/colors_env.sh | 22++++++++++++++++++++++
Agcolors/default.h | 3+++
Agcolors/gcolors.h | 4++++
Agcolors/gcolors/dracula.h | 34++++++++++++++++++++++++++++++++++
Agcolors/gcolors/nord.h | 34++++++++++++++++++++++++++++++++++
Agcolors/install.sh | 20++++++++++++++++++++
Agcolors/remake.sh | 19+++++++++++++++++++
Agcolors/theme_dmenu.sh | 19+++++++++++++++++++
Aportatil/40-libinput.conf | 7+++++++
Aportatil/70-synaptics.conf | 24++++++++++++++++++++++++
Mportatil/bashrc | 2+-
Mportatil/dwm/drw.o | 0
Mportatil/dwm/dwm | 0
Mportatil/dwm/dwm.o | 0
Mportatil/dwm/util.o | 0
Aportatil/notas.txt | 5+++++
Mportatil/st/st | 0
Mportatil/st/st.o | 0
Mportatil/st/x.o | 0
43 files changed, 391 insertions(+), 1 deletion(-)

diff --git a/Mononoki/LICENSE.txt b/Mononoki/LICENSE.txt @@ -0,0 +1,94 @@ +Copyright (c) 2022, Matthias Tellen matthias.tellen@googlemail.com, +with Reserved Font Name mononoki. + +This Font Software is licensed under the SIL Open Font License, Version 1.1. +This license is copied below, and is also available with a FAQ at: +http://scripts.sil.org/OFL + + +----------------------------------------------------------- +SIL OPEN FONT LICENSE Version 1.1 - 26 February 2007 +----------------------------------------------------------- + +PREAMBLE +The goals of the Open Font License (OFL) are to stimulate worldwide +development of collaborative font projects, to support the font creation +efforts of academic and linguistic communities, and to provide a free and +open framework in which fonts may be shared and improved in partnership +with others. + +The OFL allows the licensed fonts to be used, studied, modified and +redistributed freely as long as they are not sold by themselves. The +fonts, including any derivative works, can be bundled, embedded, +redistributed and/or sold with any software provided that any reserved +names are not used by derivative works. The fonts and derivatives, +however, cannot be released under any other type of license. The +requirement for fonts to remain under this license does not apply +to any document created using the fonts or their derivatives. + +DEFINITIONS +"Font Software" refers to the set of files released by the Copyright +Holder(s) under this license and clearly marked as such. This may +include source files, build scripts and documentation. + +"Reserved Font Name" refers to any names specified as such after the +copyright statement(s). + +"Original Version" refers to the collection of Font Software components as +distributed by the Copyright Holder(s). + +"Modified Version" refers to any derivative made by adding to, deleting, +or substituting -- in part or in whole -- any of the components of the +Original Version, by changing formats or by porting the Font Software to a +new environment. + +"Author" refers to any designer, engineer, programmer, technical +writer or other person who contributed to the Font Software. + +PERMISSION & CONDITIONS +Permission is hereby granted, free of charge, to any person obtaining +a copy of the Font Software, to use, study, copy, merge, embed, modify, +redistribute, and sell modified and unmodified copies of the Font +Software, subject to the following conditions: + +1) Neither the Font Software nor any of its individual components, +in Original or Modified Versions, may be sold by itself. + +2) Original or Modified Versions of the Font Software may be bundled, +redistributed and/or sold with any software, provided that each copy +contains the above copyright notice and this license. These can be +included either as stand-alone text files, human-readable headers or +in the appropriate machine-readable metadata fields within text or +binary files as long as those fields can be easily viewed by the user. + +3) No Modified Version of the Font Software may use the Reserved Font +Name(s) unless explicit written permission is granted by the corresponding +Copyright Holder. This restriction only applies to the primary font name as +presented to the users. + +4) The name(s) of the Copyright Holder(s) or the Author(s) of the Font +Software shall not be used to promote, endorse or advertise any +Modified Version, except to acknowledge the contribution(s) of the +Copyright Holder(s) and the Author(s) or with their explicit written +permission. + +5) The Font Software, modified or unmodified, in part or in whole, +must be distributed entirely under this license, and must not be +distributed under any other license. The requirement for fonts to +remain under this license does not apply to any document created +using the Font Software. + +TERMINATION +This license becomes null and void if any of the above conditions are +not met. + +DISCLAIMER +THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT +OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE +COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL +DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM +OTHER DEALINGS IN THE FONT SOFTWARE. diff --git a/Mononoki/MononokiNerdFont-Bold.ttf b/Mononoki/MononokiNerdFont-Bold.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFont-BoldItalic.ttf b/Mononoki/MononokiNerdFont-BoldItalic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFont-Italic.ttf b/Mononoki/MononokiNerdFont-Italic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFont-Regular.ttf b/Mononoki/MononokiNerdFont-Regular.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontMono-Bold.ttf b/Mononoki/MononokiNerdFontMono-Bold.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontMono-BoldItalic.ttf b/Mononoki/MononokiNerdFontMono-BoldItalic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontMono-Italic.ttf b/Mononoki/MononokiNerdFontMono-Italic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontMono-Regular.ttf b/Mononoki/MononokiNerdFontMono-Regular.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontPropo-Bold.ttf b/Mononoki/MononokiNerdFontPropo-Bold.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontPropo-BoldItalic.ttf b/Mononoki/MononokiNerdFontPropo-BoldItalic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontPropo-Italic.ttf b/Mononoki/MononokiNerdFontPropo-Italic.ttf Binary files differ. diff --git a/Mononoki/MononokiNerdFontPropo-Regular.ttf b/Mononoki/MononokiNerdFontPropo-Regular.ttf Binary files differ. diff --git a/Mononoki/readme.md b/Mononoki/readme.md @@ -0,0 +1,8 @@ + +# Nerd Fonts + +This is an archived font from a Nerd Fonts release. + +For more information see: +* https://github.com/ryanoasis/nerd-fonts/ +* https://github.com/ryanoasis/nerd-fonts/releases/latest/ diff --git a/ble.sh b/ble.sh @@ -0,0 +1 @@ +Subproject commit 9d84b424daf31b192891c06275fff316fa5ddd35 diff --git a/dmenu/dmenu b/dmenu/dmenu Binary files differ. diff --git a/dmenu/dmenu.o b/dmenu/dmenu.o Binary files differ. diff --git a/dmenu/drw.o b/dmenu/drw.o Binary files differ. diff --git a/dmenu/stest b/dmenu/stest Binary files differ. diff --git a/dmenu/stest.o b/dmenu/stest.o Binary files differ. diff --git a/dmenu/util.o b/dmenu/util.o Binary files differ. diff --git a/gcolors/.gitignore b/gcolors/.gitignore @@ -0,0 +1 @@ +makepkgs diff --git a/gcolors/README.md b/gcolors/README.md @@ -0,0 +1,80 @@ +# GCOLORS - Gerardet Colors +This color library (header files and some utilities) are meant to have +several color schemes (.h files). This color schemes can be included +directly in C programs (such us suckless programs) to avoid opening Xresources +file, for example, which is slow. + +It can also set environment variables with the colors formatted in `#rrggbb` + +## Installation +Simply run +```bash +sudo ./install +``` +and header files will be installed at _/usr/include_ and scripts in _/opt/gcolors_ + +## Color schemes +This are the available color schemes +- nord +- dracula + +Edit gcolors folder (_/usr/include/gcolors/_) to add/del/change color schemes. +Don't forget to include them all in _/usr/include/gcolors.h_ + +## Usage +### Use colors +#### In C files: +Just type +```c +#include <gcolors.h> +``` +and you can add COL\_GROC, for example, to get the yellow color (see definitions +in _/usr/include/gcolors/your_theme.h_) +#### In scripts +If you have set environment variables (see it below) then you can +echo "$COL\_GROC" to display the yellow color. + +This is useful for example for configuring dwmblocks with status2d, which +allows you typing any color in the hex format, which is the format followed by gcolors + +### Change color scheme +```bash +sudo /opt/gcolors/change.sh [theme_name (nord, dracula, ...)] +``` +### Remake pkgs that need gcolors.h +Edit the file _/opt/gcolors/makepkgs_, which contains a list of folders that +contain programs (such us dwm or dmenu) that need to be recompiled. + +**NOTE 1**: Run it with regular user! (**don't run it with sudo**) + +**NOTE 2**: To enter HOME directory, please type `~/` instead of `$HOME` in that file, +as you can see in the example included in this repository + +Then, run +```bash +/opt/remake.sh +``` +to re-make (install clean) those packages + +### Set environment variables +Just add the following to the autostart (maybe ~/.xinitrc) +```bash +. /opt/gcolors/colors_env.sh +``` +Notice that it must be sourced (with `.` or `source`). You can run it also in the +fly to refresh color variables + +### Make all this with dmenu! +Run the following: +```bash +/opt/gcolors/theme_dmenu.sh +``` +to open dmenu (must be installed). There you can select the theme and it will +be changed, remaked and set the env. variables! Make sure you have a program +to ask SUDO\_ASKPASS to enter the password to change the theme + +## Colors +The name of the colors are in catalan. You can see the header files (in _/usr/include/gcolors_) +to see the colors. + +If you want to add more themes, please follow the same syntax. diff --git a/gcolors/change.sh b/gcolors/change.sh @@ -0,0 +1,15 @@ +#!/usr/bin/env sh + +[ -z "$1" ] && echo "Usage: ./change.sh [name of file of scheme] (./change nord)" && exit 1 + +path="/usr/include" +path_opt="/opt/gcolors" + +if [ -f "$path/gcolors/$1.h" ]; then + upper="$(echo "$1" | tr '[:lower:]' '[:upper:]')" + + echo "#define $upper" > "$path/gcolors.h" + cat "$path_opt/default.h" >> "$path/gcolors.h" +else + exit 1 +fi diff --git a/gcolors/colors_env.sh b/gcolors/colors_env.sh @@ -0,0 +1,22 @@ +#!/usr/bin/env sh + +_PATH="/usr/include" + +scheme="$(grep "#define" "$_PATH/gcolors.h" | awk '{print $2}' | tr '[:upper:]' '[:lower:]')" +sch_file="$_PATH/gcolors/$scheme.h" + +grep "#define" "$sch_file" > /tmp/color_list +while read line +do + key="$(echo "$line" | awk '{print $2}')" + value="$(echo "$line" | awk '{print $3}' | sed s/\"//g)" + + # resolve referencies + while ! [ "$(echo "$value" | cut -c1-1)" = "#" ] + do + value="$(grep "#define $value" "$sch_file" | awk '{print $3}' | sed s/\"//g)" + done + + # finally export color + export "$key"="$value" +done < /tmp/color_list diff --git a/gcolors/default.h b/gcolors/default.h @@ -0,0 +1,3 @@ +// include here the color schemes +#include "gcolors/dracula.h" +#include "gcolors/nord.h" diff --git a/gcolors/gcolors.h b/gcolors/gcolors.h @@ -0,0 +1,4 @@ +#define NORD +// include here the color schemes +#include "gcolors/dracula.h" +#include "gcolors/nord.h" diff --git a/gcolors/gcolors/dracula.h b/gcolors/gcolors/dracula.h @@ -0,0 +1,34 @@ +// SYNTAX: define KEY "#VALUE" +#ifdef DRACULA + +#define COL_BG_0 COL_0 +#define COL_BG_1 COL_2 + +#define COL_FOSC "#7d33c9" +#define COL_CLAR COL_MAGENTA + +#define COL_0 "#161b20" +#define COL_1 "#282a36" +#define COL_2 "#444444" +#define COL_3 "#555555" + +#define COL_W0 "#ffffff" +#define COL_W1 "#d8d8d2" +#define COL_W2 "#c8c8c2" + +#define COL_B0 "#8be9fd" +#define COL_B1 "#88C0D0" +#define COL_B2 "#81A1C1" +#define COL_B3 "#5E81AC" + +#define COL_NEGRE COL_1 +#define COL_VERMELL "#ff5555" +#define COL_VERD "#50fa7b" +#define COL_TARONJA "#ffb86c" +#define COL_GROC "#f1fa8c" +#define COL_BLAU COL_B2 +#define COL_MAGENTA "#ff79c6" +#define COL_CIAN COL_B0 +#define COL_BLANC COL_W1 + +#endif diff --git a/gcolors/gcolors/nord.h b/gcolors/gcolors/nord.h @@ -0,0 +1,34 @@ +// SYNTAX: define KEY "#VALUE" +#ifdef NORD + +#define COL_BG_0 "#20242c" +#define COL_BG_1 COL_1 + +#define COL_FOSC "#94628a" +#define COL_CLAR COL_MAGENTA + +#define COL_0 "#2E3440" +#define COL_1 "#3B4252" +#define COL_2 "#434C5E" +#define COL_3 "#4C566A" + +#define COL_W0 "#ECEFF4" +#define COL_W1 "#E5E9F0" +#define COL_W2 "#D8DEE9" + +#define COL_B0 "#8FBCBB" +#define COL_B1 "#88C0D0" +#define COL_B2 "#81A1C1" +#define COL_B3 "#5E81AC" + +#define COL_NEGRE COL_1 +#define COL_VERMELL "#bf616a" +#define COL_VERD "#a3be8c" +#define COL_TARONJA "#D08770" +#define COL_GROC "#ebcb8b" +#define COL_BLAU COL_B2 +#define COL_MAGENTA "#b48ead" +#define COL_CIAN COL_B0 +#define COL_BLANC COL_W1 + +#endif diff --git a/gcolors/install.sh b/gcolors/install.sh @@ -0,0 +1,20 @@ +#!/usr/bin/env sh + +path="/opt/gcolors" + +cp -vf gcolors.h /usr/include/ +cp -rvf gcolors /usr/include/ + +mkdir -pv "$path" + +cp -vf makepkgs "$path/" +cp -vf remake.sh "$path/" +cp -vf change.sh "$path/" +cp -vf colors_env.sh "$path/" +cp -vf theme_dmenu.sh "$path/" + +cp -vf default.h "$path/" + +echo "##### INSTALLATION COMPLETED #####" +echo "Add '. $path/colors_env.sh' to autostart" +echo "Check $path/makepkgs list" diff --git a/gcolors/remake.sh b/gcolors/remake.sh @@ -0,0 +1,19 @@ +#!/usr/bin/env sh + +# Run it with REGULAR USER! + +_pwd="$(pwd)" +while read line +do + # ignoram comentaris + first="$(echo "$line" | cut -c1-1)" + [ "$first" = "#" ] && continue + [ "$first" = "~" ] && line="$HOME$(echo "$line" | cut -c2-)" + + if [ -d "$line" ]; then + cd "$line" + sudo make install clean + echo "Fet - $line" + cd "$_pwd" + fi +done < /opt/gcolors/makepkgs diff --git a/gcolors/theme_dmenu.sh b/gcolors/theme_dmenu.sh @@ -0,0 +1,19 @@ +#!/usr/bin/env sh + +opt="$(ls /usr/include/gcolors | sed s/\.h//g | dmenu -p "Tria un tema")" + +_pwd="$(pwd)" +cd /opt/gcolors + +if [ -f "/usr/include/gcolors/$opt.h" ]; then + sudo -A echo "sudo passwd" + sudo ./change.sh "$opt" + ./remake.sh + . ./colors_env.sh + + # finish + killall dwmblocks + dwmblocks & +fi + +cd "$_pwd" diff --git a/portatil/40-libinput.conf b/portatil/40-libinput.conf @@ -0,0 +1,7 @@ +echo 'Section "InputClass" + Identifier "libinput touchpad catchall" + MatchIsTouchpad "on" + MatchDevicePath "/dev/input/event*" + Driver "libinput" + Option "Tapping" "on" +EndSection' > /etc/X11/xorg.conf.d/40-libinput.conf diff --git a/portatil/70-synaptics.conf b/portatil/70-synaptics.conf @@ -0,0 +1,24 @@ +/etc/X11/xorg.conf.d/70-synaptics.conf + +Section "InputClass" + Identifier "touchpad" + Driver "synaptics" + MatchIsTouchpad "on" + Option "TapButton1" "1" + Option "TapButton2" "3" + Option "TapButton3" "2" + Option "VertEdgeScroll" "on" + Option "VertTwoFingerScroll" "on" + Option "HorizEdgeScroll" "on" + Option "HorizTwoFingerScroll" "on" + Option "CircularScrolling" "on" + Option "CircScrollTrigger" "2" + Option "EmulateTwoFingerMinZ" "40" + Option "EmulateTwoFingerMinW" "8" + Option "CoastingSpeed" "0" + Option "FingerLow" "30" + Option "FingerHigh" "50" + Option "MaxTapTime" "125" + ... +EndSection + diff --git a/portatil/bashrc b/portatil/bashrc @@ -13,7 +13,7 @@ export LANGUAGE=en_US.UTF-8 export LC_COLLATE=C export LC_CTYPE=en_US.UTF-8 # PROMPT (30: gris, 31:vermello, 32:verde, 33:amarelo, 34: azul, 35: rosa, 36: cian, 37: branco) -export PS1="\[\033[01;31m\][\[\033[01;36m\]chinomin \[\033[01;30m\]\W\[\033[01;31m\]]\[\033[00m\] " +export PS1="\[\033[01;31m\][\[\033[01;36m\]x0tero \[\033[01;30m\]\W\[\033[01;31m\]]\[\033[00m\] " # TERMINAL PRINCIPAL export TERMINAL=st # EDITOR PRINCIPAL diff --git a/portatil/dwm/drw.o b/portatil/dwm/drw.o Binary files differ. diff --git a/portatil/dwm/dwm b/portatil/dwm/dwm Binary files differ. diff --git a/portatil/dwm/dwm.o b/portatil/dwm/dwm.o Binary files differ. diff --git a/portatil/dwm/util.o b/portatil/dwm/util.o Binary files differ. diff --git a/portatil/notas.txt b/portatil/notas.txt @@ -0,0 +1,5 @@ +Para Debian: +mover 40-libinput.conf a /etc/X11/xorg.conf.d + +Para Arch: +mover 70-synaptics.conf a /etc/X11/xorg.conf.d diff --git a/portatil/st/st b/portatil/st/st Binary files differ. diff --git a/portatil/st/st.o b/portatil/st/st.o Binary files differ. diff --git a/portatil/st/x.o b/portatil/st/x.o Binary files differ.