Added many different things
This commit is contained in:
@@ -208,3 +208,18 @@ end
|
||||
if test -e /usr/bin/sudo-rs
|
||||
alias sudo=sudo-rs
|
||||
end
|
||||
|
||||
#### SOURCE of bash
|
||||
|
||||
function smart_source
|
||||
set file $argv[1]
|
||||
|
||||
if string match -q "*.bash" -- $file
|
||||
bass source $file
|
||||
else if string match -q "*.fish" -- $file
|
||||
builtin source $file
|
||||
else
|
||||
# fallback: try fish source by default
|
||||
builtin source $file
|
||||
end
|
||||
end
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
# ~/.config/fish/configs/arch_config.fish
|
||||
#
|
||||
|
||||
source $HOME/.config/fish/configs/uni.fish
|
||||
|
||||
alias git_update='$HOME/.config/fish/scripts/git-update.sh'
|
||||
|
||||
alias mount_all='$HOME/.config/fish/scripts/mount.sh'
|
||||
@@ -12,9 +14,15 @@ alias print_cam='ssh honney@192.168.1.184'
|
||||
function updateall
|
||||
# Get current Discord version (if installed)
|
||||
if pacman -Q discord >/dev/null 2>&1
|
||||
set version_before (pacman -Q discord)
|
||||
set discord_version_before (pacman -Q discord)
|
||||
else
|
||||
set version_before ""
|
||||
set discord_version_before ""
|
||||
end
|
||||
|
||||
if pacman -Q linux-zen >/dev/null 2>&1
|
||||
set kernel_version_before (pacman -Q linux-zen)
|
||||
else
|
||||
set kernel_version_before ""
|
||||
end
|
||||
|
||||
# Run updates
|
||||
@@ -22,20 +30,39 @@ function updateall
|
||||
|
||||
# Get new Discord version (if installed)
|
||||
if pacman -Q discord >/dev/null 2>&1
|
||||
set version_after (pacman -Q discord)
|
||||
set discord_version_after (pacman -Q discord)
|
||||
else
|
||||
set version_after ""
|
||||
set discord_version_after ""
|
||||
end
|
||||
|
||||
# Compare versions
|
||||
if test "$version_before" != "$version_after"
|
||||
echo "Discord version changed: $version_before -> $version_after"
|
||||
if test "$discord_version_before" != "$discord_version_after"
|
||||
echo "Discord version changed: $discord_version_before -> $discord_version_after"
|
||||
echo "Running extra command..."
|
||||
sh -c "$(curl -sS https://raw.githubusercontent.com/Vendicated/VencordInstaller/main/install.sh)"
|
||||
end
|
||||
|
||||
flatpak update
|
||||
yay -Sua --sudoloop
|
||||
paru -Sua --sudoloop
|
||||
|
||||
# Get new Discord version (if installed)
|
||||
if pacman -Q linux-zen >/dev/null 2>&1
|
||||
set kernel_version_after (pacman -Q linux-zen)
|
||||
else
|
||||
set kernel_version_after ""
|
||||
end
|
||||
if test "$kernel_version_before" != "$kernel_version_after"
|
||||
echo "Discord version changed: $kernel_version_before -> $kernel_version_after"
|
||||
echo -n "Reboot now? [y/N]: "
|
||||
|
||||
read answer
|
||||
|
||||
if test "$answer" = "y" -o "$answer" = "Y"
|
||||
reboot
|
||||
else
|
||||
echo "Skipping reboot."
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
alias big='expac -H M "%m\t%n" | sort -h | nl' # Sort installed packages according to size in MB (expac must be installed)
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
# Load pywal colors (extract from ~/.cache/wal/colors.json)
|
||||
if test -e $HOME/.cache/wal/colors.json
|
||||
if test -e $HOME/.cache/wal/colors.json1
|
||||
set -g theme_0 (jq -r '.colors.color0' ~/.cache/wal/colors.json) # Primary color
|
||||
set -g theme_1 (jq -r '.colors.color1' ~/.cache/wal/colors.json) # Secondary color (e.g., for git, @)
|
||||
set -g theme_2 (jq -r '.colors.color2' ~/.cache/wal/colors.json) # Third color (e.g., for hostname)
|
||||
|
||||
@@ -4,3 +4,5 @@
|
||||
|
||||
alias updateall='sudo apt upgrade -y && sudo apt update -y'
|
||||
alias uninstall='sudo apt purge -y'
|
||||
|
||||
source $HOME/.config/fish/configs/uni.fish
|
||||
|
||||
@@ -0,0 +1,19 @@
|
||||
if test -x /usr/bin/pacman
|
||||
if test -d ~/Nextcloud/UNI/26_TI/RISC-V
|
||||
set -U fish_user_paths ~/mount/Storage/Nextcloud/UNI/26_TI/RISC-V/xpack-riscv-none-elf-gcc-15.2.0-1-linux-x64/xpack-riscv-none-elf-gcc-15.2.0-1/bin $fish_user_paths
|
||||
set -U fish_user_paths ~/mount/Storage/Nextcloud/UNI/26_TI/RISC-V/verible-v0.0-4053-g89d4d98a-linux-static-x86_64/verible-v0.0-4053-g89d4d98a/bin $fish_user_paths
|
||||
end
|
||||
if test -d ~/projects/RISC-V
|
||||
set -gx XILINX_VIVADO ~/projects/RISC-V/vivado/Vivado/2022.2
|
||||
set -U fish_user_paths ~/projects/RISC-V/vivado/Vivado/2022.2/bin $fish_user_paths
|
||||
set -gx LM_LICENSE_FILE ~/projects/RISC-V/intel/LR-160568_License.dat
|
||||
set -gx SALT_LICENSE_SERVER $LM_LICENSE_FILE
|
||||
set -U fish_user_paths ~/projects/RISC-V/intel/questa_fse/bin $fish_user_paths
|
||||
end
|
||||
end
|
||||
|
||||
set in_container (test -f /.dockerenv; or test -f /run/.containerenv; and echo yes; or echo no)
|
||||
|
||||
if test "in_container" = yes
|
||||
echo "In Container"
|
||||
end
|
||||
Reference in New Issue
Block a user