Skip to content

Instantly share code, notes, and snippets.

@yoavniran
yoavniran / ultimate-ut-cheat-sheet.md
Last active July 16, 2025 06:32
The Ultimate Unit Testing Cheat-sheet For Mocha, Chai, Sinon, and Jest
@mistaka0s
mistaka0s / post-recieve.sh
Last active April 16, 2017 20:56
Git post-recieve hook to update Splunk deployment-apps directory on push.
#!/bin/bash
umask 022
# Uncomment to debug.
#set -x
# Modify GITWORKDIR to suit you.
#GITWORKDIR=/tmp/deployment-apps/
GITWORKDIR=/opt/splunk/etc/deployment-apps/
# Modify AUTOPUSHBRANCH with the branch you want to automatically push.
@mmstick
mmstick / transcode-install.sh
Last active October 20, 2022 21:48
Ubuntu 10-bit HEVC Transcoding Tools -- Contains a script to install x265-10bit-git, libass-git, ffmpeg-git and bomi-git; another for updating everything; as well as scripts for transcoding videos with ffmpeg. Transcoding scripts require the fish shell to be installed.
#!/bin/bash
sourcedir="$HOME/.local/src/"
mkdir "$sourcedir"
export CFLAGS='-march=native -O3 -pipe -fstack-protector -Wall'
export CXXFLAGS='-march=native -O3 -pipe -fstack-protector -Wall'
function install-dependencies() {
# Install build tools and Mesa VDPAU support.
sudo apt-fast install -y cmake yasm autoconf build-essential mesa-vdpau-drivers \
libvdpau-va-gl1
@wpscholar
wpscholar / vagrant-cheat-sheet.md
Last active October 24, 2025 06:07
Vagrant Cheat Sheet

Typing vagrant from the command line will display a list of all available commands.

Be sure that you are in the same directory as the Vagrantfile when running these commands!

Creating a VM

  • vagrant init -- Initialize Vagrant with a Vagrantfile and ./.vagrant directory, using no specified base image. Before you can do vagrant up, you'll need to specify a base image in the Vagrantfile.
  • vagrant init <boxpath> -- Initialize Vagrant with a specific box. To find a box, go to the public Vagrant box catalog. When you find one you like, just replace it's name with boxpath. For example, vagrant init ubuntu/trusty64.

Starting a VM

  • vagrant up -- starts vagrant environment (also provisions only on the FIRST vagrant up)
@giovtorres
giovtorres / slurm_core_states.py
Last active July 30, 2020 00:21
Collectd Python plugin to get Slurm's core allocation by state
#!/usr/bin/python
# vim: set ts=4 sw=4 et
"""
slurm_core_states.py - A read plugin that will dispatch the core cpu states
returned by the Slurm sinfo command.
"""
import collectd
import signal
@ejmr
ejmr / git-pick-branch.sh
Created September 9, 2015 08:05
Checkout a Git Branch Using Fuzzy-Selection
#!/bin/sh
#
# git pick-branch
#
# This command checks out a branch, using the commnad `pick` to
# provide fuzzy-selection of the branch names.
#
# https://github.com/thoughtbot/pick
#
######################################################################
@ejmr
ejmr / git-branch-show-description.sh
Last active October 6, 2024 13:44
Show the Description for the Current Branch
#!/bin/bash
#
# You can use `git branch --edit-description` to write a description
# for a branch, but Git provides no simple command to display that
# description. The "easiest" way to see it is via `git config --get
# branch.BRANCH_NAME.description`.
#
# This script automates that process and is meant to be used as
# a Git alias to provide a shorter command for showing the
# description of the current branch.
@thom8
thom8 / vagrant-box-update-all.sh
Last active September 15, 2017 16:33
Update all your vagrant base boxes
#!/bin/bash
# Find all boxes which have updates
AVAILABLE_UPDATES=`vagrant box outdated --global | grep outdated | tr -d "*'" | cut -d ' ' -f 2`
if [ ! ${#AVAILABLE_UPDATES[@]} -eq 0 ]; then
for box in $AVAILABLE_UPDATES ; do
echo "Found an update for $box"
@miglen
miglen / aws-certification.md
Last active August 1, 2024 14:08
AWS Certification guide and notes on how to prepare for the aws associate certification architect, sysops and developer exams


AWS Certification notes

Those are my personal notes on AWS Solution Architect certification preparation. Hope you find them usefull.

To pass AWS certification, you should have:

  • Sound knowledge about most of the AWS services ( EC2, VPC, RDS, Cloudfront, S3, Route53 etc,)
  • Hands on experience with AWS services.
@bishboria
bishboria / springer-free-maths-books.md
Last active September 25, 2025 06:28
Springer made a bunch of books available for free, these were the direct links