~ubuntu-branches/ubuntu/lucid/rancid/lucid

« back to all changes in this revision

Viewing changes to bin/arancid.in

  • Committer: Bazaar Package Importer
  • Author(s): Roland Rosenfeld
  • Date: 2009-06-11 14:24:49 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20090611142449-355aul2t1hz9269s
Tags: 2.3.2-1
* New upstream release 2.3.2.
* Merge rancid-core and rancid-util into a new package rancid.
* Adapt all patches to the new version.
* 07_nrancid_bs_paging: Fix "--- more ---" & backspace style paging on
  netscreen devices.  Thanks to Vaclav Ovsik <vaclav.ovsik@i.cz> for
  providing a patch (Closes: #520899).
* 08_hlogin_paging: Turn off paging on HP equipment.  Thanks to James
  W. Laferriere <babydr@baby-dragons.com> for providing a patch.
* 09_svn: Avoid "svn: Directory '<GROUP>' is out of date" message.
  Thanks to Nicolas DEFFAYET <nicolas-ml@deffayet.com> for providing a
  patch.
* Update to Standards-Version 3.8.1 (no changes).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
#! @PERLV_PATH@
2
2
##
3
 
## $Id: arancid.in,v 1.28 2007/11/16 02:22:51 heas Exp $
 
3
## $Id: arancid.in,v 1.32 2008/02/08 22:25:08 heas Exp $
4
4
##
5
5
## @PACKAGE@ @VERSION@
6
 
## Copyright (c) 1997-2007 by Terrapin Communications, Inc.
 
6
## Copyright (c) 1997-2008 by Terrapin Communications, Inc.
7
7
## All rights reserved.
8
8
##
9
9
## This code is derived from software contributed to and maintained by
178
178
        /^(ACEdirector.*|ACEswitch.*|Alteon.*)/i &&
179
179
          ProcessHistory("COMMENTS","keysort","A1", "\/\*Model: $1\n") && next;
180
180
        /^Software Version\s+(.*?)\s\((.*)\)/i &&
181
 
          ProcessHistory("COMMENTS","keysort","B1", "\/\*Image: Software: $1 ($2)\n") && next;
 
181
          ProcessHistory("COMMENTS","keysort","B1",
 
182
                         "\/\*Image: Software: $1 ($2)\n") && next;
182
183
        /^Hardware Part No:\s+(.*?)\s+/i &&
183
 
          ProcessHistory("COMMENTS","keysort","A2", "\/\*Hardware part no: $1\n") && next;
 
184
          ProcessHistory("COMMENTS","keysort","A2",
 
185
                         "\/\*Hardware part no: $1\n") && next;
184
186
        /^MAC address:\s+([0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2})/i &&
185
 
          ProcessHistory("COMMENTS","keysort","C1", "\/\*Base MAC address: $1\n") && next;
 
187
          ProcessHistory("COMMENTS","keysort","C1",
 
188
                         "\/\*Base MAC address: $1\n") && next;
186
189
    }
187
190
    return(0);
188
191
}
208
211
        next if (/^\/\* Configuration dump taken/i);
209
212
        next if (/^\/\* Version.*Base MAC.*/i);
210
213
 
211
 
                if (/^\/?script end/) {
212
 
                $found_end = 1;
213
 
                ProcessHistory("","","","$_\n");
214
 
                return(1);
215
 
                }
 
214
        if (/^\/?script end/) {
 
215
            $found_end = 1;
 
216
            ProcessHistory("","","","$_\n");
 
217
            return(1);
 
218
        }
216
219
 
217
220
        ProcessHistory("","","","$_\n");
218
221
    }
232
235
@commands = map(keys(%$_), @commandtable);
233
236
%commands = map(%$_, @commandtable);
234
237
 
235
 
$cisco_cmds=join(";",@commands);
236
 
$cmds_regexp=join("|",@commands);
 
238
$cisco_cmds = join(";",@commands);
 
239
$cmds_regexp = join("|",@commands);
237
240
 
238
241
if (length($host) == 0) {
239
242
    if ($file) {
289
292
TOP: while(<INPUT>) {
290
293
    tr/\015//d;
291
294
    if (/^>>.*$prompt exit/) {
292
 
        $clean_run=1;
 
295
        $clean_run = 1;
293
296
        last;
294
297
    }
295
298