Have some files in /tmp/dir
abc.zip
123.zip
345.zip
and if name matches to 345.zip then take action
My code....
am i doing something wrong ? Please advise.
#!/bin/bash
set -x
cd /tmp/dir
for i in *.*
do
if ]
then (4 Replies)
lets explain it easy by showing the initial file and desired file:
I've a file such this that contains:
initial_file:
31/12/2011 23:46:08 38.6762 43.689 14.16 Ml 3.1
... (1 Reply)
Hi all,
I need some help with a script I would like to amend.Let's say it's a simple script like the one below
controls=`grep line /etc/file |grep -v "^#"| awk -F":" '{print $4}'`
for cc in $controls
do
echo $cc
sleep 2
done
cc variable holds a list of 40 numbers.... (2 Replies)
I am writing a shell script that takes at least 2 arguments. The first is an octal representation of file permissions, the second is a command that is executed on all the files found with that permission.
#!/bin/sh
find . -perm $1 -exec $2 $3 $4 {} \;
invoked: ./script.sh 543 ls -la
what... (3 Replies)
Hi..
When i refered the script /etc/rc.sysinit...
i found the "action commands" like
But this is not working in my shells..
the following error is coming...
Please anybody help
Thanks in advance
esham (5 Replies)
ubuntu-dev-tools(5) File Formats Manual ubuntu-dev-tools(5)NAME
ubuntu-dev-tools - Configuration for the ubuntu-dev-tools package.
DESCRIPTION
The ubuntu-dev-tools package is similar in scope to the devscripts(1) package, providing a collection of scripts which may be of use to
Ubuntu and Debian developers or others wishing to build Debian packages.
Some of these scripts have options which may be configured on a system-wide and per-user basis. These options are configured in
devscripts.conf(5).
All variables are described in the script's manpages. Package-wide variables begin with "UBUNTUTOOLS" and are listed below.
Every script which reads the configuration files can be forced to ignore them by using the --no-conf command-line option.
ENVIRONMENT
All ubuntu-dev-tools configuration variables can be set (and overridden) by setting them in the environment (unlike devscripts).
In addition, several scripts use the following environment variables:
UBUMAIL
Overrides DEBEMAIL and DEBFULLNAME when the target is clearly Ubuntu. Can either contain an e-mail address or Full Name
<email@example.org>.
DEBEMAIL, DEBFULLNAME
As in devscripts(1).
PACKAGE-WIDE VARIABLES
The currently recognised package-wide variables are:
UBUNTUTOOLS_BUILDER
This specifies the preferred test-builder, one of pbuilder (default), sbuild, pbuilder-dist.
UBUNTUTOOLS_DEBIAN_MIRROR
The preferred Debian archive mirror. Should be of the form http://ftp.debian.org/debian (no trailing slash). If not specified, the
master will be used.
UBUNTUTOOLS_DEBSEC_MIRROR
The preferred Debian security archive mirror. Should be of the form http://security.debian.org (no trailing slash). If not speci-
fied, the master will be used.
UBUNTUTOOLS_UBUNTU_MIRROR
The preferred Ubuntu archive mirror. Should be of the form http://archive.ubuntu.com/ubuntu (no trailing slash). If not specified,
the master will be used.
UBUNTUTOOLS_UBUNTU_PORTS_MIRROR
The preferred Ubuntu archive mirror. Should be of the form http://ports.ubuntu.com (no trailing slash). If not specified, the mas-
ter will be used.
UBUNTUTOOLS_LPINSTANCE
The launchpad instance to communicate with. e.g. production (default) or staging.
UBUNTUTOOLS_MIRROR_FALLBACK
Whether or not to fall-back to the master archive mirror. This is usually the desired behaviour, as mirrors can lag the masters.
If on a private network with only a local mirror, you may want to set this to no. One of yes (default) or no.
UBUNTUTOOLS_UPDATE_BUILDER
Whether or not to update the test-builder before each test build. One of yes or no (default).
UBUNTUTOOLS_WORKDIR
The directory to use for preparing source packages etc. When unset, defaults to a directory in /tmp/ named after the script.
SEE ALSO devscripts(1), devscripts.conf(5)AUTHORS
This manpage was written by Stefano Rivera <stefanor@ubuntu.com>.
ubuntu-dev-tools December 19 2010 ubuntu-dev-tools(5)