Skip to content

Instantly share code, notes, and snippets.

@dantheman213
dantheman213 / win32-api-marshal-reference.md
Last active March 20, 2017 17:55
Marshaling Win32 API Data Types To .NET
@dantheman213
dantheman213 / youtube-dl_cheatsheet.md
Last active January 23, 2022 01:40
youtube-dl best way to download video or entire to high quality mp3

youtube-dl cheat sheet

Docs and Binary for youtube-dl are located here:

https://github.com/rg3/youtube-dl/

Install dependencies

apt-get install libav-tools ffmpeg # Linux (either one of either should do) brew install ffmpeg # OSX choco install ffmpeg # Windows

@dantheman213
dantheman213 / encoder.sh
Created February 23, 2017 00:42
Convert all of your video files to x264 for massive space savings
fmpeg -i $file -c:v libx265 -x265-params lossless -c:a copy -c:s copy output.mkv
@dantheman213
dantheman213 / install-deepin-arch-manjaro-readme.md
Last active July 9, 2026 05:44
Install Deepin Desktop Environment from a minimum Arch or Manjaro Install Operating System

Install Deepin Desktop Environment In Arch or Manjaro

I recommend doing this as a net/minimum install with Manjaro (no desktop manager attached with the install).

Update sources & packages

pacman -Syu
reboot -h now
@dantheman213
dantheman213 / pacman-cheatsheet.md
Last active December 4, 2018 08:24
Pacman Package Manager Cheatsheet

Pacman Cheatsheet

Update and upgrade all

pacman -Syu

Install specific package

pacman -S 
@dantheman213
dantheman213 / your_nodejs_app.conf
Last active February 4, 2017 00:19
NodeJS 'Upstart' Start-up script. Works on Ubuntu 14.04.
#!upstart
# NodeJS 'Upstart' Start-up script.
# Works on Ubuntu 14.04. Systemd is being used for Ubuntu 16.04 though.
description "your node js web app"
start on started mountall
stop on shutdown
@dantheman213
dantheman213 / Three Wise Monkeys.md
Created January 20, 2017 21:50
Three Wise Monkeys (NDA)

Date: [date]

Between us [company name] and you [customer name].

Summary:

In short; neither of us will share any confidential information about each-other, by any means, with anyone else.

What’s confidential information?

@dantheman213
dantheman213 / PostgresFunctionsCheatsheetReadme.md
Last active January 11, 2022 18:15
PostgreSQL & PL/pgSQL Stored Functions Cheatsheet

PostgreSQL & PL/pgSQL Stored Functions Cheatsheet

Boiler-plate stored function

CREATE OR REPLACE FUNCTION public.sp_user_ins_status(status smallint)
  RETURNS integer
  LANGUAGE plpgsql
AS $function$
@dantheman213
dantheman213 / import_db_structure.sh
Last active October 30, 2024 13:35
Batch import all *.sql files in a folder recursively into your Postgres or PostgreSQL database
#!/bin/sh
# AUTHOR
# DANIEL E. GILLESPIE (2016)
# https://github.com/dantheman213
# DESCRIPTION
# Import all *.sql files in a folder recuresively into your PostgreSQL database
# Batch export all table schemas and stored functions with this script located here:
@dantheman213
dantheman213 / export_db_structure.sh
Last active January 27, 2026 08:50
Batch backup and export your Postgres or PostgreSQL table schemas and stored functions or procedures into individual *.sql files --the easy way!
#!/bin/sh
# AUTHOR
# DANIEL E. GILLESPIE (2016)
# https://github.com/dantheman213
# DESCRIPTION
# Export your app's table schemas and stored functions from a PostgreSQL
# database into individual *.sql files for easy management and source control.