Skip to content

Instantly share code, notes, and snippets.

View BrainStone's full-sized avatar

Yannick Schinko BrainStone

View GitHub Profile
BrainStone /
Created October 11, 2022 15:12
A simple script that fixes messed up terminal when sending SIGINT to scriptreplay
function scriptreplay () {
# Start a subshell to remove the trap in every case and to prevent the exit command from ending the parent shell
function _restore () {
# Reset terminal without losing scrollback
reset -I
# Exit subshell
View .gitignore
View gist:03b73f719ee5afe6bc8290b466c242ab
alias certbot_cert='certbot certonly --webroot --rsa-key-size 4096 -w /var/www/html'
View ssl.conf
# Einige Optionen nach Bettercrypto
ssl_prefer_server_ciphers on;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
add_header Strict-Transport-Security max-age=15768000;
ssl_session_timeout 30m;
#ssl_dhparam /etc/ssl/nginx/dhparams.pem;
View proxy_ssl_only
server {
listen [2001:41d0:1004:75::]:80;
server_name <subdomain> *.<subdomain>;
root /var/www/html;
location /.well-known {
# Just to prevent the redirect
View gist:701018096ff8c86258c4d5772443bf5f
Chain INPUT (policy ACCEPT)
target prot opt source destination
DROP tcp -- ! tcp dpts:20000:20199
f2b-sshd-month tcp -- multiport dports 22
f2b-sshd-week tcp -- multiport dports 22
f2b-sshd tcp -- multiport dports 22
DROP tcp -- ! tcp dpts:20000:20199
ufw-before-logging-input all --
ufw-before-input all --
ufw-after-input all --
View crash-2018-04-20_20.50.21-server.txt
---- Minecraft Crash Report ----
WARNING: coremods are present:
OpenEyePlugin (OpenEye-1.12.1-0.8.jar)
SpongeCoremod (spongeforge-1.12.2-2655-7.1.0-BETA-3025.jar)
Contact their authors BEFORE contacting forge
// I'm sorry, Dave.
Time: 4/20/18 8:50 PM
BrainStone / error.txt
Created July 18, 2017 18:38
Error that appears when running `./gradlew cleanCache clean setupDecompWorkspace eclipse --refresh-dependencies`
View error.txt
This file has been truncated, but you can view the full file.
./gradlew : Patching failed: minecraft\net\minecraft\command\
In Zeile:1 Zeichen:1
+ ./gradlew cleanCache clean setupDecompWorkspace eclipse --refresh-dep ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (Patching [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError
Hunk 1 failed! Cannot find hunk target
BrainStone / Makefile
Last active April 5, 2017 14:37
Super generic Makefile for C++
View Makefile
# Must be either executable, dynamic_library or static_library
# Defaults to executable if a wrong value is used!
BIN_TYPE = executable
# The name of the executable to be created
# The extension gets appended automatically based on the type
BIN_NAME := prog
# The name of the documentation file
# Compiler used
# Force bash
if [ -z "$BASH" ] || [ ! "_$BASH" = "_/bin/bash" ];then bash $0 "$@";exit;fi
exec < /dev/tty
oldstty=$(stty -g)
stty raw -echo min 0