I am trying to strip all leading and trailing spaces of a shell variable using either awk or sed or any other utility, however unscuccessful and need your help.
echo $SH_VAR | command_line Syntax.
The SH_VAR contains embedded spaces which needs to be preserved. I need only for the leading and... (6 Replies)
I'm trying to do something like that:
for $filename in `ls -1`
do
some_command $filename
done
but it doesn't work properly for file names with spaces, for...in splits at spaces. Anyway around? (4 Replies)
dear pro-coders,
is there any command out there that takes out the front spaces from a string?
sample strings:
4 members
5 members
3 members
but it has to be like so:
4 members
5 members
3 members (3 Replies)
Forgive me. I am very new to kornshell scripts. The simplest things stop me dead in my tracks.
Here are two such examples.
I want to save the first 19 characters of the following string to a variable.
"Operation Completed and blah blah blah"
I know this works (from another thread):
... (2 Replies)
Hi,
Could someone has any suggestions on this? When read a line from a file, I need to check the first char in the line, it could be a space or any char. But the leading spaces are removed by read.
Thanks. (2 Replies)
Hi all,
I've a .csv file containing data per line delimited with '|' (The fields may contains elements with spaces).
e.g. (really a sample)
ID|Name|fon
12345|Celal Dikici|+4921123456
12346|Celal Dikici Jun.|+4921123456
12347|Celal Dikici Sen.|+4921123456
12348|Celal|+4921123456... (3 Replies)
'String' file contains the following contents,
D11, D31, D92, D29, D24,
using ksh, I want to remove all white spaces between characters no matter how long the string is.
Would you please give me some help? (1 Reply)
I have a lot of files with keywords and unique names. I'm using a shell script to refer to a simple pattern file with comma separated values in order to match on certain keywords. The problem is that I don't understand how to handle the wildcard values when I want to skip over the unique names.
... (5 Replies)
Hi Gurus,
I have a requirement which needs to pass a parameter when calling the script, using this parameter to find a file name stored in master file. then read the file content. the issue is in the file name has a special character "$". don't know how to handle this. below is example:
the... (10 Replies)
Discussion started by: green_k
10 Replies
LEARN ABOUT DEBIAN
tm::materialized::stream
TM::Materialized::Stream(3pm) User Contributed Perl Documentation TM::Materialized::Stream(3pm)NAME
TM::Materialized::Stream - Topic Maps, abstract class for maps with stream based input/output drivers
SYNOPSIS
# this class will never be directly used for instantiation
# see the description in TM and individual low-level drivers (AsTMa, ...)
DESCRIPTION
This class is a subclass of TM, so it implements map objects. It is abstract, though, as it only defined how a stream-based driver package
should behave. It may thus be inherited by classes which implement external formats (TM::Materialized::AsTMa, TM::Materialized::XML, ....).
INTERFACE
Constructor
The constructor of implementations should expect a hash as parameter containing the field(s) from TM and one or more of the following:
url:
If given, then the instance will be read from this url whenever synced in.
file:
If given, then the data will be read/written from/to this file. This is just a convenience as it will be mapped to url.
inline:
If given, then the instance will be read directly from this text provided inline when synced.
If several fields ("file", "url", "inline") are specified, it is undefined which one will be taken.
Examples (using AsTMa):
# opening from an AsTMa= file
$atm = new TM::Materialized::AsTMa (file => 'here.atm');
# why need a file? files are evil, anyway
$atm = new TM::Materialized::AsTMa (inline => '# this is AsTMa');
SEE ALSO
TM
AUTHOR INFORMATION
Copyright 200[2-6], Robert Barta <drrho@cpan.org>, All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
http://www.perl.com/perl/misc/Artistic.html
perl v5.10.1 2008-04-10 TM::Materialized::Stream(3pm)