diff --git a/fish/config.fish b/fish/config.fish index d2246c9..6511ccf 100644 --- a/fish/config.fish +++ b/fish/config.fish @@ -4,3 +4,4 @@ end set fish_greeting alias l "ls -hAGg" +fish_add_path /home/crispypin/bin/scripts diff --git a/fish/fish_variables b/fish/fish_variables index a367aca..103c3c2 100644 --- a/fish/fish_variables +++ b/fish/fish_variables @@ -30,3 +30,4 @@ SETUVAR fish_pager_color_description:B3A06D\x1eyellow SETUVAR fish_pager_color_prefix:normal\x1e\x2d\x2dbold\x1e\x2d\x2dunderline SETUVAR fish_pager_color_progress:brwhite\x1e\x2d\x2dbackground\x3dcyan SETUVAR fish_pager_color_selected_background:\x2dr +SETUVAR fish_user_paths:/home/crispypin/bin/scripts diff --git a/install.conf.yaml b/install.conf.yaml index 500c2f0..5a74d50 100644 --- a/install.conf.yaml +++ b/install.conf.yaml @@ -21,6 +21,7 @@ ~/.config/kitty/kitty.conf: kitty.conf ~/.config/btop/btop.conf: btop.conf ~/.config/mpv: mpv + ~/bin/scripts: scripts - create: - ~/downloads diff --git a/scripts/GPU_VR.sh b/scripts/GPU_VR.sh new file mode 100755 index 0000000..eedd32d --- /dev/null +++ b/scripts/GPU_VR.sh @@ -0,0 +1,4 @@ +#!/bin/bash +echo 4 > /sys/class/drm/card0/device/pp_power_profile_mode +echo "Set GPU to VR power profile mode" + diff --git a/scripts/GPU_VR_off.sh b/scripts/GPU_VR_off.sh new file mode 100755 index 0000000..80d164e --- /dev/null +++ b/scripts/GPU_VR_off.sh @@ -0,0 +1,4 @@ +#!/bin/bash +echo 0 > /sys/class/drm/card0/device/pp_power_profile_mode +echo "Set GPU to DEFAULT power profile mode" + diff --git a/scripts/arch_setup.sh b/scripts/arch_setup.sh new file mode 100755 index 0000000..143764f --- /dev/null +++ b/scripts/arch_setup.sh @@ -0,0 +1,51 @@ +#!/bin/sh + +# installs most of the stuff I need in arch, may make it more flexible in the future + +cd ~ + +sudo pacman -S --needed git neovim base-devel + +git clone https://aur.archlinux.org/yay-bin.git +cd yay-bin +makepkg -si +cd ~ + +yay + +yay -S --needed xorg-server xf86-video-amdgpu awesome picom xcape numlockx polkit-gnome \ +lxappearance dracula-gtk-theme ly \ +noto-fonts-emoji ttf-comic-mono-git wqy-zenhei \ +lshw sshfs xdg-user-dirs xdg-utils fuse \ +fish fastfetch pfetch cpupower \ +pulseaudio ncpamixer alsa-utils \ +pcmanfm vscodium-bin ffmpeg alacritty kitty meld cloc \ +maim xclip slop xdotool \ +firefox discord spotify + +mkdir -p .config +git clone https://github.com/crispypin/awesomewm-config .config/awesome + +mkdir -p archive bin documents downloads music pictures proj temp uni videos .templates .desktop + +cd proj +git clone https://github.com/crispypin/crispypin +cp -f crispypin/config/user-dirs.dirs ~/.config/ +xdg-user-dirs-update +rmdir Desktop/ Downloads/ Documents/ Pictures/ Music/ Videos/ Templates/ Public/ + + +yay -S --needed \ +steam obs-studio-git linux-headers v4l2loopback-dkms \ +blender btop godot gimp \ +mpv feh yt-dlp file-roller \ +redshift element-desktop gnome-keyring trash-cli \ +gvfs-gphoto2 gvfs-mtp jmtpfs + +# for building apriltags +yay -S --needed gst-plugins-good +sudo ln -s /usr/bin/make /usr/bin/gmake +sudo ln -s /usr/lib/glib-2.0/include/glibconfig.h /usr/include/glib-2.0/glibconfig.h + + +timedatectl set-ntp true diff --git a/scripts/camera_mode_normal.sh b/scripts/camera_mode_normal.sh new file mode 100755 index 0000000..2e53c11 --- /dev/null +++ b/scripts/camera_mode_normal.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +v4l2-ctl -c exposure_auto=3 + +v4l2-ctl -c brightness=127 + +v4l2-ctl -c contrast=5 + +#does this make a difference? +v4l2-ctl -c sharpness=25 + + + diff --git a/scripts/camera_mode_track.sh b/scripts/camera_mode_track.sh new file mode 100755 index 0000000..e22305f --- /dev/null +++ b/scripts/camera_mode_track.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +v4l2-ctl -c auto_exposure=1 + +v4l2-ctl -c exposure_time_absolute=39 + +v4l2-ctl -c brightness=255 + +v4l2-ctl -c contrast=10 + +#does this make a difference? +#v4l2-ctl -c sharpness=50 + + + diff --git a/scripts/ffgif.sh b/scripts/ffgif.sh new file mode 100755 index 0000000..2fa5a6c --- /dev/null +++ b/scripts/ffgif.sh @@ -0,0 +1,6 @@ +#!/bin/bash +echo making gif from $1 +echo +ffmpeg -i $1 -filter_complex "[0:v] palettegen" $1.palette.png +ffmpeg -i $1 -i $1.palette.png -filter_complex "[0:v][1:v] paletteuse" $1.gif +rm $1.palette.png diff --git a/scripts/vrc-compressor.py b/scripts/vrc-compressor.py new file mode 100755 index 0000000..1b48e3d --- /dev/null +++ b/scripts/vrc-compressor.py @@ -0,0 +1,37 @@ +#!/bin/env python3 +import time +import datetime +import os +from subprocess import call + + +ROOT_DIR = "/home/crispypin/pictures/VRChat/" +MAX_SIZE = 8 * 1024 * 1024 + +PROCESSED = [] + +def delay(seconds=30): + # delay that can be keyboard interrupted + for _ in range(10*seconds): + time.sleep(0.1) + +def scan(): + print("scanning") + date = datetime.datetime.now() + month = f"{date.year}-{date.month:02d}/" + path = ROOT_DIR + month + print(f"checking {path}") + items = os.listdir(path) + # print(items) + for f in items: + if os.path.isfile(path + f): + if os.path.getsize(path + f) > MAX_SIZE and f not in PROCESSED: + # input(f) + call(f"convert {f} temp.{f}", cwd=path, shell=True) + call(f"mv temp.{f} {f}", cwd=path, shell=True) + PROCESSED.append(f) + +while True: + scan() + delay(60) + diff --git a/vscodium.json b/vscodium.json index 137eb0a..b505e92 100644 --- a/vscodium.json +++ b/vscodium.json @@ -39,5 +39,6 @@ "C_Cpp.renameRequiresIdentifier": false, "window.zoomLevel": 1, "editor.renderWhitespace": "all", - "terminal.integrated.fontFamily": "monospace" + "terminal.integrated.fontFamily": "monospace", + "markdown.preview.fontFamily": "sans" } \ No newline at end of file