Skip to content

Instantly share code, notes, and snippets.

View dramaturg's full-sized avatar

Sebastian Krohn dramaturg

View GitHub Profile
#!/usr/bin/env bash
# strip out all the escape code crud
sed 's/\x1b\[[0-9;]*m//g' |\
sed 's/\x1b\[[0-9;]*[a-zA-Z]//g' |\
sed 's/\x1b\[[0-9;]*[mGKFH]//g'
#!/usr/bin/env python3
import os
from sys import argv
from shutil import copyfile
import yaml
def yamlLoader(file):
with open(file, 'r') as f:
return yaml.safe_load(f)
### Keybase proof
I hereby claim:
* I am dramaturg on github.
* I am dramaturg (https://keybase.io/dramaturg) on keybase.
* I have a public key ASAlTpQnGUphliXIxpihgb-jOv5MW51tmjR9l5GkQNaP4Qo
To claim this, I am signing this object:
@dramaturg
dramaturg / gist:6bb04b35c290b502df52b62f5a6d8d19
Created August 20, 2019 15:23
Thecus N3200PRO/N3800 on-board VGA output pinout

Thecus N3200PRO/N3800 on-board VGA output pinout

Using the on-board VGA output

The AMD Geode has an on-chip VGA controller that is connected to an IDC-10 connector on the motherboard, to the left of the CPU. It is relatively easy to build a custom cable to connect this port to a regular DB-15 VGA port. The IDC-10 connector pins are labelled on the board, with pin 2 being and bottom left pin, and pin 10 the topleft one (see image below). The following pinout seems to work enough for BIOS access and simple graphic modes.

4: RED, GREEN and BLUE GROUNDs
5: RED
@dramaturg
dramaturg / i3-in-mate-playbook-snippet.yaml
Created April 30, 2017 14:27
Running i3 in a mate session playbook snippet
- name: get gsettings
shell: gsettings list-recursively
register: gsettings
changed_when: false
- name: set gsettings
shell: gsettings set {{item.schema}} {{item.key}} {{item.value}}
when: "'{{item.schema}} {{item.key}} {{item.value}}' not in gsettings.stdout"
with_items:
- { schema: 'org.mate.background', key: 'show-desktop-icons', value: 'false' }

Some IPMI default credentials

Mostly scrapped from here.

Vendor Type Username Password
IBM various USERID PASSW0RD
Dell DRAC/10g root calvin
HP IPMI admin admin
@dramaturg
dramaturg / sql_uglyduckling.pl
Last active July 25, 2016 13:29
Quick n' dirty SQL beautifier with SQL::Beautify
#!/usr/bin/env perl
use strict;
use warnings;
use utf8;
use SQL::Beautify;
my $sql = SQL::Beautify->new(uc_keywords => 1);
@dramaturg
dramaturg / nxlog.conf
Created November 29, 2014 21:25
nxlog configuration sending event log to fluentd using HTTP
#define ROOT C:\Program Files\nxlog
define ROOT C:\Program Files (x86)\nxlog
Moduledir %ROOT%\modules
CacheDir %ROOT%\data
Pidfile %ROOT%\data\nxlog.pid
SpoolDir %ROOT%\data
LogFile %ROOT%\data\nxlog.log
-- Helper function to do whitespace cleanup
DELIMITER $$
CREATE FUNCTION ugly_trim(s VARCHAR(1000))
RETURNS VARCHAR(1000)
DETERMINISTIC
BEGIN
DECLARE temp VARCHAR(1000);
SET temp = '';