Skip to content

Instantly share code, notes, and snippets.

@basperheim
basperheim / postgres-postgresql-psql-essential-useful-commands.md
Last active October 27, 2024 12:57
Postgres psql essential commands

Useful Postgres (psql) commands

Here are some useful and essential psql commands to perform CRUD operations on PostgreSQL data.

DISCLAIMER: Use these commands with extreme caution.

It is highly recommended to:

  1. Back up your database before running any of these commands (especially the UPDATE, DROP, TRUNCATE, and DELETE commands).
  2. Double-check the command is the intended action you want to do.
  3. Review the output of the SELECT query before executing any DROP statements.
@basperheim
basperheim / download-youtube-dl-crop-ffmpeg.md
Last active March 6, 2023 07:35
Download and crop YouTube videos using youtube-dl and FFmpeg

Download a YouTube video with youtube-dl

Basic youtube-dl command is: youtube-dl "https://www.youtube.com/watch?v=VIDEO_ID_HERE".

Make sure to do the following first:

  • Ensure the python3 command is working and actually runs a version of Python 3.x.
  • Make sure that the path to your cookies file is correct.
  • Make sure that you have the latest version of youtube-dl installed (youtube-dl --version).
  • Ensure the absolute file path for the youtube-dl binary or installation (In a UNIX-like terminal use which youtube-dl).
@bubblerun
bubblerun / array.js
Created January 17, 2017 02:37
State abbreviations JavaScript array
[ 'AL', 'AK', 'AS', 'AZ', 'AR', 'CA', 'CO', 'CT', 'DE', 'DC', 'FM', 'FL', 'GA', 'GU', 'HI', 'ID', 'IL', 'IN', 'IA', 'KS', 'KY', 'LA', 'ME', 'MH', 'MD', 'MA', 'MI', 'MN', 'MS', 'MO', 'MT', 'NE', 'NV', 'NH', 'NJ', 'NM', 'NY', 'NC', 'ND', 'MP', 'OH', 'OK', 'OR', 'PW', 'PA', 'PR', 'RI', 'SC', 'SD', 'TN', 'TX', 'UT', 'VT', 'VI', 'VA', 'WA', 'WV', 'WI', 'WY' ];
@chranderson
chranderson / nvmCommands.js
Last active November 18, 2024 00:17
Useful NVM commands
// check version
node -v || node --version
// list locally installed versions of node
nvm ls
// list remove available versions of node
nvm ls-remote
// install specific version of node
@roachhd
roachhd / README.md
Last active November 15, 2024 09:34
Basics of BrainFuck

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

BrainFuck Programming Tutorial by: Katie

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

INTRODUCTION