Skip to content

Instantly share code, notes, and snippets.

View VottusCode's full-sized avatar
💭
enjoying corona, hbu

VottusCode

💭
enjoying corona, hbu
View GitHub Profile
@VottusCode
VottusCode / remove_ps_eval.sh
Created August 24, 2021 21:44
Remove PhpStorm evaluation (Linux)
rm ~/.config/JetBrains/PhpStorm*/options/other.xml
rm ~/.config/JetBrains/PhpStorm*/eval/*
rm -rf .java/.userPrefs
@VottusCode
VottusCode / build.sh
Created August 2, 2021 21:55
prisma-client-go binaries/publish.sh without the publish stuff
#!/bin/sh
set -eux
v="$1"
mkdir -p build
cd build
npm init --yes
npm i "pkg" --dev
@VottusCode
VottusCode / fake-data.php
Created April 11, 2021 12:40
Fixtures not working, fuck them
<?php declare(strict_types = 1);
/**
*
* This file is just a "scratch file" for creating fake
* data in development environment, not meant and not used
* in production. Fixtures are not working at the moment for some reason,
* probably related to PHP 8, so at the moment this is a shitty alternative.
*
* This code isn't gonna use some fancy shit, it's just gonna be a crappy shit,
@VottusCode
VottusCode / nohiber.sh
Created April 30, 2021 14:26
Fuck Hiberfile right off your drive. Just rewrite /dev/sda to your Windows drive.
if ! [ $(id -u) = 0 ]; then
echo "You need to run this script as root (or use sudo)." >&2
exit 1
fi
if grep -qs '/dev/sda4 ' /proc/mounts; then
echo '/dev/sda4 is already mounted, proceeding to unmount'
umount /dev/sda4
if [ $? -eq 0 ]; then
@VottusCode
VottusCode / build.gradle.kts
Created April 26, 2021 13:19
Explicitly set UTF-8 in Gradle (build.gradle.kts)
tasks.withType<JavaCompile> {
options.encoding = "UTF-8"
}
tasks.withType<Javadoc>{
options.encoding = "UTF-8"
}
@VottusCode
VottusCode / Shit-script-to-remove-ads-on-KissAnime.js
Last active October 6, 2020 18:52
Script for Tampermonkey that deletes iframe ads on KissAnime, and the one over the play (beta server)
// ==UserScript==
// @name FuckAdsKA
// @version 1.0
// @description my stupid little js script that deletes ads at the Anime watch page
// @author Vottus
// @match https://kissanime.ru/Anime/*
// @require http://code.jquery.com/jquery-3.4.1.min.js
// ==/UserScript==
/**
@VottusCode
VottusCode / Sha256.ts
Created October 6, 2020 18:43
Port of AuthMe's SHA256 hashing to Node.js
import { createHash } from "crypto";
import { range } from "lodash";
export class Sha256 {
/** Range of characters for salt generation */
private chars: string[];
public static SALT_LENGTH = 16;
constructor() {