10-12-2006
Copy code from shell
Hi everyone.. I'm a full-fledged newbie so bear with me. =)
I'm running code in the shell, and I'd like to copy the lines into a text file. Everytime I try using Contrl-C, the lines repeat as code. Is there some sort of export history function I can use?
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I accidentally assigned a password to the root user on this system and I don't remember what it was.. I was messing around with commands trying to learn the OS.
I have an old Indy R5000 system and I do not have a working cd drive for it to run the irix installation.
I booted into the PROM... (6 Replies)
Discussion started by: Qubbe
6 Replies
2. UNIX for Dummies Questions & Answers
Hi,
whenever I copy a code to vi session from other script it just goes weird.
It just goes across the whole screen and looks really bizzare
If the code is small I can manually remove the tabs and indent it correctly but if it is 2000 lines it makes it really difficult.
Is there something... (12 Replies)
Discussion started by: rooh
12 Replies
3. Shell Programming and Scripting
Hi,
I need to save content of the copy buffer to file.
I can open a text editor, paste it and save it. But I want to do it in script because I will do other actions with this file.
Is there any opportunity to it from shell?
I'm using Solaris 9. (0 Replies)
Discussion started by: kwama
0 Replies
4. Shell Programming and Scripting
How to run another shell and have all current shell dectaration copied to that new shell?
I would like to have available all current declarations in a new shell. That are functions, aliases, variables.
I need to test some functions that use the 'exit', but running it in current shell on... (9 Replies)
Discussion started by: alex_5161
9 Replies
5. UNIX for Advanced & Expert Users
Hello,
I am making a script to copy files interactively from one directory to another using the "i" option because I dont want to overwrite the files.
cp -i *.html ./../otherdir/
cp: do you want to overwrite (y/n) ?
I used
cp -i *.html ./../otherdir/
ans='n'
read $ans
... (4 Replies)
Discussion started by: telecomics
4 Replies
6. Shell Programming and Scripting
Dear all,
I have a database with thousands of files with the structure of name is:
Filename_hour_year.abc
Filename_hour_year_1.abc
..............
So what I need is how to write a script that all file with contain the character "_1" will copy to "_2"
For example: file name:... (7 Replies)
Discussion started by: hainguyen1402
7 Replies
7. UNIX for Dummies Questions & Answers
Hello,
I am currently learning UNIX scripting and have written a simple copy program.
However, upon execution, it returns an error despite debugging correctly.
Can anyone assist in explaining this?
Attached screenshots illustrating a test execution.
Many thanks. (13 Replies)
Discussion started by: dixer
13 Replies
8. Shell Programming and Scripting
Heyas
I'm currently attempting to apply the code of tui-select to tui-list.
That is because tui-list simply made a 1 string list, while tui-select uses dynamicly up to 3 strings per line.
Anyway, so i copy pasted the code, and just made the changes marked with red....
Know that both scripts... (2 Replies)
Discussion started by: sea
2 Replies
9. Shell Programming and Scripting
Hi,
I am new to scripting and i am trying to use below script to copy code to multiple servers and multiple locations on each server. the script is not working or doesnt give any error. Any help is appreciated. basically i want a script to get the code from a location (dir below) and read the... (2 Replies)
Discussion started by: Ron0612
2 Replies
10. Shell Programming and Scripting
I am trying to copy files with specific date and name to another folder. I am very new to shell scripting so i am finding it hard to do that. see the sample code i have written below.
srcdir="/media/ubuntu/CA52057F5205720D/Users/st4r8_000/Desktop/office work/26 nov"... (13 Replies)
Discussion started by: Aqeel Abbas
13 Replies
LEARN ABOUT OPENDARWIN
slapd-shell
SLAPD-SHELL(5) File Formats Manual SLAPD-SHELL(5)
NAME
slapd-shell - Shell backend to slapd
SYNOPSIS
/etc/openldap/slapd.conf
DESCRIPTION
The Shell backend to slapd(8) executes external programs to implement operations, and is designed to make it easy to tie an existing data-
base to the slapd front-end.
This backend is is primarily intended to be used in prototypes.
WARNING
This backend's calling conventions have changed since OpenLDAP 2.0. The abandon operation now gets a new "pid:" line. The "msgid:" lines
will be removed in a future version.
CONFIGURATION
These slapd.conf options apply to the SHELL backend database. That is, they must follow a "database shell" line and come before any subse-
quent "backend" or "database" lines. Other database options are described in the slapd.conf(5) manual page.
These options specify the pathname and arguments of the program to execute in response to the given LDAP operation. Each option is fol-
lowed by the input lines that the program receives:
abandon <pathname> <argument>...
ABANDON
msgid: <message ID of operation to abandon>
<repeat { "suffix:" <database suffix DN> }>
pid: <process ID of operation to abandon>
add <pathname> <argument>...
ADD
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
<entry in LDIF format>
bind <pathname> <argument>...
BIND
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <DN>
method: <method number>
credlen: <length of <credentials>>
cred: <credentials>
compare <pathname> <argument>...
COMPARE
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <DN>
<attribute>: <value>
delete <pathname> <argument>...
DELETE
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <DN>
modify <pathname> <argument>...
MODIFY
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <DN>
<repeat {
<"add"/"delete"/"replace">: <attribute>
<repeat { <attribute>: <value> }>
-
}>
modrdn <pathname> <argument>...
MODRDN
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <DN>
newrdn: <new RDN>
deleteoldrdn: <0 or 1>
<if new superior is specified: "newSuperior: <DN>">
search <pathname> <argument>...
SEARCH
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
base: <base DN>
scope: <0-2, see ldap.h>
deref: <0-3, see ldap.h>
sizelimit: <size limit>
timelimit: <time limit>
filter: <filter>
attrsonly: <0 or 1>
attrs: <"all" or space-separated attribute list>
unbind <pathname> <argument>...
UNBIND
msgid: <message id>
<repeat { "suffix:" <database suffix DN> }>
dn: <bound DN>
Note that you need only supply configuration lines for those commands you want the backend to handle. Operations for which a command is
not supplied will be refused with an "unwilling to perform" error.
The commands - except abandon and unbind - should output:
RESULT
code: <integer>
matched: <matched DN>
info: <text>
where only RESULT is mandatory. The search RESULT should be preceded by the entries in LDIF format, each entry followed by a blank line.
Lines starting with `#' or `DEBUG:' are ignored.
EXAMPLE
There is an example search script in the slapd/back-shell/ directory in the OpenLDAP source tree.
LIMITATIONS
The shell backend does not support threaded environments. When using the shell backend, slapd(8) should be built --without-threads.
FILES
/etc/openldap/slapd.conf
default slapd configuration file
SEE ALSO
slapd.conf(5), slapd(8), sh(1).
OpenLDAP 2.1.X RELEASEDATE SLAPD-SHELL(5)