10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello.
From a script, a command for a test is use :
find /home/user_install -maxdepth 1 -type f -newer /tmp/000_skel_file_deb ! -newer /tmp/000_skel_file_end -name '.bashrc' -o -name '.profile' -o -name '.gtkrc-2.0' -o -name '.i18n' -o -name '.inputrc'
Tha command... (3 Replies)
Discussion started by: jcdole
3 Replies
2. Shell Programming and Scripting
Hi all,
Forgive me for asking for help with my first post, but I am struggling here. I've been asked to translate a bash script into a Windows script (probably batch or powershell, not sure yet), so the first step is obviously understand what the bash script is doing. But I have no experience in... (5 Replies)
Discussion started by: el_foz
5 Replies
3. Shell Programming and Scripting
I have the following bash script lines in a file named test.sh.
#!/bin/bash
#
# Write Date to cron.log
#
echo "Begin SSI Load $(date +%d%b%y_%T)"
#
# Get the latest rates file for processing.
#
d=$(ls -tr /rms/data/ssi | grep -v "processed" | tail -n 1)
filename=$d
export filename... (3 Replies)
Discussion started by: ginowms
3 Replies
4. Shell Programming and Scripting
Hi,
I have the following lines in a script :
.
.
exec < some_file
.
.
.
I have very little idea about exec command. I would like to know what this does and what will happen if the file some_file does not exist. Specifically, I would like to know whether the lines following this... (5 Replies)
Discussion started by: elixir_sinari
5 Replies
5. UNIX for Dummies Questions & Answers
Hi can some one explain the following command , It would really help if some can really elloborate on what is happening out here
export PATH | exec /bin/sh ./auto_approve :q
P.S: This is the first time i am using exec ,so an elloboration what does it do and what is the use of the :q will be... (1 Reply)
Discussion started by: Sri3001
1 Replies
6. Shell Programming and Scripting
How can I use the exec command to log my korn shell session to the screen and the log file?
Currently I have this command:
$exec 1> ${LOG} 2>&1
This logs the output to the log file only. I want it to go to the screen also. Is this possible with this command?
thanks. (10 Replies)
Discussion started by: djehresmann
10 Replies
7. Shell Programming and Scripting
All,
I am using below shell script to output the content to outputfile.txt. What I am looking for is in addition to outputfile.txt, I want the output to be on standard output too.
exec > outputfile.txt
echo "Starting "
echo "ending" (5 Replies)
Discussion started by: basic_shell
5 Replies
8. Shell Programming and Scripting
can any one pls explain the meaning of
exec 1<&5 ?? its urgent (2 Replies)
Discussion started by: santosh1234
2 Replies
9. UNIX for Dummies Questions & Answers
I have a ksh script that contains the following:
find /dir1/dir2 -type f -name "FILE.*" -newer /dir1/dir2/afterme.txt -exec cp /dir1/dir2/dir3 {} \;
When I run it from the cli, it runs fine. When I run it from the ksh script I get
find: missing argument to `-exec'
I also tried -exec cp... (40 Replies)
Discussion started by: bbbngowc
40 Replies
10. Shell Programming and Scripting
hai
i want know the difference between two shell scripts those are
1)
a=2004
echo $a #output------2004
exec < inputfile
while read line
do
echo $a #output-------2004
a=2005
echo $line
echo $a ... (1 Reply)
Discussion started by: g_s_r_c
1 Replies
DH-EXEC-INSTALL(1) dh-exec DH-EXEC-INSTALL(1)
NAME
dh-exec-install - Install (and possibly rename) files.
SYNOPSIS
#! /usr/bin/dh-exec
debian/default.conf => /etc/my-package/start.conf
usr/bin/*
DESCRIPTION
Being a sub-command of dh-exec(1), this program must not be ran directly, but through dh-exec, which automatically runs all available
sub-commands if run bare; or explicitly with dh-exec --with=install.
It is meant to be used for dh_install(1) files, and those alone. If it finds that its input is not such a file, it will do nothing, but
echo back the contents.
The purpose of the program is to extend dh_install(1)'s functionality, by allowing to specify a destination filename.
This can be accomplished by a special syntax: the " => " mark between a source and a destination means that the source file should be
installed with the specified destination name.
For obvious reasons, the source must not be a wildcard, and the destination in this case must be a file, and not a directory.
All other non-comment lines are left alone.
RESTRICTIONS
Due to the way executable scripts are called from debhelper(1), there is no way to know what options were used for the original
dh_install(1). This means, that the --sourcedir option of dh_install(1) will not work correctly when dh-exec-install is in use.
IMPLEMENTATION
Internally, the renaming happens by creating a temporary directory under debian/tmp/, and copying (or moving, if the source was under
debian/tmp/ to begin with) the file there, with the new name.
This is done this way to allow dh_install(1) to do the real copying, and allow its options to continue working, even when renaming is
involved.
The temporary directory is put under debian/tmp so that it will be cleaned by dh_prep(1) when the clean target gets to run. Thus, no extra
code is needed anywhere to clean up the renamed files.
ENVIRONMENT
DH_EXEC_SCRIPTDIR
Indicates which directory the command-specific scripts should be sought for. If not specified, scripts will be searched for in
/usr/share/dh-exec/.
FILES
$DH_EXEC_SCRIPTDIR/dh-exec-install-*
The various scripts for the higher-level program.
SEE ALSO
debhelper(1), dh-exec(1), dh_install(1)
AUTHOR
dh-exec-install is copyright (C) 2011-2012 by Gergely Nagy <algernon@madhouse-project.org>.
2012-05-03 DH-EXEC-INSTALL(1)