This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
SOURCE_IMG=jammy-server-cloudimg-amd64.img | |
IMG_TEMPLATE_INTR=template-v1-intermediate.qcow2 | |
IMG_TEMPLATE=template-v1.qcow2 | |
IMG_TEMPLATE_VMDK=template-v1.vmdk | |
TEMPLATE_SZ=20G | |
DIR=`pwd` | |
if [[ ! -f ${DIR}/${SOURCE_IMG} ]] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
import os | |
import sys | |
import string | |
from scapy.all import * | |
from scapy.contrib.mpls import * | |
from scapy.layers.vxlan import * | |
import argparse |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Print an introduction line in cyan | |
printf "\033[0;36mPre-commit hook is linting your changes for C/CPP code...\033[0m \n" | |
# Grab feed of staged cppfiles | |
cppfiles=$(git diff --name-only --cached --diff-filter=ACMRT | \ | |
grep ".*\.\(c\|cc\|cpp\|h\|hh\|hpp\)$" ) | |
numfiles=$( printf '%s' "$cppfiles" | grep -c '^' ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [ "$#" -ne 2 ]; then | |
echo "Usage : $0 <session_name> <machine_type>" | |
exit 1 | |
fi | |
session="$1" | |
machine="$2" |