#!/bin/bash 
#
#    Copyright (c) 2018-2019 Brocade Communications Systems, Inc.
#    All rights reserved.
#
#    Description:
#
#    This BSL CLI script will be run as part of the BSL inventory 
#    collection. It collects the list of chassis and VF based CLI command outputs.


file=$1
vfId=$2
lsId=$3

swCmdList=("cmd1" "cmd2");

chassisCmdList=("cmd1" "cmd2");

#Switch commands 
count=${#swCmdList[@]}
for (( i = 0; i < $count; i++ ))
	do 
		${swCmdList[$i]} > "$file/${swCmdList[$i]}.$vfId.cli"
	done

#Chassis commands
count=${#chassisCmdList[@]}
for (( i = 0; i < $count; i++ ))
	do 
		if [ $lsId -eq 0 ]; then
			${chassisCmdList[$i]} > "$file/${chassisCmdList[$i]}.cli"
		fi	
	done
