Skip to content

Commit

Permalink
OKI ntp mibs
Browse files Browse the repository at this point in the history
  • Loading branch information
neermitt authored and dcwangmit01 committed Aug 13, 2019
1 parent d8e5188 commit 62ed663
Show file tree
Hide file tree
Showing 70 changed files with 48,714 additions and 0 deletions.
33 changes: 33 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,16 @@ compile: ## Compile all MIBs into .py files
$$f; \
done

compile-changed: ## Compile With Texts all MIBs into .py files
@for f in $$(git status --porcelain | grep "^A" | cut -c 4- | grep "asn1/"); do \
echo "## Compiling $$f"; \
mibdump.py \
--no-python-compile \
--mib-source=file://$$(pwd)/asn1 \
--destination-directory=./pysnmp \
$$f; \
done

compile-with-texts: ## Compile With Texts all MIBs into .py files
@for f in $$(ls asn1); do \
echo "## Compiling $$f with texts"; \
Expand All @@ -27,6 +37,17 @@ compile-with-texts: ## Compile With Texts all MIBs into .py files
$$f; \
done

compile-with-texts-changed: ## Compile With Texts all MIBs into .py files
@for f in $$(git status --porcelain | grep "^A" | cut -c 4- | grep "asn1/"); do \
echo "## Compiling $$f with texts"; \
mibdump.py \
--generate-mib-texts \
--no-python-compile \
--mib-source=file://$$(pwd)/asn1 \
--destination-directory=./pysnmp-with-texts \
$$f; \
done

compile-json: ## Compile With Texts all MIBs into .py files
@for f in $$(ls asn1); do \
echo "## Compiling $$f with texts"; \
Expand All @@ -39,6 +60,18 @@ compile-json: ## Compile With Texts all MIBs into .py files
$$f; \
done

compile-json-changed: ## Compile With Texts all MIBs into .py files
@for f in $$(git status --porcelain | grep "^A" | cut -c 4- | grep "asn1/"); do \
echo "## Compiling $$f with texts"; \
mibdump.py \
--generate-mib-texts \
--no-python-compile \
--mib-source=file://$$(pwd)/asn1 \
--destination-format=json \
--destination-directory=./json \
$$f; \
done

help: ## Print list of Makefile targets
@# Taken from https://github.com/spf13/hugo/blob/master/Makefile
@grep -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | \
Expand Down
Loading

0 comments on commit 62ed663

Please sign in to comment.