diff options
author | Ole Mathias Aa. Heggem <olemathias.aa.heggem@gmail.com> | 2019-04-02 20:20:25 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-02 20:20:25 +0200 |
commit | 02bb6476b443765bb673d4a0e93770698e44e8a7 (patch) | |
tree | b7ae384ea3cc28f3550dd73b0baeb659faf43e26 /tech-support/labels/old/cable_labels.pl | |
parent | f706bae1c3c2222a702e4121e1db8b7e9d45ab50 (diff) | |
parent | 7cd4617b362b99562e265fd9715764e4976cdf3e (diff) |
Merge pull request #102 from sklirg/feat/support-label-scripts
Add label generation scripts for Tech Support
Diffstat (limited to 'tech-support/labels/old/cable_labels.pl')
-rw-r--r-- | tech-support/labels/old/cable_labels.pl | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/tech-support/labels/old/cable_labels.pl b/tech-support/labels/old/cable_labels.pl new file mode 100644 index 0000000..b461d03 --- /dev/null +++ b/tech-support/labels/old/cable_labels.pl @@ -0,0 +1,16 @@ +#!/usr/bin/perl + +use strict; +use warnings; + +my ($rows, $switches, $cables) = @ARGV; + +for my $row (1 .. $rows) { + next if (!($row & 1)); + + for my $switch (1 .. $switches) { + for my $cable (1 .. $cables) { + print join('-', ($row, $switch, $cable)) . ';' . "\n"; + } + } +} |