Skip to content

Instantly share code, notes, and snippets.

Avatar
🙂
Training ... Unit ready

amanusk amanusk

🙂
Training ... Unit ready
View GitHub Profile
@amanusk
amanusk / cairo_vim_env.md
Last active May 20, 2022
Cairo Env for Vim
View cairo_vim_env.md

Setting up Cairo env for vim development

Setup the cairo virtualenv

First things first, you need to install the cairo-lang package, preferably in a virtual env you can later use and upgrade. Currently only python 3.7 and 3.8 is supported

python3 -m venv ~/cairo_venv
source ~/cairo_venv/bin/activate
@amanusk
amanusk / display.sh
Last active Aug 8, 2022
Easily change between laptop and external displays in i3 + dmenu
View display.sh
#!/bin/bash
# This script is intended to make switching between laptop and external displays easier when using i3+dmenu
# To run this script, map it to some shortcut in your i3 config, e.g:
# bindsym $mod+p exec --no-startup-id $config/display.sh
@amanusk
amanusk / spectre.c
Created Jan 8, 2018 — forked from ErikAugust/spectre.c
Spectre example code
View spectre.c
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#ifdef _MSC_VER
#include <intrin.h> /* for rdtscp and clflush */
#pragma optimize("gt",on)
#else
#include <x86intrin.h> /* for rdtscp and clflush */
#endif