Skip to content

Instantly share code, notes, and snippets.

View dmiller-nmap's full-sized avatar

Daniel Miller dmiller-nmap

View GitHub Profile
@dmiller-nmap
dmiller-nmap / nmap-check.sh
Last active April 11, 2024 16:19 — forked from bonsaiviking/nmap-check.sh
Check for bugs and code quality issues in Nmap source files.
#!/bin/bash
PEP8=$(which pep8)
PEP8IGNORE=E123,E124,E126,E127,E128
if [ -z $PEP8 ]; then
echo "No pep8 in your path. Skipping Python checks"
else
for file in $(find "$@" -name '*.py'); do
OUTPUT=$(mktemp)
@dmiller-nmap
dmiller-nmap / pre-commit
Last active April 11, 2024 16:13 — forked from bonsaiviking/pre-commit
Pre-commit git hook for Nmap (WIP)
#!/bin/bash
#
# An example hook script to verify what is about to be committed.
# Called by "git commit" with no arguments. The hook should
# exit with non-zero status after issuing an appropriate message if
# it wants to stop the commit.
#
if git rev-parse --verify HEAD >/dev/null 2>&1
then