Skip to content

Instantly share code, notes, and snippets.

View mauvehed's full-sized avatar
:shipit:
hax.

mauvehed mauvehed

:shipit:
hax.
View GitHub Profile
@mauvehed
mauvehed / revert_last_git_commit.sh
Created October 21, 2023 21:38
Revert last git commit
git reset --hard HEAD~1
@mauvehed
mauvehed / poetry_export_reqs_wo_hash.sh
Created December 19, 2022 04:01
Poetry Export without Hashes
poetry export --without-hashes --format=requirements.txt > requirements.txt
@davidedmundson
davidedmundson / PlasmaNested.sh
Last active May 2, 2024 10:37
Run plasma from within gamescope
#!/bin/sh
# Remove the performance overlay, it meddles with some tasks
unset LD_PRELOAD
## Shadow kwin_wayland_wrapper so that we can pass args to kwin wrapper
## whilst being launched by plasma-session
mkdir $XDG_RUNTIME_DIR/nested_plasma -p
cat <<EOF > $XDG_RUNTIME_DIR/nested_plasma/kwin_wayland_wrapper
#!/bin/sh
@todb-r7
todb-r7 / fedifinder_following_accounts.csv
Last active November 11, 2022 21:06
Twitter Cybers List
Account address Show boosts
todb@mastodon.social true
intidc@mastodon.social true
thorsheim@mastodon.social true
molly0xfff@mastodon.social true
foone@mastodon.social true
eddie1perez@mastodon.social true
savagejen@mastodon.social true
podsothoth@mastodon.social true
viss@mastodon.social true
@mauvehed
mauvehed / ssh-key fingerprint.md
Last active November 23, 2022 17:02
Generate the crypto fingerprint of an SSH key

Generate SSH-KEY fingerprints

The New Way (SHA256)

ssh-keygen -l -f /path/to/id_rsa

The Old Way (MD5)

ssh-keygen -l -E md5 -f /path/to/id_rsa

@mauvehed
mauvehed / tmux-cheatsheet.markdown
Created September 20, 2022 15:39 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname
@mauvehed
mauvehed / Fail2ban Debian-based Config.md
Last active February 23, 2023 13:47
Fail2ban Debian-based Config

Fail2ban Configuration

The default Fail2ban installation comes with two configuration files, /etc/fail2ban/jail.conf and /etc/fail2ban/jail.d/defaults-debian.conf. It is not recommended to modify these files as they may be overwritten when the package is updated.

Fail2ban reads the configuration files in the following order. Each .local file overrides the settings from the .conf file:

  • /etc/fail2ban/jail.conf
  • /etc/fail2ban/jail.d/*.conf
  • /etc/fail2ban/jail.local
  • /etc/fail2ban/jail.d/*.local
@mauvehed
mauvehed / Ubuntu - Enable Autoupdates.md
Last active November 23, 2022 17:02
Ubuntu - Enable Autoupdates

Execute the following command to update a server

sudo apt update && sudo apt upgrade

Now, install the unattended upgrade on your Ubuntu system through the following command:

sudo apt install unattended-upgrades apt-listchanges bsd-mailx

After that, turn on the unattended security updates by running the following command:

@mauvehed
mauvehed / Ubuntu LTS Upgrade via CLI.md
Last active November 23, 2022 17:02
Ubuntu LTS Upgrade via CLI
@Zate
Zate / docker-compose.yaml
Created May 3, 2022 15:37
Valheim docker-compose.yaml
version: "3"
services:
valheim:
image: mbround18/valheim:latest
ports:
- "2456:2456/udp"
- "2457:2457"
- "2458:2458/udp"
environment:
PORT: 2456