Compare commits

..

No commits in common. "4dadcd5f9f6e73036c65fadaccb1ba99be194fec" and "d459d79de0e77ea2de9e9cfea33d293542092186" have entirely different histories.

6 changed files with 59 additions and 95 deletions

View file

@ -5,11 +5,9 @@
[init]
defaultBranch = main
[core]
pager = git delta
[pager]
difftool = true
pager = delta
[interactive]
diffFilter = git delta --color-only
diffFilter = delta --color-only
[merge]
conflictstyle = diff3
[delta]
@ -25,9 +23,6 @@
pushall = "!git remote | xargs -I R git push R" # push to all connected remotes
fetchall = "!git remote | xargs -I R git fetch R" # fetch from all connected remotes
diffword = "!git diff --word-diff=color --word-diff-regex='[0-9A-Za-z_]+'" # word-wise diff, good for prose
diffsyn = "!git difftool --tool difftastic" # add syntax-driven diff using treesitter
diffside = "!DELTA_FEATURES='+side-by-side' git diff" # add side-by-side diffing
delta = "![ $TERM_DARK=false ] && delta --light || delta" # Take care that we always display right color scheme
[commit]
gpgsign = true # sign commits as me
verbose = true # Always show diff when preparing commit message
@ -37,10 +32,6 @@
rebase = true # always rebase on pulling, obviates merge commits
[diff]
colorMoved = zebra # also color stuff that has simply been moved, in a classy zebra-color
[difftool]
prompt = false
[difftool "difftastic"]
cmd = difft "$LOCAL" "$REMOTE"
[color.diff]
meta = "9"
frag = "magenta bold"

View file

@ -31,32 +31,19 @@ else
fi
alias gco='git checkout'
alias gd='git diff'
alias gdd='git diffword'
alias gds='git diff --staged'
alias gdds='git diffword --staged'
alias gi='git ignore'
# normal diff
alias gd='git diff'
alias gds='git diff --staged'
# word-based diff (with custom word regex)
alias gdw='git diffword'
alias gdws='git diffword --staged'
# side-by-side diff
alias gdd='git diffside'
alias gdds='git diffside --staged'
# syntax-based diff
if exist difft; then
alias gdy='git diffsyn'
alias gdys='git diffsyn --staged'
fi
alias gdd='git diffside'
alias gdds='git diffside --staged'
# show last committed content
alias gdl='git last'
alias gll='git last'
# show quick log overview
alias glg='git log --oneline --decorate --graph'
alias glga='git log --oneline --decorate --graph --remotes --all'
# show quick log overview - with dates
alias glgd="git log --graph --pretty=format:'%C(auto)%h%Creset %C(cyan)%ar%Creset%C(auto)%d%Creset %s'"
alias glga='git log --oneline --decorate --graph --remotes --all'
alias glgad="git log --graph --remotes --all --pretty=format:'%C(auto)%h%Creset %C(cyan)%ar%Creset%C(auto)%d%Creset %s'"
# show detailed log overview
alias glog='git log --stat'

View file

@ -183,6 +183,21 @@ redirects = {
"whoogle.dcs0.hu",
],
},
"wiki-en": {
"source": ["en.wikipedia.org"],
"target": [
"wiki.slipfox.xyz",
"wikiless.funami.tech",
"wikiless.org",
"wikiless.tiekoetter.com",
],
},
"wiki-de": {
"source": ["de.wikipedia.org"],
"target": [
"wiki.adminforge.de",
],
},
}

View file

@ -5,39 +5,7 @@ cur_dir=$(pwd)
search_dir="${molten_session_dir}${cur_dir}"
if [ "$1" == "-c" ]; then
cmd_explicit=$(echo -e "euporie-console\njupyter-console\nptipython\nipython\npython" | fzf)
fi
# search for molten session for current dir
if [ -n "$(ls -A "${search_dir}" 2>/dev/null)" ]; then
session=$(find "$search_dir" -maxdepth 1 -type f -name "*.json")
if [ "$(echo "$session" | wc -l)" -gt 1 ]; then
session=$(echo "$session" | fzf --prompt "Molten session> ")
fi
fi
if [ -n "$cmd_explicit" ] && not exist "$cmd_explicit"; then
echo "Command $cmd_explicit not found."
exit 1
elif [ "$cmd_explicit" == "euporie-console" ]; then
if [ -n "$session" ]; then
euporie-console --edit-mode vi --connection-file "$session"
else
echo "Starting euporie without a session to attach to."
euporie-console --edit-mode vi
fi
exit 0
elif [ "$cmd_explicit" == "jupyter-console" ]; then
if [ -n "$session" ]; then
jupyter-console --existing "$session"
else
echo "Starting jupyter console without a session to attach to."
jupyter-console
fi
exit 0
elif [ -n "$cmd_explicit" ]; then
"$cmd_explicit"
exit 0
cmd=$(echo -e "euporie-console\njupyter-console\nptipython\nipython\npython" | fzf)
fi
# set normal command first
@ -54,15 +22,22 @@ if [ -z "$cmd" ]; then
fi
fi
# search for molten session for current dir
if [ -n "$(ls -A "${search_dir}" 2>/dev/null)" ]; then
res=$(find "$search_dir" -maxdepth 1 -type f -name "*.json")
if [ "$(echo "$res" | wc -l)" -gt 1 ]; then
session=$(echo "$res" | fzf --prompt "Molten session> ")
fi
fi
# attach to kernel
if [ -n "${session}" ]; then
if exist euporie-console; then
if exist euporie-console || [ "$cmd" == "euporie-console" ]; then
euporie-console --edit-mode vi --connection-file "$session"
exit 0
elif exist jupyter-console; then
elif exist jupyter-console || [ "$cmd" == "jupyter-console" ]; then
jupyter-console --existing "$session"
exit 0
fi
fi
# or just run normal python
else
$cmd
fi

View file

@ -215,7 +215,7 @@ set viewcolumns=-{name}..,6{}.
" Filter-out build and temporary files
"
filter! /^.*\.(lo|o|d|class|py[co])$|.*~$/
" filter! /^.*\.(lo|o|d|class|py[co])$|.*~$/
" }}}
" Mappings {{{
@ -471,17 +471,13 @@ filetype *.sqlite,*.db
\ sqlite3 %f,
" tabular data
filextype *.csv, *.xlsx, *.tsv, *.json
filextype *.csv
\ {Open with visidata}
\ vd %f,
fileviewer *.tsv,*.csv
\ tidy-viewer --color-always --title %c
fileviewer *.csv
\ tidy-viewer
" \ xsv sample 100 %c | xsv table -c8 -p1 -w1,
" \ {cat %c | sed -e 's/,,/, ,/g' | column -s, -t | less -#5 -N -S; }
fileviewer *.xlsx
\ xlsx2csv %c | tidy-viewer --color-always --title %c
fileviewer *.json
\ jq '.' --color-output %c
" Mindmap
filextype *.vym

View file

@ -16,4 +16,4 @@ linewrap: 79
tagsymbols: '#@'
template: false
timeformat: '%F %r'
version: v4.1
version: v4.0.1