I'm moving a list of files of some extension and I wish to output the moved filenames into a text file, I tried using the command below, but after all the files are moved, I got a blank file.
find /abc/temp -type f -mtime +365 \( -name "*.bak" -o -name "*.log" \) -exec mv -f {} /junk \; >>... (3 Replies)
Hello,
I am using rsync to make sure that my folder "local" mirrors the remote directory "remote". When a file is copied from "remote" to "local", I need to apply a bash script to it. What would be a neat way to do that?
Thanks
ps: is there a way to edit the title of the thread (I am a bit... (5 Replies)
Hi everyone,
In a directory I have files with various extensions. I would like to move all the files ending in .L2 into a directory: ~/test. But I would also like to show which files are being moved. Of course I could type:
$ ls *.L2
$ mv *.L2 ~/test
Is there a way I can combine these two... (5 Replies)
Hi,
I want to know the user ID who moved a file from one directory to another Directory.
Example: File1 created by user A is present in dirA
then some one has moved it to dirB using "mv" command
I want to know the user ID who moved the file to dirB.
As far as i know "ls -lrt" command... (1 Reply)
Hi.
I am actually doing all of this on OSX, but using unix apps and script.
I have built my own transparent rsync/open directory/mobility/etc set of scripts for the firm I work at, and it is all almost complete except for ONE THING.
I have the classic problem with rsync where if a user... (0 Replies)
I'm writing a script for searching substring in file content and then moving found files. So far I've wrote script shown below
grep -lir 'stringtofind' $1 | xargs mv -t $2
How can i count number of files moved? (4 Replies)
Discussion started by: Kadikis
4 Replies
LEARN ABOUT FREEBSD
prefix
PREFIX(1) General Commands Manual PREFIX(1)NAME
prefix - Script that allows you to reconfigure environment variables for multiple installations of a set of software installed on the same
machine
SYNOPSIS
prefix
DESCRIPTION
It is assumed that the software for each installation is all under a single directory whose name is assigned to an environment variable
called PREFIX.
This arrangement of enabling multiple installations of software on a single machine is useful at many times. On a single server, it can
provide for development, test, and production installations of software. Alternatively, on development servers, it allows for multiple
development "sandboxes", one for each developer. On production servers, it allows for multiple versions of the production software to be
installed. One might be the currently running software, one the previous software kept online as a fall-back, and one a new release of
software wich is scheduled to be brought online soon.
There are three usages of the prefix script:
(1) The interactive usage should be placed as the last line
of a user's ".profile". The user must be running the
Korn shell (ksh) or the Bourne Again shell (bash).
The user is prompted to enter one of the known PREFIX locations,
specified in the $HOME/.prefixes file or the /etc/prefixes file.
During configuration, the $PREFIX/.prefixrc file is sourced
in order to accomplish environment-specific configurations.
(2) The non-interactive user configuration does not consult
$HOME/.prefixes or /etc/prefixes or prompt the user, but merely
configures the environment in accordance with the cmd line argument.
(3) The batch command usage is mainly for running commands from
cron or running commands in another environment without changing
to that environment.
Usage (1): . prefix (sets up environment)
(2): . prefix <prefix> (non-interactive setup)
(3): prefix <prefix> <cmd> <args> (runs cmd configured for PREFIX)
This manual page was written for the Debian distribution because the original program does not have a manual page.
AUTHOR
Prefix was written by Stephen Adkins <spadkins@gmail.com>, and is part of the App-Options distribution.
This manual page was written by Jotam Jr. Trejo <jotamjr@debian.org.sv>, for the Debian systems (but may be used by others).
Oct 07, 2010 PREFIX(1)