10-21-2006
Thanks for the reply. Although I'm sure you wont believe me, I read the rules before I posted.
After posting the question I realised that it wasn't clear. In the example I used above, I was after the last argument (which the thread you suggested does show how to do) but my question was as per the second article. That is to say it could be anywhere within the argument list. If i were to search, the terms I would be using would be position, argument, file, all terms ubiquitous to most threads. That is why i chose against searching.
Thanks for your response.
Mitch.
P.S. I am a nice guy, and understand where you are coming from. I know from experience what it is like partaking in forums where people ask questions that have been asked a hundred times before. I didn't just ignore the search feature off the cuff. Sorry if I pi**ed you off.
Last edited by spudtheimpaler; 10-21-2006 at 02:16 PM..
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
in vi, if i type ctrl-J, i can shift the next line up to the current line.
I need to do this whenever a specific string exists (in particular ^M) ,however i have not been able to find a way to do this in vi, sed, or awk
seems simple enough.
can someone help me?
thanks in advance (9 Replies)
Discussion started by: Brandt
9 Replies
2. Shell Programming and Scripting
I have a ascii file with lines like this:
240|^M\ ^M\^M\ Old Port Marketing order recd $62,664.- to ship 6/22/99^M\
when this record gets loaded into my database, the \ is stored literally and so the user sees carriage return \ (hex 0D 5C) when what i need is carriage return line feed (hex 0D... (1 Reply)
Discussion started by: Brandt
1 Replies
3. UNIX for Dummies Questions & Answers
Hi
I need to define a pattern that will match an open square bracket, a series of numbers fro 1 to 4 digits in length and a close square bracket. Examples of the numbers I will need to find are:
or
or
or
I am using BBEdit to search, and BBEdit uses the standard GREP search... (1 Reply)
Discussion started by: alisamii
1 Replies
4. Shell Programming and Scripting
hi there,
I am a complete newb to bash but am going to try and make a script to help me seach text files for strings of interest, any help that one of you gurus could pass on will be greatly received!!
I want to write something like:
in "text1.txt" find "string1" and copy out the line... (7 Replies)
Discussion started by: jumbo999
7 Replies
5. Shell Programming and Scripting
Hello
I am trying to do global search on access log files for a date and for either 'Error|error' string
ls -lrt *access* | grep "Sep 23" | awk '{print $9}'|xargs awk '/23\/Sep\/2011/ && /Error/ || /error'
Above matches All lines with 'error' as well unfortunately.
Is there a... (6 Replies)
Discussion started by: delphys
6 Replies
6. Shell Programming and Scripting
Hello;
we have :
awk '/reg_exp/,0/
prints every line after the first occurrence of "reg_exp"
But if I want to print rest of the lines AFTER the last occurrence of "reg_exp",
how would I do it ??
Tried :
awk ' ! (/reg_exp/,0)'
But it errored...
Thank you for any... (5 Replies)
Discussion started by: delphys
5 Replies
7. Shell Programming and Scripting
Hello all!
This is my first post and I'm very new to programming. I would like help creating a simple perl or bash script that I will be using in my work as a junior bioinformatician.
Essentially, I would like to take a tab-delimted or .csv text with 3 columns and write them to a "3D" matrix:
... (16 Replies)
Discussion started by: torchij
16 Replies
8. Red Hat
Cheers!
In /etc/syslog.conf, if an error type is not specified, is it logged anywhere (most preferable is it logged to /var/log/messages) or not?
To be more precise I am interested in error and critical level messages. At default these errors are not specified in syslog.conf, and I need to... (6 Replies)
Discussion started by: dr1zzt3r
6 Replies
9. UNIX for Dummies Questions & Answers
I have a text file (allWords.txt), that I would like to search through. Here is a snippet of what it looks like...
a
aah
aahed
aahing
aahs
aardvark
aardvarks
aardwolf
ab
abaci
aback
abacus
abacuses
abaft
......
I would like to use the grep search to search, line by line, for... (8 Replies)
Discussion started by: blackvelvet
8 Replies
LEARN ABOUT DEBIAN
afp_ldap.conf
AFP_LDAP.CONF(5) Netatalk 2.2 AFP_LDAP.CONF(5)
NAME
afp_ldap.conf - Configuration file used by afpd(8) to configure a LDAP connection to an LDAP server. That is needed for ACL support in
order to be able to query LDAP for UUIDs.
DESCRIPTION
/etc/netatalk/afp_ldap.conf is the configuration file used by afpd to set up an LDAP connection to an LDAP server.
Any line not prefixed with # is interpreted.
Note
You can use afpldaptest(1) to syntactically check your config
The required parameters and their meanings are:
PARAMETER
ldap_server
Name or IP address of your LDAP Server
ldap_auth_method
Authentication method: none | simple | sasl
none
anonymous LDAP bind
simple
simple LDAP bind
sasl
SASL. Not yet supported !
ldap_auth_dn
Distinguished Name of the user for simple bind.
ldap_auth_pw
Distinguished Name of the user for simple bind.
ldap_userbase
DN of the user container in LDAP.
ldap_userscope
Search scope for user search: base | one | sub
ldap_groupbase
DN of the group container in LDAP.
ldap_groupscope
Search scope for user search: base | one | sub
ldap_uuuid_attr
Name of the LDAP attribute with the UUIDs.
Note: this is used both for users and groups.
ldap_name_attr
Name of the LDAP attribute with the users short name.
ldap_group_attr
Name of the LDAP attribute with the groups short name.
EXAMPLES
Example. afp_ldap.conf setup with simple bind
ldap_server = localhost
ldap_auth_method = simple
ldap_auth_dn = cn=admin,dc=domain,dc=org
ldap_auth_pw = notthisone
ldap_userbase = ou=users,dc=domain,dc=org
ldap_userscope = one
ldap_groupbase = ou=groups,dc=domain,dc=org
ldap_groupscope = one
ldap_uuid_attr = some_attribute
ldap_name_attr = cn
ldap_group_attr = cn
SEE ALSO
afpd(8), AppleVolumes.default(5), afpldaptest(1)
Netatalk 2.2 30 Mar 2011 AFP_LDAP.CONF(5)