Skip to content

Instantly share code, notes, and snippets.


[?25l[?7l -/oyddmdhs+:.
-odNMMMMMMMMNNmhy+-`  .
-yNMMMMMMMMMMMNNNmmdhy+-  .vir. d$b
`omMMMMMMMMMMMMNmdmmmmddhhy/`  .d$$$$$$b. .cd$$b. .d$$b. d$$$$$$$$$$$b .d$$b. .d$$b.
omMMMMMMMMMMMNhhyyyohmdddhhhdo`  $$$$( )$$$b d$$$()$$$. d$$$$$$$b Q$$$$$$$P$$$P.$$$$$$$b. .$$$$$$$b.
.ydMMMMMMMMMMdhs++so/smdddhhhhdm+`  Q$$$$$$$$$$B$$$$$$$$P" d$$$PQ$$$$b. $$$$. .$$$P' `$$$ .$$$P' `$$$
oyhdmNMMMMMMMNdyooydmddddhhhhyhNd.  "$$$$$$$P Q$$$$$$$b d$$$P Q$$$$b $$$$b $$$$b..d$$$ $$$$b..d$$$
:oyhhdNNMMMMMMMNNNmmdddhhhhhyymMh  | d$$$$$$P" "$$$$$$$$ Q$$$
program="BEGIN{prev = \"\"} \
\
/^# file: / {\
prev = substr(\$0, 9)\
}\
\
/$2/ {\
print prev;\
prev=\"\"\
}\
#!/usr/bin/env python
# Based on https://www.openwall.com/lists/oss-security/2018/08/16/1
# untested CVE-2018-10933
import sys, paramiko
import logging
username = sys.argv[1]
hostname = sys.argv[2]
command = sys.argv[3]
@crabdancing
crabdancing / minecraft.sh
Created August 3, 2018 23:43
Minecraft Launcher alternative with no bullshit calling home
#!/usr/bin/env bash
# Copyleft (C) Alexandria Pettit
# GNU GPL v3
# This is a script to load Minecraft on Linux machines without using Mojang's crappy launcher.
# It is currently pretty much unusable for anyone but me, but I'm going to hopefully fix that soon!
# it'll require quite a lot of reverse engineering however.
# TODO: figure out how to better dynamicize .jar lib loading
@dideler
dideler / bot.rb
Last active April 17, 2024 08:40
Sending a notification message to Telegram using its HTTP API via cURL
# Use this script to test that your Telegram bot works.
#
# Install the dependency
#
# $ gem install telegram_bot
#
# Run the bot
#
# $ ruby bot.rb
#
@vonNiklasson
vonNiklasson / sublime3-disable-zoom.sh
Last active March 7, 2022 13:44
Disable scroll zoom in Sublime 3, by Hugh Perkins from https://superuser.com/a/1121238
cat <<EOF>~/.config/sublime-text-3/Packages/User/"Default (Linux).sublime-mousemap"
[
// Change font size with ctrl+scroll wheel
{ "button": "scroll_down", "modifiers": ["ctrl"], "command": "null" },
{ "button": "scroll_up", "modifiers": ["ctrl"], "command": "null" }
]
EOF
@estorgio
estorgio / Mounting VirtualBox shared folders on Ubuntu Server 16.04 LTS.md
Last active March 8, 2024 17:34
Mounting VirtualBox shared folders on Ubuntu Server 16.04 LTS

Update 28 July 2019: An updated version of this guide for Ubuntu Server 18.04 LTS is now available. Feel free to check it out.

Update 23 May 2020: This guide is ALREADY OUTDATED and might no longer work with new versions of Ubuntu and VirtualBox. Please consider switching to the updated guide instead. I will no longer respond to the replies to this gist. Thank you.

Mounting VirtualBox shared folders on Ubuntu Server 16.04 LTS

This guide will walk you through steps on how to setup a VirtualBox shared folder inside your Ubuntu Server guest. Tested on Ubuntu Server 16.04.3 LTS (Xenial Xerus)

@varhub
varhub / Android - Enable ADB from recovery.md
Created December 23, 2016 17:54
Android - Enable ADB from recovery

Android - Enable ADB from recovery

Credits to @TheOnlyAnil-@Firelord[^stackoverflow]

  • Requirements: a) stock recovery + rooted phone b) custom recovery

  • Files changed:

@pawelszydlo
pawelszydlo / transmission_remove_finished.sh
Last active April 20, 2024 13:35
Script to clear finished torrents from transmission-daemon
#!/bin/bash
# Clears finished downloads from Transmission.
# Version: 1.1
#
# Newest version can always be found at:
# https://gist.github.com/pawelszydlo/e2e1fc424f2c9d306f3a
#
# Server string is resolved in this order:
# 1. TRANSMISSION_SERVER environment variable
@haasn
haasn / about:config.md
Last active April 2, 2024 18:46
Firefox bullshit removal via about:config

Firefox bullshit removal

Updated: Just use qutebrowser (and disable javascript). The web is done for.