Skip to content

Instantly share code, notes, and snippets.

View amanusk's full-sized avatar
Training ... Unit ready

amanusk amanusk

Training ... Unit ready
  • TxPool
  • 04:06 (UTC +02:00)
  • Twitter @amanusk_
View GitHub Profile
amanusk / cairo.vim
Last active April 14, 2023 02:52
Cairo 1.0 Syntax highligh for vim
View cairo.vim
" Vim syntax file
" Language: CAIRO
if exists("b:current_syntax")
syntax include @python syntax/python.vim
amanusk /
Last active February 20, 2023 13:51
Cairo Env for Vim

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 /
Last active August 7, 2023 01:46
Easily change between laptop and external displays in i3 + dmenu
# 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/
amanusk / spectre.c
Created January 8, 2018 19:37 — 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)
#include <x86intrin.h> /* for rdtscp and clflush */