Skip to content

Commit

Permalink
jasdfdasf
Browse files Browse the repository at this point in the history
  • Loading branch information
ediw8311xht committed Nov 23, 2024
1 parent 33d5b4e commit aedb3d6
Show file tree
Hide file tree
Showing 5 changed files with 59 additions and 33 deletions.
2 changes: 1 addition & 1 deletion bashrc_files/aliases.sh
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ alias paclocal=' pacman -Qm'
alias pacsel=' pacman -Qs'
alias pacil=' pacman -Qi'
alias pacfrom=' pacman -Qo'
alias pacfiles=' pacman -Qql'
alias pacfiles=' list_files_pac'
alias pacf=' pacman -Fl'
alias pacool=' pacman -Sl | grep -Fi "[installed]" | grep -i'
alias pacnot=' pacman -Sl | grep -vFi "[installed]" | grep -i'
Expand Down
15 changes: 15 additions & 0 deletions bashrc_files/functions.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,19 @@
#!/bin/bash

list_files_pac() {
if yay -Qi "${1}" &>/dev/null ; then
yay -Ql "${1}"
elif yay -Si "${1}" &>/dev/null ; then
echo "HER"
if ! pkgfile -sl "${1}" ; then
echo "Package in AUR and not installed. Can't list files." >&2; return 1
fi
else
echo "Package: '${1}' not in AUR/AOR." >&2; return 1
fi
return 0
#if yay -Qi "${1}"
}
mps() {
local h1='\[\e[00;01;07;34m\]' h2='\[\e[00;01m\]' h3='\[\e[00;01;34m\]' h4='\[\e[00;01;33m\]'
local d1='\D{%F}' d2='\D{%T}' d3='\D{%s}'
Expand Down Expand Up @@ -92,6 +106,7 @@ fzf_cd() {
}

fzf_edit() {
# local f=""
local RG=( --ignore-file="${XDG_CONFIG_HOME}/rg/code.rg"
--hidden
--files "${1:-.}" )
Expand Down
9 changes: 5 additions & 4 deletions mimeapps.list
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ x-scheme-handler/https=brave-browser.desktop;
application/vnd.openxmlformats-officedocument.wordprocessingml.document=libreoffice-writer.desktop;

[Default Applications]
image/vnd.djvu+multipage=org.pwmt.zathura-pdf-mupdf.desktop;
application/x-xz-compressed-tar=org.gnome.FileRoller.desktop;
application/x-compressed-tar=org.gnome.FileRoller.desktop;
application/zip=org.gnome.FileRoller.desktop;
application/epub+zip=org.pwmt.zathura-pdf-mupdf.desktop;
application/epub=zathura.desktop;
application/gzip=engrampa.desktop;
Expand All @@ -22,6 +18,7 @@ application/x-ankiaddon=anki.desktop;
application/x-apkg=anki.desktop;
application/x-bittorrent=deluge.desktop;
application/x-colpkg=anki.desktop;
application/x-compressed-tar=org.gnome.FileRoller.desktop;
application/x-desktop=nvim.desktop;
application/x-extension-htm=nvim.desktop;
application/x-extension-html=nvim.desktop;
Expand All @@ -33,8 +30,10 @@ application/x-mobipocket-ebook=zathura.desktop;
application/x-openzim=zim.desktop;
application/x-shellscript=nvim.desktop;
application/x-wine-extension-ini=nvim.desktop;
application/x-xz-compressed-tar=org.gnome.FileRoller.desktop;
application/xhtml+xml=nvim.desktop;
application/xml=nvim.desktop;
application/zip=org.gnome.FileRoller.desktop;
audio/AMR=mpv.desktop;
audio/aac=mpv.desktop;
audio/ac3=mpv.desktop;
Expand Down Expand Up @@ -72,6 +71,7 @@ image/jxl=nsxiv.desktop;
image/png=nsxiv.desktop;
image/svg+xml=nsxiv.desktop;
image/tiff=nsxiv.desktop;
image/vnd.djvu+multipage=org.pwmt.zathura-pdf-mupdf.desktop;
image/webp=nsxiv.desktop;
image/x-portable-anymap=nsxiv.desktop;
image/x-portable-bitmap=nsxiv.desktop;
Expand Down Expand Up @@ -99,6 +99,7 @@ text/x-chdr=nvim.desktop;
text/x-common-lisp=nvim.desktop
text/x-copying=nvim.desktop;
text/x-csrc=nvim.desktop;
text/x-dbus-service=nvim.desktop
text/x-dsrc=nvim.desktop;
text/x-elixir=nvim.desktop;
text/x-emacs-lisp=nvim.desktop;
Expand Down
16 changes: 13 additions & 3 deletions nvim/lua/functions.lua
Original file line number Diff line number Diff line change
@@ -1,9 +1,19 @@

local va = vim.api;
local vauto = vim.api.nvim_create_autocmd;
local vc = vim.cmd;
local vauto = vim.api.nvim_create_autocmd
local vc = vim.cmd

function env_var_check(var)
local e = os.getenv(var)
if e == nil or e == '' then
return false
else
return e
end
end

function ClipBoardExit()
if va.executable("xclip") then
if env_var_check("$DISPLAY") and va.executable("xclip") then
va.system('xclip -selection clipboard -i -r <<< ', va.getreg('a'))
end
end
50 changes: 25 additions & 25 deletions xorg/SetKeys.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ toggle_r_rate() {
if [[ "${1,,}" != 'on' ]] &&
{ xset q | grep -q -Pi 'auto[ ]*repeat[:][ ]*on'; }
then xset r off; status='Off'
else xset r rate 300 50
else xset r rate 350 40
fi
notify-send -t 3000 "Keyboard Repeat Toggled" "${status}"
}
Expand All @@ -17,32 +17,12 @@ main() {
toggle_r_rate "${@:2}"
else
if [[ ! "${1,,}" = '--y' ]] ; then
xset +fp /usr/share/fonts/misc 2>/dev/null
xset +fp /usr/share/fonts/* 2>/dev/null
xset +fp /usr/share/fonts/misc 2>/dev/null
xset +fp /usr/share/fonts/* 2>/dev/null
xset +fp "${HOME}/.local/share/fonts/"* 2>/dev/null
xset -dpms
toggle_r_rate "on"
fi
#xset r off
##### This turns off mouse acceleration
##### xinput --set-prop 12 "libinput Accel Speed" -1
##### Increases mouse speed, neccesary to adjust this value if you do not want mouse acceleration.
##### xinput --set-prop 12 "Coordinate Transformation Matrix" 1, 0, 0, 0, 1, 0, 0, 0, 0.44
#xmodmap -e "keycode 49 = 0x0000 0xffeb 0x0000 0xffeb"
#xmodmap -e "keycode 108 = 0x007e 0x0060 0x007e 0x0060"
#xmodmap -e "keycode 133 = 0x007e 0x0060 0x007e 0x0060"
#check_mod_map() {
# local a=(
# 'Mod1 Alt_R'
# 'Mod1 Meta_R'
# 'Mod4 asciitilde'
# )
# for i in "${a[@]}" ; do
# if xmodmap -pm | grep -qF "${i}" ; then
# xmodmap -e 'remove Mod1 = Alt_R'
# fi
# done
#}
xset -dpms
toggle_r_rate "on"
xmodmap "$HOME/.Xmodmap"

if xmodmap -pm | grep -iq 'Mod1.*Alt_R' ; then
Expand All @@ -57,3 +37,23 @@ main() {
}

main "${@}"

##### This turns off mouse acceleration
##### xinput --set-prop 12 "libinput Accel Speed" -1
##### Increases mouse speed, neccesary to adjust this value if you do not want mouse acceleration.
##### xinput --set-prop 12 "Coordinate Transformation Matrix" 1, 0, 0, 0, 1, 0, 0, 0, 0.44
#xmodmap -e "keycode 49 = 0x0000 0xffeb 0x0000 0xffeb"
#xmodmap -e "keycode 108 = 0x007e 0x0060 0x007e 0x0060"
#xmodmap -e "keycode 133 = 0x007e 0x0060 0x007e 0x0060"
#check_mod_map() {
# local a=(
# 'Mod1 Alt_R'
# 'Mod1 Meta_R'
# 'Mod4 asciitilde'
# )
# for i in "${a[@]}" ; do
# if xmodmap -pm | grep -qF "${i}" ; then
# xmodmap -e 'remove Mod1 = Alt_R'
# fi
# done
#}

0 comments on commit aedb3d6

Please sign in to comment.