summaryrefslogtreecommitdiff
path: root/.bashrc
diff options
context:
space:
mode:
Diffstat (limited to '.bashrc')
-rw-r--r--.bashrc43
1 files changed, 21 insertions, 22 deletions
diff --git a/.bashrc b/.bashrc
index f0590ba..13dfd7b 100644
--- a/.bashrc
+++ b/.bashrc
@@ -1,22 +1,22 @@
#basics
stty -ixon
export MOZ_DBUS_REMOTE=1
-export BROWSER="vivaldi-snapshot --ozone-platform=wayland --enable-features=UseOzonePlatform,UseSkiaRenderer,Vulkan"
+#export BROWSER="vivaldi-stable --enable-features=UseOzonePlatform --ozone-platform=wayland --use-cmd-decoder=validating --use-gl=egl"
+
+export BROWSER="qutebrowser"
export EDITOR="nvim"
+#export EDITOR="vim"
# keep dictionaries in ~/bin/
export STARDICT_DATA_DIR="$HOME/bin/dict/"
+export NOTES_DIR="$HOME/notes"
export TERM="screen-256color"
export GREP_COLOR='00;38;5;166'
+export CM_HISTLENGTH=50
# my scripts on PATH
export PATH=/usr/local/bin:$PATH
export PATH=$PATH:$HOME/bin
export PATH=$PATH:$HOME/bin/bash-scripts
-export PATH=$PATH:$HOME/.gem/ruby/2.6.0/bin
-export QT_QPA_PLATFORM=wayland
-export QT_PLATFORM_THEME=qt5ct
-export QT_QPA_PLATFORMTHEME=qt5ct
-export XDG_SESSION_TYPE=wayland
-export GDK_BACKEND=wayland
+export PATH=$PATH:$HOME/.local/bin
# Alias definitions
if [ -f ~/.aliases ]; then
@@ -56,17 +56,15 @@ shopt -s autocd
shopt -s cdable_vars
export FZF_DEFAULT_OPTS="
---color dark,hl:33,hl+:37,fg+:235,bg+:136,fg+:254
+--color dark,hl:33,hl+:37,fg+:235,bg+:136,fg+:254
--color info:254,prompt:37,spinner:108,pointer:235,marker:235
--no-mouse --height 70% -1 --multi --inline-info --preview='[[ \$(file --mime {}) =~ binary ]] && echo {} is a binary file || (bat --style=numbers --color=always {} || cat {}) 2> /dev/null | head -300' --preview-window='right:hidden:wrap' --bind='f3:execute(bat --style=numbers {} || less -f {}),f2:toggle-preview,ctrl-d:half-page-down,ctrl-u:half-page-up,ctrl-a:select-all+accept,ctrl-y:execute-silent(echo {+} | wl-copy),ctrl-x:execute(rm -i {+})+abort'"
if type rg &> /dev/null; then
export FZF_DEFAULT_COMMAND='rg --files --no-ignore-vcs --hidden'
export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
fi
-
-
# Don't use ~ to define your home here, it won't work.
-export wir="$HOME/writing/conde/wired"
+export wir="$HOME/writing/wired"
export l="$HOME/writing/luxagraf/"
export lux="$HOME/sites/luxagraf.net"
export d="$HOME/documents"
@@ -97,9 +95,12 @@ export PS1="\[\033[33;1m\]\[\033[m\]\$(pwd-prompt.bash) \[$txtred\]\$git_dirty\[
# Complete all the things
source ~/bin/pass-completion.bash
+# arch:
source /usr/share/fzf/key-bindings.bash
source /usr/share/fzf/completion.bash
-
+#debian:
+#source /usr/share/doc/fzf/examples/key-bindings.bash
+#source /usr/share/bash-completion/completions/fzf
fzf-snippet() {
selected="$(cat ~/documents/snippets | sed '/^$/d' | sort -n | fzf -e -i )"
# remove tags, leading and trailing spaces, also no newline
@@ -120,12 +121,12 @@ function fore(){
#search any folder like you're in nvalt:
function nv() {
- ${EDITOR:-nvim} "$(find ${2:-~/notes} -maxdepth ${3:-1} -type f -print0 | xargs -0 grep -li $1 | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
+ ${EDITOR:-vim} "$(find ${2:-~/notes} -maxdepth ${3:-1} -type f -print0 | xargs -0 grep -li $1 | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
}
#search any folder like you're in nvalt but have ripgrep at your disposal
function fn() {
- ${EDITOR:-nvim} "$(rg -l $1 ${2:-~/notes} | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
+ ${EDITOR:-vim} "$(rg -l $1 ${2:-~/notes} | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
}
# same thing, but context
function nvl(){
@@ -136,7 +137,6 @@ function nvl(){
function fnt(){
find ~/notes ~/documents/bookmarks ~/documents/reading\ notes -type f -maxdepth 2 -print0 | xargs -0 grep -$2i $1
}
-
function fntt(){
${EDITOR:-nvim} "$(rg -l $1 ~/notes/ ~/documents/bookmarks/ ~/documents/reading\ notes/ | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
}
@@ -145,12 +145,15 @@ function f() {
${EDITOR:-nvim} "$(rg -l $1 ${2:-.} | fzf --preview="bat {}" --preview-window=right:70%:wrap)";
}
-fo() { ${EDITOR:-nvim} $(rg -n '.*' "$HOME/documents/org/" | fzf --layout=reverse --height 50% --ansi | sed -E 's/(.*):([0-9]+):.*/\1 +\2/g'); }
#fuzzy find file names only
function ff() {
ag -g "$1" ${2:-.} | fzf --preview="bat {}" --preview-window=right:70%:wrap
}
+# Notational Velocity
+function fn() {
+ rg -l $1 ${2:-~/notes} | fzf --preview="bat {}" --preview-window=right:70%:wrap
+}
function tolux() {
scp $3 $1 lxf:/home/lxf/$2
@@ -201,7 +204,7 @@ function md() {
# Encode webm:
function webm() {
- ffmpeg -i "$1" -c:v libvpx -quality good -cpu-used 0 -b:v 7000k -qmin 10 -qmax 42 -maxrate 500k -bufsize 2500k -threads 8 -vf scale=-1:720 -c:a libvorbis -b:a 192k -f webm "$1".webm
+ ffmpeg -i $1 -c:v libvpx -quality good -cpu-used 0 -b:v 7000k -qmin 10 -qmax 42 -maxrate 500k -bufsize 2500k -threads 8 -vf scale=-1:720 -c:a libvorbis -b:a 192k -f webm $1.webm
}
# encode ogg v:
function ogv() {
@@ -262,7 +265,7 @@ function timer(){
}
function markdone(){
- echo "@done - $(date '+%Y-%m-%d')" >> "$1"
+ echo '\n@done' >> "$1"
mkdir -p ~/gtd/done/$(date '+%Y-%m-%d')
mv "$1" ~/gtd/done/$(date '+%Y-%m-%d')
clear
@@ -274,10 +277,6 @@ fd() {
cd "$dir"
}
-fo() { ${EDITOR:-nvim} $(rg -n '.*' "$HOME/documents/org/" | fzf --layout=reverse --height 50% --ansi | sed -E 's/(.*):([0-9]+):.*/\1 +\2/g'); }
-
-fr() { ${EDITOR:-nvim} $(rg -n '.*' "$HOME/.config/remind/" | fzf --layout=reverse --height 50% --ansi | sed -E 's/(.*):([0-9]+):.*/\1 +\2/g'); }
-
if [[ "$OSTYPE" == "darwin"* ]]; then
# OSX-SPECIFIC SETTINGS