Sponsored Content
Full Discussion: Shell scripting task
Homework and Emergencies Homework & Coursework Questions Shell scripting task Post 302516955 by Strongid on Monday 25th of April 2011 03:23:54 PM
Old 04-25-2011
I copy all You written, then:

Code:
strongid@ktl ~ $ pico sav1
  
 UW PICO(tm) 4.10                             File: sav1

#!/bin/bash
while read -A ARR
do
    echo "${#ARR[@]} elements"
    for STR in "${ARR[@]}"
    do
    true
    done
done < band

                                           [ Read 9 lines ]

strongid@ktl ~ $ sh sav1
sav1: 5: Syntax error: Bad substitution

I don't exactly understand what ARR means, is it my array from band file?
so it's something like this [jonas algis andrius] ?
[tomas rimas karolis]
[saulius justas domas]
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

difference between AIX shell scripting and Unix shell scripting.

please give the difference between AIX shell scripting and Unix shell scripting. (2 Replies)
Discussion started by: haroonec
2 Replies

2. Shell Programming and Scripting

Optimized way of doing the task in shell programming

Hi I have a file consists of the following similar lines (10 mb file) 2008-05-15 02:15:38,268 RMSConnectionFactory - Setting session state for connection. 2008-05-15 02:15:38,277 RMSConnectionFactory - Returning WS connection. My task is to find out any missing second lines for... (14 Replies)
Discussion started by: pcjandyala
14 Replies

3. Shell Programming and Scripting

comment and Uncomment single task out of multiple task

I have a file contains TASK gsnmpproxy { CommandLine = $SMCHOME/bin/gsnmpProxy.exe } TASK gsnmpdbgui { CommandLine = $SMCHOME/bin/gsnmpdbgui.exe I would like to comment and than uncomment specific task eg TASK gsnmpproxy Pls suggest how to do in shell script (9 Replies)
Discussion started by: madhusmita
9 Replies

4. Shell Programming and Scripting

Parse an XML task list to create each task.xml file

I have an task definition listing xml file that contains a list of tasks such as <TASKLIST <TASK definition="Completion date" id="Taskname1" Some other <CODE name="Code12" <Parameter pname="Dog" input="5.6" units="feet" etc /Parameter> <Parameter... (3 Replies)
Discussion started by: MissI
3 Replies

5. Shell Programming and Scripting

Call Shell scripting from Perl Scripting.

Hi How to call a shell scripting through a Perl scripting? Actually I need some value from Shell scripting and passes in the Perl scripting. So how can i do this? (2 Replies)
Discussion started by: anupdas
2 Replies

6. What is on Your Mind?

Shell scripting vs Perl scripting

Hi all, I would like to start developping some good scripting skills. Do you think it would be best to start with shell scripting or Perl? I already got a fundation, really basics, in perl. but I am wondering what would be best to be good at first. Can you please help me determine which one to... (14 Replies)
Discussion started by: Pouchie1
14 Replies

7. Shell Programming and Scripting

Shell scripting task

Hi all, I am new to shell scripting. And I have a task to do, I tried all possible ways to solve this, but didn't. Iwas wondering maybe someone could help me. So I have a random file something like this Andrew John Mike Alfa Omega Beta And I need to create scrip witch would filter any... (1 Reply)
Discussion started by: Strongid
1 Replies

8. Shell Programming and Scripting

Can any programmer do this task in shell script...

input file's one set header is this, ----------------------------------------------------- OUTPUT FROM ASCII FILE: CAST #1 ----------------------------------------------------- CC Cruise Latitude Longitude YYYY MM DD Time Cast #Levels CA 8504 50.083 -144.883 1970 1 2... (6 Replies)
Discussion started by: Akshay Hegde
6 Replies

9. Shell Programming and Scripting

Whether Shell script can do this task ???

In following attached 748phy.xls file, fifth column is ST_Date, which contains time and dates in this format 22-11-2012 7:54:54 PM in single column I want it to split in this format either 1st column 22/11/2012 and in second column 7:54:54 PM Or like this in separate... (13 Replies)
Discussion started by: Akshay Hegde
13 Replies

10. UNIX for Beginners Questions & Answers

Need list of input and output parameter of task in a text file, using shell script

//file begin ===== //some code task abcd_; input x; input y,z; //some comment output w; //some comment reg p; integer q; begin //some code end endtask : abcd_ //some code //file end ===== expected output from above... (1 Reply)
Discussion started by: rishifrnds
1 Replies
KEYTAB-LILO.PL(8)														 KEYTAB-LILO.PL(8)

NAME
keytab-lilo - compile keytables files for use with LILO SYNOPSIS
/usr/sbin/keytab-lilo [-p R old_code = new_code ] ... [default_layout] kbd_layout DESCRIPTION
keytab-lilo is a program which compiles keytable definitions (in the format specified in keytables(5)) into a format which can be used by lilo(8) to set the keyboard type when booting [using the keytable parameter in /etc/lilo.conf]. kbd_layout should be the name of a map file which specifies the desired keyboard layout. This file may be a gzip(1) compressed map. If no file extension is given, .map.gz is assumed. If the full pathname is not specified, /usr/share/keymaps/ is assumed. Since lilo essentially needs to know the differences between the BIOS keyboard mapping and the one you require, the default_layout file should contain a keytables(5) file for the BIOS default mapping. If no default_layout file is specified, us.map.gz is used. keytab-lilo writes the output translation table as a binary string to standard output, so you should redirect it to a suitable file. lilo has no particular restrictions on the name of keyboard translation files, but the suggested naming convention and location is /boot/map- ping.ktl (where .ktl stands for "Keyboard Table for Lilo"). OPTIONS
-p R old_code = new_code Specifies corrections ("patches") to the mapping obtained from the translation table files. E.g. if pressing the upper case "A" should yield an at sign, -p 65=64 would be used. The -p option can be repeated any number of times. The codes can also be given as hexadecimal or as octal numbers if they are prefixed with 0x or 0, respectively. EXAMPLES
keytab-lilo dvorak >/boot/dvorak.ktl This is the most common form of invocation; it simply compiles the given map file (in this case dvorak) and puts the result in /boot/dvorak.ktl. AUTHOR
Werner Almesberger (almesber@bernina.ethz.ch). Peter Maydell (pmaydell@chiark.greenend.org.uk) wrote this manual page. SEE ALSO
lilo(8), keytables(5), gzip(1) lilo comes with extensive documentation which can be found in /usr/share/doc/lilo-doc/ on Debian-based systems. April 1998 KEYTAB-LILO.PL(8)
All times are GMT -4. The time now is 04:50 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy