Skip to content

Instantly share code, notes, and snippets.

Avatar
:shipit:
p̰͍͖̄̀ͬ̒̎̅a̲͚̯̱̺͗̿̓̆͊̀͌ǘ̳̹͙͔̘̈ͭ̋̒ͭ̋lͫ̔ͯ̂ ͎͖͍̤ͣͧ̀ͨj̾o̹̗͍̲̽ͥ́̊͐b̪ͬͪͫ̂s̙̫͕̼̭͛̍̔on̽

Paul Jobson pjobson

:shipit:
p̰͍͖̄̀ͬ̒̎̅a̲͚̯̱̺͗̿̓̆͊̀͌ǘ̳̹͙͔̘̈ͭ̋̒ͭ̋lͫ̔ͯ̂ ͎͖͍̤ͣͧ̀ͨj̾o̹̗͍̲̽ͥ́̊͐b̪ͬͪͫ̂s̙̫͕̼̭͛̍̔on̽
View GitHub Profile
@pjobson
pjobson / exfat.md
Last active Aug 12, 2021
Create exFat Partiion in Linux Accessible to Windows / MacOS
View exfat.md

To create a exFat partition which is compatible with all operating systems, I recommend using a drive with under 2TB. This will allow you to use an MBR partition table instead of GPT, I've had issues mounting GPT exFat drives in Windows.
This could be partially because I don't know how to Windows anything.

List Disks

fdisk -l

Mine for example is /dev/sdl, because I have many disks.

@pjobson
pjobson / diskripper.sh
Last active Jul 20, 2021 — forked from tacofumi/diskripper.sh
This script rips DVD/Blu-ray using makemkvcon. Use udev to invoke this script to auto-rip when disk is inserted. Some variables such as length of string to trim in order to get the title of movie may vary depending on your environment.
View diskripper.sh
#!/bin/bash
# heavily derived from: https://gist.github.com/tacofumi/3041eac2f59da7a775c6
# I mainly simplifed the title generation and made it automatically create a path
echo $(date)
echo "Disk found"
echo "Setting the title..."
title=$(makemkvcon -r info |grep "DRV:0" | sed -E 's/.+,"(.+)","\/dev\/.+"$/\1/')
@pjobson
pjobson / GT-3TP.md
Last active Sep 14, 2021
Baofeng GT-3TP Linux Flash Notes
View GT-3TP.md

Baofeng GT-3TP Linux Flash Notes

All FCC Rules apply, if you are not licensed you shouldn't be broadcasting on channels which are forbidden.

CHIRP LOGO

Loosely based on these GT-3 instructions.

I had a lot of trouble flashing on Windows 10 and MacOS, I should really have just started with Linux and not wasted a long time with the other OSes.

@pjobson
pjobson / 0.win10_phy_to_virtualbox_vm.md
Last active Apr 12, 2021
Windows 10 Physical Drive to VirtualBox VM
View 0.win10_phy_to_virtualbox_vm.md

Windows Physical Drive to VirtualBox VM

What You Need

  • Windows Computer (I'm using Win10)
  • Linux Computer (I'm using Mint 20.1)
  • External Drive
    • The largest supported image size is 127GB, so if you have a bunch of personal files on your Windows computer, migrate it to a different drive..

Boot your Windows Machine

@pjobson
pjobson / vaapi-ffmpeg-build.md
Created Mar 11, 2021 — forked from Brainiarc7/vaapi-ffmpeg-build.md
Building a VAAPI enabled FFmpeg for use bound to the !/bin prefix
View vaapi-ffmpeg-build.md

Build FFmpeg and libva with decode and encode hardware acceleration on an Intel-based validation testbed:

Build platform: Ubuntu

Install baseline dependencies first

sudo apt-get -y install autoconf automake build-essential libass-dev libtool pkg-config texinfo zlib1g-dev libva-dev cmake mercurial libdrm-dev libvorbis-dev libogg-dev git libx11-dev libperl-dev libpciaccess-dev libpciaccess0 xorg-dev

Then add the Oibaf PPA, needed to install the latest development headers for libva:

View keybase.md

Keybase proof

I hereby claim:

To claim this, I am signing this object:

@pjobson
pjobson / nanopi_r1_pi_hole.md
Last active Nov 20, 2020
NanoPi R1 as Pi Hole Device
View nanopi_r1_pi_hole.md

NanoPi R1 as Pi Hole Device

This guide assumes you're using linux or some kind of OS with a shell, you can use Windows with some modifications.

Links

Install Latest Xenial

@pjobson
pjobson / hevc2avc.js
Created Nov 11, 2020
Convert hevc to avc (h.265 to h.264)
View hevc2avc.js
#!/usr/bin/env node
const fs = require('fs');
const path = require('path');
const process = require('process');
const shellescape = require('shell-escape');
const child_process = require('child_process');
const cliProgress = require('cli-progress');
const FFMPEG = '/home/pjobson/bin/ffmpeg -hide_banner';
@pjobson
pjobson / avi2mp4.js
Created Nov 11, 2020
Convert AVI to MP4
View avi2mp4.js
#!/usr/bin/env node
const fs = require('fs');
const path = require('path');
const process = require('process');
const shellescape = require('shell-escape');
const child_process = require('child_process');
const avi = process.argv[2];
const outpath = path.resolve(process.argv[3] || path.parse(avi).dir);
@pjobson
pjobson / sublime-text-prefs.json
Created Oct 8, 2020
Preferences for Sublime Text
View sublime-text-prefs.json
{
"draw_white_space": "all",
"ensure_newline_at_eof_on_save": true,
"font_face": "Hack",
"font_size": 20.0,
"gutter": true,
"highlight_line": true,
"line_numbers": true,
"line_padding_bottom": 2,
"line_padding_top": 2,