Skip to content

Instantly share code, notes, and snippets.

Avatar

A. J. Ricoveri axltxl

View GitHub Profile
@axltxl
axltxl / pdf_downsample.sh
Created Nov 9, 2018
Downsample image-based PDF documents with Ghostscript
View pdf_downsample.sh
#!/bin/bash
# Usage: pdf_downsample.sh <input_pdf_file> <output_pdf_file> [output_dpi]
# A. J. Ricoveri (github.com/axltxl)
set -e
_pdf_help() {
echo "Usage: $0 <input_pdf_file> <output_pdf_file> [output_dpi]"
exit 1
}
View tmux-truecolor.diff
diff --git a/colour.c b/colour.c
index a56ddce..8098f83 100644
--- a/colour.c
+++ b/colour.c
@@ -29,305 +29,85 @@
* of the 256 colour palette.
*/
-struct colour_rgb {
- u_char i;
@axltxl
axltxl / cVimrc
Last active Oct 22, 2015
My somewhat simple cVimrc configuration
View cVimrc
" Basics
set cncpcompletion
let mapleader = ";"
let barposition = "bottom"
@axltxl
axltxl / ovpn_router.sh
Created Sep 8, 2015
OpenVPN router setup
View ovpn_router.sh
#!/usr/bin/env bash
#
# openvpn router setup:
# Small utility to set up an OpenVPN router
#
# Author: Alejandro Ricoveri <alejandroricoveri@gmail.com>
# network interfaces
i_lan=eth0
i_vpn=tun0 # OpenVPN TUN interface
View cw-monitor-memusage.py
#!/usr/bin/env python
'''
Send memory usage metrics to Amazon CloudWatch
This is intended to run on an Amazon EC2 instance and requires an IAM
role allowing to write CloudWatch metrics. Alternatively, you can create
a boto credentials file and rely on it instead.
Original idea based on https://github.com/colinbjohnson/aws-missing-tools
'''
You can’t perform that action at this time.