From mboxrd@z Thu Jan 1 00:00:00 1970 From: Karl Voit Subject: Re: Some advice on how to use babel to generate cisco configs Date: Thu, 31 Jan 2013 10:50:32 +0100 Message-ID: <2013-01-31T10-48-36@devnull.Karl-Voit.at> References: Reply-To: news1142@Karl-Voit.at Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([208.118.235.92]:50346) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U0qn8-0000jn-7W for emacs-orgmode@gnu.org; Thu, 31 Jan 2013 04:50:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U0qn6-0001fU-IM for emacs-orgmode@gnu.org; Thu, 31 Jan 2013 04:50:46 -0500 Received: from plane.gmane.org ([80.91.229.3]:38869) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U0qn6-0001fL-5Q for emacs-orgmode@gnu.org; Thu, 31 Jan 2013 04:50:44 -0500 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1U0qnN-0004L0-10 for emacs-orgmode@gnu.org; Thu, 31 Jan 2013 10:51:01 +0100 Received: from mail.michael-prokop.at ([88.198.6.110]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 31 Jan 2013 10:51:01 +0100 Received: from news1142 by mail.michael-prokop.at with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 31 Jan 2013 10:51:01 +0100 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org * Bart Bunting wrote: > Good morning, Hi! > What I would like to achieve is to have a table containing a few values, > e.g. ip address vlan number etc. > > Then have a cisco config in the org file with markers where the > substitutions are to be inserted. > Run through the table and create a node in the org file one for each row > of the table. Are you planning to use this as a one-time creation thing or do you want to re-run (and re-generate) the configs from the same table multiple times? > The end result should be a set of cisco configs with the substitutions > made. I was hoping to also use shell to call pwgen to generate a > random password to insert. If it is one-time only, you might be happy using a yasnippet template which generates your substitutions. -- Karl Voit