Skip to content

Instantly share code, notes, and snippets.

View velzie's full-sized avatar

velzie velzie

View GitHub Profile
@velzie
velzie / corners.user.css
Created June 22, 2024 01:05
remove all rounded corners userstyle
/* ==UserStyle==
@name No Rounded Corners
@description remove all rounded corners
@author velzie
@version 0.0
@namespace https://gist.github.com/velzie/9fbde71738ee9a207fb87dcc5c0a2ce7
==/UserStyle== */
*:not(__unreachable),
*:not(__unreachable)::before,
@velzie
velzie / manifest-v2-chrome.md
Last active June 26, 2024 04:02
How to keep using adblockers on chrome and chromium

How to keep using adblockers on chrome and chromium

  1. google's manifest v3 has no analouge to the webRequestBlocking API, which is neccesary for (effective) adblockers to work
  2. starting in chrome version 127, the transition to mv3 will start cutting off the use of mv2 extensions alltogether
  3. this will inevitably piss of enterprises when their extensions don't work, so the ExtensionManifestV2Availability key was added and will presumably stay forever after enterprises complain enough

You can use this as a regular user, which will let you keep your mv2 extensions even after they're supposed to stop working

Linux

In a terminal, run:

@velzie
velzie / Xorg.md
Last active January 16, 2024 15:14
Boycott Xorg. It breaks everything!!

Hello! This is a parody of the infamous "boycott wayland" thread. Meant to be a reference of issues, instead of tracking actual flaws with the wayland ecosystem or pointing out helpful resources or alternatives, the creator mostly cites secondhand anecdotes, personal opinions, and outdated or provably false statements. When commenters tried to point out the outdated information and suggest improvements to the gist, their comments were either deleted, harrassed by the creator of the gist, or edited to include homophobic remarks.

Do not take anything here seriously, I made this mostly as a joke. If you have extra things to add leave them in comments (i won't harass you)

Think twice before using Xorg over Wayland. It breaks everything!!

Xorg breaks Gnome

@velzie
velzie / chromeos-117-sudo-howto.md
Last active May 17, 2024 14:49
Re-Enable sudo from crosh on R117+ Chrome OS without recompiling

Short guide on how to bypass this:

image

If you haven't disabled rootfs verification, switch to vt-2 and run /usr/libexec/debugd/helpers/dev_features_rootfs_verification. Then reboot.

Inside crostini, download minioverride.c and compile it with gcc minioverride.c -o minioverride.so -shared (make sure gcc is installed)

In the files app, move minioverride.so into your downloads folder.

@velzie
velzie / rickroll.c
Last active August 9, 2023 17:23
linux pcspkr rickroll in C
/* compile:
```
gcc rickroll.c
sudo ./a.out
```
MUST BE RUN AS ROOT
*/
#include <fcntl.h> // open
#include <linux/input.h> // struct input_event
#include <linux/kd.h>
@velzie
velzie / delinker.sh
Last active February 20, 2024 19:07
convert compiled binary into static binary
mkdir libs
cp $(ldd bin | sed -e "s/ (.*//" -e "s/\t//g" -e "s/.*=> //" | grep -v "linux-vdso.so.1") libs
# to execute the program, libs/linker.so --library-path libs /path/to/binary
# ty r58 for the fix
@velzie
velzie / vpkunpack.py
Created August 21, 2022 22:17
Unpacker for source VPK files on linux
#!/usr/bin/python
import vpk
from pathlib import Path
import os
pakdir = "pak01_dir.vpk"
pak1 = vpk.open(pakdir);
os.mkdir("pak01")
for filepath in pak1:
using System.Collections;
using UnityEngine;
using UnityEngine.SceneManagement;
public class SaveStatesManager : MonoBehaviour
{
public List<SavedGameObject> savedState;
public void SaveState()
{
var numPointsSlider = 0, turnFractionSlider = 0;
var LastNumPoints = 0, LastTurnFraction = 0;
var numPoints = 0, turnFraction = 0;
var points = [];
var powSlider;
var LastPower;
var speedSlider;
var angleOffset = 0;
function setup(){
createCanvas(800,800);