This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Copyright (c) 2020-2024 Hetzner Online GmbH | |
| Copyright (c) 2026 Christopher Bock <christopher@bocki.com> | |
| Permission is hereby granted, free of charge, to any person obtaining | |
| a copy of this software and associated documentation files (the | |
| “Software”), to deal in the Software without restriction, including | |
| without limitation the rights to use, copy, modify, merge, publish, | |
| distribute, sublicense, and/or sell copies of the Software, and to | |
| permit persons to whom the Software is furnished to do so, subject to | |
| the following conditions: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # ok so how this shit works: | |
| # it launches playerctl command that watches for changes | |
| # every time there's a change it sends fzf an event | |
| # fzf then executes omega cursed preview command | |
| # aint going to explain how it works but yeah | |
| # | |
| # <cb> /me did some changes here and there /(°o°)\ | |
| # <cb> btw, chafa should detect -f by it's own. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ################################################################################ | |
| # TOPRE 104UB / 87U / XF111T0 / REALFORCE BREAKS DOWN AFTER BIOS | |
| # And when replugging the keyboard it only lights up shortly and the log shows | |
| # something like this: | |
| # | |
| # Dec 31 11:26:31 kernel: usb 1-8: unable to read config index 0 descriptor/start: -32 | |
| # Dec 31 11:26:31 kernel: usb 1-8: can't read configurations, error -32 | |
| # Dec 31 11:26:31 kernel: usb 1-8: unable to read config index 0 descriptor/start: -32 | |
| # Dec 31 11:26:31 kernel: usb 1-8: can't read configurations, error -32 | |
| # Dec 31 11:26:31 kernel: usb 1-8: unable to read config index 0 descriptor/start: -32 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| #set -x | |
| SCRIPT_BUILD=202411254 | |
| GROMOX_MAILDIR_PATH="$(grommunio-admin config get options.userPrefix)" | |
| SOFTDELETE_TIMESTAMP=${SOFTDELETE_TIMESTAMP:-30d20h} | |
| function TrapQuit { | |
| local exitcode=0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [[Snippets]] | |
| Description = "zpool list (real space)" | |
| Output = "" | |
| Tag = ["truenas", "zfs"] | |
| command = "zfs list -o space,refer,lrefer,quota,refquota -d0" | |
| [[Snippets]] | |
| Description = "truenas upgrade all jails to latest" | |
| Output = "" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $DiskSpd = "$PSScriptRoot\DiskSpd\$($Env:PROCESSOR_ARCHITECTURE.ToLower())\diskspd.exe" | |
| if ( -Not ( Test-Path $DiskSpd ) ) { | |
| # Destination will be the directory of the script + 'DiskSpd' | |
| $destdir = "$PSScriptRoot" | |
| $tempdir = "$env:TEMP" | |
| New-Item -Type Directory -Path $tempdir -ErrorAction Ignore | |
| $file = "DiskSpd.ZIP" | |
| $tempfile = Join-Path -Path "$tempdir" -ChildPath "$file" | |
| Set-Location -Path $tempdir | |
| $repo = "microsoft/diskspd" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # v=0.5 2023-06-06 | |
| # ~cb | |
| # | |
| # # TMUX | |
| # cat << EOTMUX >> ~/.tmux.conf | |
| # # TrueNAS MIDCLT-QUERYs | |
| # bind-key C-t popup -E tmux-midclt | |
| # EOTMUX |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| modprobe zfs || exit | |
| apt-get update | |
| apt-get install ntpdate jq --yes | |
| ntpdate-debian | |
| #zpool export -f bpool | |
| #zpool export -f rpool | |
| #swapoff --all | |
| #mount |awk '/\/mnt/ {print $3}'|xargs -n 1 umount 2>/dev/null |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/sh | |
| ROOT="p0/bak/home" | |
| frequently=4 | |
| hourly=36 | |
| daily=30 | |
| monthly=3 | |
| _remove_old_snaps() { | |
| COUNT=$(echo "{$1}" |wc -l) | |
| #echo "COUNT: ${COUNT}" | |
| if [ "$COUNT" -gt "$2" ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ## vim: filetype=sh | |
| # FARBSPIELE # | |
| RED='\033[0;31m' | |
| GREEN='\033[0;32m' | |
| YELLOW='\033[0;33m' | |
| BLUE='\033[0;34m' | |
| NC='\033[0m' # No Color | |
| function red { printf "${RED}$@${NC}\n" ; } | |
| function green { printf "${GREEN}$@${NC}\n" ; } |
NewerOlder