Skip to content

Instantly share code, notes, and snippets.

View kotx's full-sized avatar

Kot C kotx

View GitHub Profile
{ config, pkgs, ... }:
{
imports =
[
./hardware-configuration.nix
];
# Use the systemd-boot EFI boot loader.
boot.loader.systemd-boot.enable = true;

The Freenode resignation FAQ, or: "what the fuck is going on?"

IMPORTANT NOTE:

It's come to my attention that some people have been spamming issue trackers with a link to this gist. While it's a good idea to inform people of the situation in principle, please do not do this. By all means spread the word in the communities that you are a part of, after verifying that they are not aware yet, but unsolicited spam is not helpful. It will just frustrate people.

Update 3 (May 24, 2021)

A number of things have happened since the last update.

@linuswillner
linuswillner / psa.md
Last active May 30, 2022 01:43
Public service announcement from The Coding Den staff about social engineering being utilised as an attack vector for server takeovers

Today, on the 27th of March 2021, The Coding Den was subjected to a social engineering attack that lead to a brief hostile takeover of the server before the situation was brought under control by staff. We are sharing this statement as a public service announcement on the methodology used in the scam and possible remediations to prevent it, in order to help other staff teams avoid becoming victims of it.

Methodology

The attack proliferates as follows:

  1. The attacker will look for a staff member who is presently offline. This will ensure that it appears as if the staff member's account was globally banned and forcefully booted offline.
  2. It is within the attacker's interest to choose a target with the highest possible privileges (to do the maximum amount of damage), meaning that they will likely prefer administrators over moderators and so forth.
  3. The attacker will create a new Discord account with the same name and profile picture as the target.
  4. The attacker will approach a staff member, claiming
@akihikodaki
akihikodaki / README.en.md
Last active May 25, 2025 08:56
Linux Desktop on Apple Silicon in Practice

Linux Desktop on Apple Silicon in Practice

I bought M1 MacBook Air. It is the fastest computer I have, and I have been a GNOME/GNU/Linux user for long time. It is obvious conclusion that I need practical Linux desktop environment on Apple Silicon.

Fortunately, Linux already works on Apple Silicon/M1. But how practical is it?

  • Two native ports exist.
@brussell98
brussell98 / whatthefuck.js
Created January 5, 2021 00:52
Can you find out what it does?
_ = global;a = '▌╣'.slice(+!![] - [] << 2);b = [...'the quick brown fox jumps over the lazy dog'];c = c => String.fromCharCode(c.charCodeAt([] - []) - 98);d = s => [...s].map(c).join([] + []);e = !![] + !![] + !![];f = (!![] - [] + e << !![]) + !![];g = !![] << !![];h = !![] + !![] + [];i = (f - !![]) * g + [];j = b[+i - f - h] + b[-[]] + b[+i];ja = j[g] + b[+((+!![] + []) + +!![] + [])] + b[f + e] + b[+(h + h)];k = ['±ÄÌÇÅÖ', '£ÔÔÃÛ', 'µÖÔËÐÉ', 'ÒÔÑÅÇÕÕ', '§ÔÔÑÔ', '¤×ÈÈÇÔ'].map(d);l = '档牡潃敤瑁';m = [] + new _[k[(!![] - [] << !![] + !![]) + !![]]][ja](l, b[e + g] + b[e + g * g] + (typeof i)[[] - []] + h) + [];n = b[+i + f - !![]] + b[+i + f - g] + b[i * g + e] + b[e * g] + b[[] - []];o = _[k[![] - []]].getOwnPropertyNames(_[k[!![] + !!{}]])[f - (e << !![])];p = _[k[![] - []]].getOwnPropertyNames(_[k[!![] - !{}]].prototype)[+(h + h)];q = _[k[![] - []]].getOwnPropertyNames(_[k[!![] - !{}]].prototype)[i - !![]];r = b[i - g - e] + b[g] + b[i * e + [] - [] - g * (e + !![])] + b[g + e] + b[f - g] + b[g];s = (ac, v) =
@MeguminSama
MeguminSama / Discord Experiments.js
Last active April 29, 2025 08:31
Discord Experiments.js
let cache; webpackChunkdiscord_app.push([["wp_isdev_patch"], {}, r => cache=r.c]);
var UserStore = Object.values(cache).find(m => m?.exports?.default?.getUser).exports.default;
var actions = Object.values(UserStore._dispatcher._actionHandlers._dependencyGraph.nodes);
var user = UserStore.getCurrentUser();
actions.find(n => n.name === "ExperimentStore").actionHandler.CONNECTION_OPEN({
type: "CONNECTION_OPEN", user: {flags: user.flags |= 1}, experiments: [],
});
actions.find(n => n.name === "DeveloperExperimentStore").actionHandler.CONNECTION_OPEN();
webpackChunkdiscord_app.pop(); user.flags &= ~1; "done";
@Erisa
Erisa / hlg.cr
Created November 11, 2020 17:01
Hard Link Generator
#!/bin/env -S crystal build
# Hard Link Generator
# Generates hard links for all files in a given folder,
# while also finding and replacing strings in the filenames.
#
# The folder is created for you, but existing files (Running it twice?) will cause errors.
#
# Usage:
@IronWarrior
IronWarrior / UnityProjectJunctionTool.cs
Last active February 18, 2025 07:15
Unity editor tool to create dummy Unity projects to allow a single project to be open in multiple editor instances.
// gist by Roystan (IronWarrior): https://gist.github.com/IronWarrior/005f649e443bf51b656729231d0b8af4
// Video demo: https://twitter.com/DavigoGame/status/1300842800964018178
//
// CONTRIBUTIONS:
// Mac and Linux support added by Creature Coding: https://creaturecoding.com/
//
// PURPOSE:
// Unity does not permit a project to be open in two different editor instances.
// This can be frustrating when building projects with multiplayer networking,
// as it would require you to create a build every time you wish you test your netcode.
@kotx
kotx / KeyBind.java
Last active December 11, 2022 22:21
Dumb Fabric keybind thing.
package moe.whip.pilot.keys;
import net.fabricmc.api.EnvType;
import net.fabricmc.api.Environment;
import net.minecraft.client.options.KeyBinding;
@Environment(EnvType.CLIENT)
public class KeyBind extends KeyBindBase {
private KeyBinding keyBinding;
private boolean pressed;
@advaith1
advaith1 / top bots.md
Last active June 13, 2025 07:20
The top Discord bots ranked by server count
Rank Bot Approximate Server Count Library
1 MEE6 21,300,000 Custom Python
2 Rythm 14,900,000 JDA
3 carl-bot 🅱️ 12,100,000 Pycord
4 Dyno 10,600,000 Eris
5 Midjourney Bot