#!/bin/sh shell question


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting #!/bin/sh shell question
# 1  
Old 02-23-2006
Data #!/bin/sh shell question

HI,
Nice to meet u... I am a newbie. I have met a problem in the work as following:
SRCLOG[0]="/Share/log/testlog/*"
SRCLOG[1]="/Share/log/systemlog/*"
SRCLOG[2]="/Share/log/log.conf"
SRCLOG[3]="/Share/log/message"
How can I get the file or directory value from each element of this array by shell? (How to remove the "/*"?)
Expect result :
SRCLOG[0]="/Share/log/testlog"
SRCLOG[1]="/Share/log/systemlog"
SRCLOG[2]="/Share/log/log.conf"
SRCLOG[3]="/Share/log/message"
Thank u very much indeed
Best Regards!

Last edited by GCTEII; 02-23-2006 at 05:32 AM..
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Usage of #!/bin/sh vs #!/bin/bash shell scripts?

Some question about the usage of shell scripts: 1.) Are the commands of the base shell scripts a subset of bash commands? 2.) Assume I got a long, long script WITHOUT the first line. How can I find out if the script was originally designed für "sh" or "bash"? 3.) How can I check a given... (3 Replies)
Discussion started by: pstein
3 Replies

2. AIX

Redistribution bin required for AIX. j7r164redist.7.1.0.25.bin

Hi, I am planning to install a version of Informatica on my AIX box. It requires a specific java build in pap6470_27sr2-20141101_01(SR2). The current link for IBM 64-bit SDK for AIX®, JavaTM Technology Edition, Version 7 Release 1 has a more recent version in j7r164redist.7.1.0.75.bin. Is... (4 Replies)
Discussion started by: meetpraveens
4 Replies

3. Shell Programming and Scripting

shell type.. /bin/uvalid?

Hi, I gave a command echo $SHELL --> To find out the shell I'm using, which gave me the below output echo $SHELL /bin/uvalid what does it mean? Please use code tags when posting data and code samples, thank you. (1 Reply)
Discussion started by: dnam9917
1 Replies

4. OS X (Apple)

When to use /Users/m/bin instead of /usr/local/bin (& whats the diff?)?

Q1. I understand that /usr/local/bin means I can install/uninstall stuff in here and have any chance of messing up my original system files or effecting any other users. I created this directory myself. But what about the directory I didn't create, namely /Users/m/bin? How is that directory... (1 Reply)
Discussion started by: michellepace
1 Replies

5. Shell Programming and Scripting

Convert perl-statement to /bin/sh shell

Hi, I'm doing a small shellscript which is going to take each line in a "queue file" and do stuff to them. I can do the script easily, but I'd like this one to be a bit prettier. Consider the following perl statement: ... foreach my $line (@filedata) { my ($a, $b, $c) = split(/\t/,... (4 Replies)
Discussion started by: brightstorm
4 Replies

6. Shell Programming and Scripting

[Bourne shell] Asking stuff with #!bin/sh urgent!

1. Accept a “userid” as a command line argument 2. Produce the following output: User userid has a home directory of /path/directory the default shell for this user is /path/shell 3. At this level, it may be assumed that the “userid” is a unique string in the file that is being searched 4.... (17 Replies)
Discussion started by: grandios
17 Replies

7. UNIX for Dummies Questions & Answers

fuser: difference with bin/sh and bin/ksh shell script

Hi, I have a problem I don't understand with fuser. I launch a simple shell script mysleep.sh: I launch the command fuser -fu mysleep.sh but fuser doesn't return anything excepted: mysleep: Then I modify my script switching from #!/bin/sh to #!/bin/ksh I launch the command fuser -fu... (4 Replies)
Discussion started by: Peuj
4 Replies

8. Shell Programming and Scripting

Using #! /bin/sh in Shell scripts

Hi All, What does #! /bin/sh mean in a shell script? Is it mandatory to include in a shell script? I'm able to execute the shell script without it. Any help on this would be appreciated. (4 Replies)
Discussion started by: sumesh.abraham
4 Replies

9. Shell Programming and Scripting

CSH CGI-BIN question ?

Hi, 1. How to Write csh CGI-BIN script which return a web page which show the environment of the executed script ? 2. How do we read command line on csh and ksh ? Thank's (2 Replies)
Discussion started by: 7eleven
2 Replies
Login or Register to Ask a Question
Module::Install::Share(3pm)				User Contributed Perl Documentation			       Module::Install::Share(3pm)

NAME
Module::Install::Share - Install non-code files for use during run-time SYNOPSIS
# Put everything inside ./share/ into the distribution 'auto' path install_share 'share'; # Same thing as above using the default directory name install_share; DESCRIPTION
As well as Perl modules and Perl binary applications, some distributions need to install read-only data files to a location on the file system for use at run-time. XML Schemas, YAML data files, and SQLite databases are examples of the sort of things distributions might typically need to have available after installation. "Module::Install::Share" is a Module::Install extension that provides commands to allow these files to be installed to the applicable location on disk. To locate the files after installation so they can be used inside your module, see this extension's companion module File::ShareDir. TO DO
Currently "install_share" installs not only the files you want, but if called by the author will also copy .svn and other source-control directories, and other junk. Enhance this to copy only files under share that are in the MANIFEST, or possibly those not in MANIFEST.SKIP. AUTHORS
Audrey Tang <autrijus@autrijus.org> Adam Kennedy <adamk@cpan.org> SEE ALSO
Module::Install, File::ShareDir COPYRIGHT
Copyright 2006 Audrey Tang, Adam Kennedy. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. See <http://www.perl.com/perl/misc/Artistic.html> perl v5.14.2 2012-03-01 Module::Install::Share(3pm)