summaryrefslogtreecommitdiffstats
path: root/extras/emacs/plugin-setup-skel.el
diff options
context:
space:
mode:
authorDave Barach <dave@barachs.net>2018-08-10 16:22:48 -0400
committerDave Barach <openvpp@barachs.net>2018-08-11 00:07:10 +0000
commitd7a37a75625dd5f09cdb99e0de6e40b49dd9a0d0 (patch)
treee2a4c5cd4aa7b90b90cb5bd28099731bbca11017 /extras/emacs/plugin-setup-skel.el
parent7eb9d9608b5b47b95f4860b2c470411658f7cdac (diff)
emacs skeletons: add quad/single, avx2/avx512 support
Change-Id: Ib8095ad69620308d6199ab030a754ee45f92e59b Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'extras/emacs/plugin-setup-skel.el')
-rw-r--r--extras/emacs/plugin-setup-skel.el45
1 files changed, 45 insertions, 0 deletions
diff --git a/extras/emacs/plugin-setup-skel.el b/extras/emacs/plugin-setup-skel.el
new file mode 100644
index 00000000000..9ff2a7b9427
--- /dev/null
+++ b/extras/emacs/plugin-setup-skel.el
@@ -0,0 +1,45 @@
+;;; plugin-setup-skel.el - debug CLI + pg setup
+;;;
+;;; Copyright (c) 2018 Cisco and/or its affiliates.
+;;; Licensed under the Apache License, Version 2.0 (the "License");
+;;; you may not use this file except in compliance with the License.
+;;; You may obtain a copy of the License at:
+;;;
+;;; http://www.apache.org/licenses/LICENSE-2.0
+;;;
+;;; Unless required by applicable law or agreed to in writing, software
+;;; distributed under the License is distributed on an "AS IS" BASIS,
+;;; WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+;;; See the License for the specific language governing permissions and
+;;; limitations under the License.
+
+(require 'skeleton)
+
+(define-skeleton skel-plugin-setup
+"Insert a debug cli / pg skeleton "
+nil
+'(if (not (boundp 'plugin-name))
+ (setq plugin-name (read-string "Plugin name: ")))
+'(setq PLUGIN-NAME (upcase plugin-name))
+'(setq capital-oh-en "ON")
+"
+comment { simple debug CLI setup script w/ packet generator test vector }
+set term page off
+loop create
+set int ip address loop0 192.168.1.1/24
+set int state loop0 up
+
+comment { Packet generator script. Src MAC 00:de:ad:be:ef:01 }
+comment { Dst mac 01:ba:db:ab:be:01 ethtype 0800 }
+packet-generator new {
+ name simple
+ limit 1
+ size 128-128
+ interface loop0
+ node " plugin-name "
+ data {
+ hex 0x00deadbeef0001badbabbe010800
+ incrementing 30
+ }
+}
+")