move from stow to chezmoi

This commit is contained in:
2025-09-29 11:40:54 +02:00
commit 04f8de3573
51 changed files with 420 additions and 0 deletions

View File

@@ -0,0 +1,36 @@
#!/bin/bash
function install() {
name=$1
src_dir=$2
mkdir -p /usr/share/fonts/$name
cp $src_dir/*.ttf /usr/share/fonts/$name/
chmod 0775 /usr/share/fonts/$name
chmod 0664 /usr/share/fonts/$name/*
}
function help() {
echo "$0 <font name> <sorce dir>"
}
if [[ -z "$1" ]]; then
help
exit
fi
if [[ -z "$2" ]]; then
echo "ERROR: give at least two arguments"
echo
help
exit
fi
if [[ ! -d "$2" ]]; then
echo "ERROR: $2 is not a directory"
echo
help
exit
fi
install $1 "$2"

View File

@@ -0,0 +1,44 @@
#!/bin/bash
token="$1"
page=1
project_dir="$HOME/projects"
base_url="https://gitea.finnvanreenen.nl/api/v1"
git_url="git@gitea.finnvanreenen.nl"
while [[ $page -lt 50 ]]
do
# echo
echo "## get repo list page $page"
repos="$(curl -X 'GET' "$base_url/user/repos?page=$page&token=$token" -H 'accept: application/json')"
login="$(echo "$repos" | sed -e 's/^.*"login":"\([^"]*\)".*$/\1/')"
if [[ "$repos" != "[]" ]]
then
for repo in $(echo "$repos" | sed -e 's/^\[{//' -e 's/}]$//' -e 's/},{/\n/g' -e 's/%/%p/g' -e 's/ /%20/g')
do
repo_json="$(echo "$repo" | sed -e 's/%20/ /g' -e 's/%p/%/g')"
full_name="$(echo "$repo_json" | sed -e 's/^.*"full_name":"\([^"]*\)".*$/\1/')"
clone_url="$(echo "$repo_json" | sed -e 's/^.*"clone_url":"\([^"]*\)".*$/\1/')"
echo
echo "### ${full_name,,}"
if [ -d "$project_dir/${full_name,,}" ]
then
cd "$project_dir/${full_name,,}"
# git fetch
else
url="$(echo "$clone_url" | sed "s|://|://$login:$token@|")"
git clone "$url" "$project_dir/${full_name,,}"
git -C "$project_dir/${full_name,,}" remote set-url origin "$git_url:${full_name,,}.git"
fi
done
else
echo "No more repositories found."
page=999
fi
page="$(( $page + 1 ))"
done

View File

@@ -0,0 +1,7 @@
#!/bin/bash
font="$(fc-list | fzf)"
echo "$font"
display "$(echo "$font" | awk '{{ print $1 }}' | tr -d ':')"

View File

@@ -0,0 +1,3 @@
#!/bin/bash
git log --graph --oneline --all

View File

@@ -0,0 +1,4 @@
#/bin/bash
rclone sync pdrive: "/mnt/backup/proton/" --verbose --progress \
--filter-from "$HOME/.config/rclone/bisync_backup.filter" $*

View File

@@ -0,0 +1,4 @@
#/bin/bash
rclone bisync "$HOME/Documents" pdrive:Documents --verbose --progress \
--filter-from "$HOME/.config/rclone/bisync_documents.filter" $*

View File

@@ -0,0 +1,4 @@
#/bin/bash
rclone bisync "$HOME" pdrive: --verbose --progress \
--filter-from "$HOME/.config/rclone/bisync_home.filter" $*

View File

@@ -0,0 +1,3 @@
#/bin/bash
rclone bisync "$HOME/Music" pdrive:Music --verbose --progress $*

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!xdg-download

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!xdg-download

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!xdg-download;!xdg-videos;/run/media;/mnt/media

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=xdg-videos

View File

@@ -0,0 +1,3 @@
[Context]
devices=!all;dri
filesystems=xdg-config/PrusaSlicer;~/projects

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects/hr/pee51_gan_motor_driver

View File

@@ -0,0 +1,3 @@
[Context]
features=!bluetooth
filesystems=!xdg-run/app/com.discordapp.Discord

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=xdg-documents/git

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!xdg-desktop

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/mnt/media/

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=xdg-download;!home;!host

View File

@@ -0,0 +1,2 @@
[Context]
persistent=~/.local/share/vdhcoapp/vdhcoapp

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!xdg-download;!xdg-run/app/com.discordapp.Discord;!/run/media;!/mnt;!/media;~/projects/freenen/kladjes

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects:ro

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects

View File

@@ -0,0 +1,2 @@
[Context]
devices=!all

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/vdhcoapp:ro;~/projects:ro;~/.local/tiCloudAgent;~/.local/share/vdhcoapp;

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=/home/freenen/.local/share/fonts:ro;xdg-documents

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=~/projects

View File

@@ -0,0 +1,2 @@
[Context]
filesystems=!/media