From: Jan Kratochvil Date: Fri, 9 Sep 2022 13:40:15 +0000 (+0200) Subject: Undo accidental commit. X-Git-Url: http://git.jankratochvil.net/?p=nethome.git;a=commitdiff_plain;h=c5bb072adf2104b0096ff8c08b1d1184ce86aacf Undo accidental commit. --- diff --git a/.bashrc b/.bashrc index 0a78130..2bd97fb 100644 --- a/.bashrc +++ b/.bashrc @@ -394,6 +394,7 @@ function rpmsrclist } function yumupdate {(ulimit -v unlimited;yum makecache;yum -y --skip-broken update "$@";);} function gitcommit { git commit -a --allow-empty-message -m '' "$@"; } +function git {(unset git;if [ "$1" = "checkout" ];then shift;git checkout --ignore-other-worktrees "$@";else git "$@";fi)} function gpg {(unset gpg; http_proxy= all_proxy= HTTP_PROXY= ALL_PROXY= gpg "$@"; );} function swap() {( set -ex;local TMPFILE=tmp.$$;[ $# = 2 ] && mv "$1" $TMPFILE && mv "$2" "$1" && mv $TMPFILE "$2" && echo done )} alias gthumb='rm -rf ~/.cache/thumbnails/fail/;gthumb' diff --git a/.gdbinit b/.gdbinit index 6d168c4..613d134 100644 --- a/.gdbinit +++ b/.gdbinit @@ -1,13 +1,3 @@ -add-auto-load-safe-path ~/src/stock -add-auto-load-safe-path ~/src/interview/.gdbinit -add-auto-load-safe-path ~/src/interview/asan/*-gdb.gdb -add-auto-load-safe-path ~/src/toptal.com-codility.com/.gdbinit -add-auto-load-safe-path ~/src/toptal.com-codility.com/asan/*-gdb.gdb -define bt - disable frame-filter all - backtrace -end - set break pending on set style enabled off # See .bashrc: export GDBHISTFILE="$HOME/.gdb_history" diff --git a/.mailcap b/.mailcap deleted file mode 100644 index ad4dd1d..0000000 --- a/.mailcap +++ /dev/null @@ -1,4 +0,0 @@ -# https://unix.stackexchange.com/a/42714/296319 -#text/html; (cp -p '%s' /tmp/$$.html\;chromium-freeworld /tmp/$$.html 2>/dev/null\;rm /tmp/$$.html)&; test=test -n "$DISPLAY"; needsterminal; -text/html; chromium-freeworld '%s' 2>/dev/null &; test=test -n "$DISPLAY"; nametemplate=%s.html; needsterminal; -text/html; lynx -dump $(: -width=$COLUMNS ) %s; nametemplate=%s.html; copiousoutput; diff --git a/.muttrc b/.muttrc index 74da566..09b4501 100644 --- a/.muttrc +++ b/.muttrc @@ -17,4 +17,3 @@ alias archer archer@sourceware.org alias binutils binutils@sourceware.org alias gccpat gcc-patches@gcc.gnu.org alias steph Marie Stephanie Kratochvilova -alias jacob Thomas Jacob diff --git a/.muttrc-gpg.rc b/.muttrc-gpg.rc index e69de29..aee3df2 100644 --- a/.muttrc-gpg.rc +++ b/.muttrc-gpg.rc @@ -0,0 +1,73 @@ +# -*-muttrc-*- +# +# Command formats for gpg. +# +# This version uses gpg-2comp from +# http://muppet.faveve.uni-stuttgart.de/~gero/gpg-2comp.tar.gz +# +# $Id$ +# +# %p The empty string when no passphrase is needed, +# the string "PGPPASSFD=0" if one is needed. +# +# This is mostly used in conditional % sequences. +# +# %f Most PGP commands operate on a single file or a file +# containing a message. %f expands to this file's name. +# +# %s When verifying signatures, there is another temporary file +# containing the detached signature. %s expands to this +# file's name. +# +# %a In "signing" contexts, this expands to the value of the +# configuration variable $pgp_sign_as. You probably need to +# use this within a conditional % sequence. +# +# %r In many contexts, mutt passes key IDs to pgp. %r expands to +# a list of key IDs. + +# decode application/pgp +set pgp_decode_command="gpg %?p?--passphrase-fd 0? --no-verbose --batch --output - %f" + +# verify a pgp/mime signature +set pgp_verify_command="gpg --no-verbose --batch --output - --verify %s %f" + +# decrypt a pgp/mime attachment +set pgp_decrypt_command="gpg --passphrase-fd 0 --no-verbose --batch --output - %f" + +# create a pgp/mime signed attachment +# set pgp_sign_command="gpg-2comp --no-verbose --batch --output - --passphrase-fd 0 --armor --detach-sign --textmode %?a?-u %a? %f" +set pgp_sign_command="gpg --no-verbose --compress-algo 1 --cipher-algo cast5 --batch --output - --passphrase-fd 0 --armor --detach-sign --textmode %?a?-u %a? %f" + +# create a application/pgp signed (old-style) message +# set pgp_clearsign_command="gpg-2comp --no-verbose --batch --output - --passphrase-fd 0 --armor --textmode --clearsign %?a?-u %a? %f" +set pgp_clearsign_command="gpg --no-verbose --compress-algo 1 --cipher-algo cast5 --batch --output - --passphrase-fd 0 --armor --textmode --clearsign %?a?-u %a? %f" + +# create a pgp/mime encrypted attachment +# set pgp_encrypt_only_command="pgpewrap gpg-2comp -v --batch --output - --encrypt --textmode --armor --always-trust -- -r %r -- %f" +set pgp_encrypt_only_command="pgpewrap gpg -v --compress-algo 1 --cipher-algo cast5 --batch --output - --encrypt --textmode --armor -- -r %r -- %f" +# --always-trust + +# create a pgp/mime encrypted and signed attachment +# set pgp_encrypt_sign_command="pgpewrap gpg-2comp --passphrase-fd 0 -v --batch --output - --encrypt --sign %?a?-u %a? --armor --always-trust -- -r %r -- %f" +set pgp_encrypt_sign_command="pgpewrap gpg --passphrase-fd 0 -v --compress-algo 1 --cipher-algo cast5 --batch --textmode --output - --encrypt --sign %?a?-u %a? --armor -- -r %r -- %f" +# --always-trust + +# import a key into the public key ring +set pgp_import_command="gpg --no-verbose --import -v %f" + +# export a key from the public key ring +set pgp_export_command="gpg --no-verbose --export --armor %r" + +# verify a key +set pgp_verify_key_command="gpg --no-verbose --batch --fingerprint --check-sigs %r" + +# read in the public key ring +set pgp_list_pubring_command="gpg --no-verbose --batch --with-colons --list-keys %r" + +# read in the secret key ring +set pgp_list_secring_command="gpg --no-verbose --batch --with-colons --list-secret-keys %r" + +# receive key from keyserver: +#set pgp_getkeys_command="wrap.sh -g %r" +set pgp_getkeys_command="" diff --git a/.screenrc b/.screenrc index 359a9a5..a2a56d1 100644 --- a/.screenrc +++ b/.screenrc @@ -150,29 +150,3 @@ bindkey -d -k kb stuff \010 # bind + resize +1 # bind - resize -1 # bind _ resize max - -# jankratochvil: -bindkey -t \033OP select 1 -bindkey -t \033OQ select 2 -bindkey -t \033OR select 3 -bindkey -t \033OS select 4 -bindkey -t \033[15~ select 5 -bindkey -t \033[17~ select 6 -bindkey -t \033[18~ select 7 -bindkey -t \033[19~ select 8 -bindkey -t \033[20~ select 9 -bindkey -t \033[21~ select 10 -bindkey -t \033[23~ select 11 -bindkey -t \033[24~ select 12 -bindkey -t \033O2P select 13 -bindkey -t \033O2Q select 14 -bindkey -t \033O2R select 15 -bindkey -t \033O2S select 16 -bindkey -t \033[15;2~ select 17 -bindkey -t \033[17;2~ select 18 -bindkey -t \033[18;2~ select 19 -bindkey -t \033[19;2~ select 20 -bindkey -t \033[20;2~ select 21 -bindkey -t \033[21;2~ select 22 -bindkey -t \033[23;2~ select 23 -bindkey -t \033[24;2~ select 24 diff --git a/bin/engine-di.fm b/bin/engine-di.fm index 8cefb64..45a9968 100755 --- a/bin/engine-di.fm +++ b/bin/engine-di.fm @@ -1,6 +1,6 @@ #! /usr/bin/perl # -# $Id: engine-di.fm,v 1.7 2008/05/08 09:08:23 lace Exp $ +# $Id$ use strict; use warnings; @@ -84,15 +84,14 @@ if ("build" eq ($ARGV[0]||"")) { my($site,$page)=@_; my @newdashed; - while ($page=~m{"(?:http://listen.$site)?([^":]*(?" if m{[^-a-zA-Z 0-9/:.@=_?]}; } for @list; + do { die "[$&] <$_>" if m{[^-a-zA-Z 0-9/:.@=]}; } for @list; system {"bash"} "bash","-c",join(" ",@list); exit 0 if $?; } diff --git a/bin/exx b/bin/exx index 8994599..97f021b 100755 --- a/bin/exx +++ b/bin/exx @@ -14,8 +14,6 @@ use constant FORMATS=>{ "rpm" =>'rpm2cpio $pathname|cpio -id --quiet', #-v #FIXME: --sparse doesn't work, why? "zip" =>'unzip -Lq $pathname', "jar" =>'unzip -Lq $pathname', - "xpi" =>'unzip -Lq $pathname', - "crx" =>'unzip -Lq $pathname', "a" =>'ar x $pathname', "deb" =>'ar x $pathname;' .'for i in *.tar.gz;do j=`basename $i .tar.gz`;mkdir -p $j;cd $j;tar xzf ../$i;cd ..;rm -f $i;done', diff --git a/bin/kernel/kernelkkfix b/bin/kernel/kernelkkfix index e6d03c2..1bf168a 100755 --- a/bin/kernel/kernelkkfix +++ b/bin/kernel/kernelkkfix @@ -1,8 +1,8 @@ #! /bin/bash # -# $Id: kernelkkfix,v 1.2 2005/05/12 10:21:26 short Exp $ +# $Id$ # -# Subst $Id: kernelkkfix,v 1.2 2005/05/12 10:21:26 short Exp $ -> $Id: kernelkkfix,v 1.2 2005/05/12 10:21:26 short Exp $ (as in cvs ... -kk) in all the subdirectories. +# Subst $Id$ -> $Id$ (as in cvs ... -kk) in all the subdirectories. # Required for proper diffing of CVSed Linux kernel sourcetrees. diff --git a/bin/taillog b/bin/taillog index f6a48e6..b58d0e0 100755 --- a/bin/taillog +++ b/bin/taillog @@ -1,2 +1,2 @@ #! /bin/bash -tail -fn0 $(file $(find /var/log $(cat ~/.taillog.addon 2>/dev/null) -name ntpstats -prune -o -type f -print)|grep -v 'data$'|sed 's/:.*//'|grep -v '^/var/log/squid/store.log$\|/.tmp$\|[.]gz$') "$@" +tail -fn0 `(file $(find /var/log -name ntpstats -prune -o -type f -print)|grep -v 'data$'|sed 's/:.*//'|grep -v '^\(/var/log/squid/store.log\|/var/log/acpid\|/var/log/btmp\|/var/log/maillog\)$';echo "$*"|tr ' ' '\n')|sort -u` # |grep -v ': bio too big device md3 (248 > 240)$' diff --git a/public_html/cgi-bin/idnes-foto b/public_html/cgi-bin/idnes-foto index 6ead9ce..2cd8e73 100755 --- a/public_html/cgi-bin/idnes-foto +++ b/public_html/cgi-bin/idnes-foto @@ -41,30 +41,7 @@ print <<"EOH"; EOH -$BASE=~m{^http://\w+\Q.idnes.cz/foto.asp\Ex?[?](?:r=[-_\w]+&c=[-_\w]+|c=[-_\w]+&r=[-_\w]+)$} or $BASE=""; - - -my $ua=LWP::UserAgent->new(); -$ua->env_proxy(); -$ua->requests_redirectable([]); - -#sub webget($) -#{ -# my($url)=@_; -# -# my $resp=$ua->get($url); -# if ($resp->is_redirect()) { -# my $relurl=$resp->header("Location"); -# $relurl=~m{^foto.*[?]} or die; -# $url=~s{[^/]*$}{}; -# $url.=$relurl; -# warn "Redirect to: $url\n"; -# $resp=$ua->get($url); -# } -# $resp->is_success() or die $url; -# return $resp->decoded_content(); -#} - +$BASE=~m{^http://\w+\Q.idnes.cz/foto.asp?\E(?:r=[-_\w]+&c=[-_\w]+|c=[-_\w]+&r=[-_\w]+)$} or $BASE=""; if ($BASE) { my $pageno=1; my %seen; @@ -73,43 +50,7 @@ PAGES: for (;;) { my $pageurl=$BASE.'&strana='.$pageno; my $page=LWP::Simple::get($pageurl) or die $pageurl; my $did=0; - my $aspx=0; - while ($page=~m{"&]*(?:&inframe=1)?)"(?: target="foto-iframe")?>}gi) { - my $relurl=$1; - $relurl=~s{&}{&}g; - my $frameurl=$BASE; - $frameurl=~s{[?].*}{}; - $frameurl.=$relurl; - my $frame=LWP::Simple::get($frameurl) or die $frameurl; - if ($frame=~m{