Skip to content

Instantly share code, notes, and snippets.

View adri326's full-sized avatar
🐺
Wolfo

Shad Amethyst adri326

🐺
Wolfo
View GitHub Profile
@adri326
adri326 / readme.md
Last active October 11, 2022 09:26
UI tweaks for gitlab

Amethyst's UI Tweaks for Gitlab

How to install

Load userscript.js into a userscript extension, like Tampermonkey, and load userstyle.css into a userstyle extension, like Stylus. Tweak the values of both files to fit your needs.

Changelog

0.2.0: add support for semantic commit names, fix the 'you' showing on reviewed MRs

@adri326
adri326 / tp1.py
Created April 6, 2022 17:19
RS40, template propre du TP1 avec Unit Tests
import hashlib
import binascii
import math
import sys
import unittest
def home_mod_exponent(x, y, n):
# TODO :)
@adri326
adri326 / abg.sh
Created October 31, 2021 17:34
Animated desktop background on X11
#!/bin/sh
# Animated desktop background on X11, using xwinwrap and mpv
# bg=$(ls ~/bg/ | rofi -dmenu -theme theme) || exit
bg="$1"
killall -q xwinwrap
while pgrep -x xwinwrap > /dev/null; do sleep 0.3; done
@adri326
adri326 / README.md
Last active September 28, 2021 08:45
Quick Berkely UPC build scripts

Quick Berkeley UPC build scripts

This small gist contains the required steps to compile and install Berkeley's UPC implementation.

This script is far from being fail-safe, but worked on my end. Good luck!

Requirements

To build UPC, you will need to have autoconf and a set of C/C++ compilers. The script defaults to using gcc/g++ and will install UPC in ~/.berkeley. If you wish to change this behavior, you will have to edit the first lines of the script.

@adri326
adri326 / velot-cfg.txt
Created May 20, 2020 13:16
An velot-poc configuration example for Chinese
ni:你
shi:是
zho:中
zgho:中国
guo:国
ren:人
ma:吗?
ma5:吗
ne:呢?
ne5:呢
@adri326
adri326 / parse_moodle_chat.js
Last active April 7, 2020 13:16
Parse a copy-pasted moodle chat into usable markdown
/* USAGE: node parse_moodle_chat.js [--date] copy_pasted_chat.txt
If `--date` is set, timestamps will be put before every message.
*/
const fs = require("fs");
let raw = fs.readFileSync(process.argv[process.argv.length - 1], "utf8");
let lines = raw.split("\n");
let messages = [];
let msg = "";
@adri326
adri326 / README.md
Last active April 7, 2021 20:39
[rofi + X] CJK input pop-up

[rofi + X] CJK input pop-up

This is a small pop-up window made with rofi which lists CJK characters, lets you type in their name or things in their description and will type the corresponding character out for you.

Installation

You will need:

Keybase proof

I hereby claim:

  • I am adri326 on github.
  • I am sha_dryx (https://keybase.io/sha_dryx) on keybase.
  • I have a public key whose fingerprint is B396 7A3A 3706 761E B5E0 F3A1 D970 C8DD 1D6D EE36

To claim this, I am signing this object: