moved all of my config into this nix flake

This commit is contained in:
Sebastian Moser
2023-10-28 19:10:37 +02:00
parent 9facde9d3a
commit 112ef46fd2
46 changed files with 3545 additions and 0 deletions

58
mybin/mvn Executable file
View File

@@ -0,0 +1,58 @@
#!/bin/bash
#revert:
#svn st | grep ^D | cut -c 9- | sed 's/^/"/' | sed 's/$/"/' | xargs svn revert -R
#svn st | grep ^A | cut -c 9- | sed 's/^/"/' | sed 's/$/"/' | xargs svn revert -R
if [ "$1" == "cut" ]
then
cut -c 9- | sed 's/^/"/' | sed 's/$/"/'
fi
if [ "$1" == "e" ]
then
if [ "$2" == "" ]
then
export SVN_EDITOR=nvim
echo "DONE: export SVN_EDITOR=nvim"
else
export SVN_EDITOR=nvim
svn propedit svn:ignore $2
fi
fi
if [ "$1" == "ignore" ]
then
if [ -t 0 ]
then
echo
else
# have a pipe
cat >> ./svn-ignore
fi
# do if no or some pipe ... apply the things in the svn-ignore file
cat ./svn-ignore | tr -d '"' | sed 's/$/\/../' | xargs svn propdel svn:ignore 1>/null
cat ./svn-ignore | tr -d '"' | sed 's\^\./\' | while read p; do
name=$(echo -en "$p" | tr "/" "\n" | tail -n 1)
path=${p%/*}
prop=$(svn propget svn:ignore $path)
svn propset svn:ignore "${prop}"$'\n'"${name}" $path
echo prop: $prop
echo path: $path
done
fi
if [ "$1" == "up" ]
then
echo "-----------------------------------------------------------------"
svn st | grep ^? | cut -c 9- | sed 's/^/"/' | sed 's/$/"@/' | xargs svn add
svn st | grep ^! | cut -c 9- | sed 's/^/"/' | sed 's/$/"@/' | xargs svn rm
echo "-----------------------------------------------------------------"
svn ci -m "$2"
fi