I have a directory e2e_ms_xfer/cent01
this contains the multiple files some of which will be named below with unique date time stamps
e2e_ms_edd_nom_CCYYMMDD_HHMM.csv
What I want to do is in a loop
1) Get the oldest file
2) Rename
3) Move it up one level from e2e_ms_xfer/cent01 to /e2e_ms_xfer
3) Process it
4) Move it down 2 levels to e2e_ms_xfer/cent01/done
4) Exit loop
This is what I have below but it does not do step 2 it says it cannot find files of that name although I have put 5 unique
e2e_ms_edd_nom_CCYYMMDD_HHMM.csv in the directory.
Last edited by Scrutinizer; 09-13-2013 at 07:54 PM..
Reason: code tags
1. If I have a file-yyyymmdd.dat in a directory DATA1, then how do I move this file to directory DATA2 and the file name change to file-yyyymmdd.dat.currenttime
I can manual do this
$mv fileA-yyyymmdd.dat ./DATA2/fileA-yyyymmdd.dat.`date +%Y%m%d%H%M%S`
but how do I move all of the files in... (1 Reply)
Using a bash script, I need to find all files in a folder "except" the newest file. Then I need to insert the contents of one text file into all the files found. This text needs to be placed at the beginning of each file and needs a blank line between it and the current contents of the file. Then I... (5 Replies)
I am connecting to a remote server (Unix) and doing a ftp dowmload of files. The script (VB script) works fine except for not being able to move the downloaded files on the remote server to another folder.
I need to move all files with an .asc extesnion from folder "tovecellio_edi" to folder... (1 Reply)
Hello,
I'm new in the forum and in UNIX scripting, what I need is to write a simple batch script that renames or move the files back & forth from one directory to another, and then schedule the script to run on the server when the scheduled down time is, which is on Thursdays at 8pm and during... (5 Replies)
Hi,
I need to do something easy but I can't seem to figure out how to do this.
Let's say I have 6 files in the directory below:
/ebsbeta_f/flash/EBSUATQB/onlinelog
o1_mf_6_55klt7nr_.log
o1_mf_3_55klskj4_.log
o1_mf_4_55klsrl1_.log
o1_mf_5_55klt09p_.log
o1_mf_2_55klv1ts_.log... (10 Replies)
hi people;
i want to make a file/folder operation as follows.
- i have 41 folders in Windows and each of them have same-named files (~200 files each) inside.
- i want to stack these files together in a folder but Windows is asking to "overwrite" (as usual) since the file names are the same.... (2 Replies)
Hello there! I'm having a lot of trouble writing a script.
The script is supposed to:
1) Find all files with the name "Object.mtl" within each folder in the directory: /Users/username/Desktop/convert/Objects
2) Search and replace the string ".bmp" with ".tif" (without the quotations)
3)... (1 Reply)
I'm using cygwin32 on Windows.
DN is an environment variable pointed at my download directory.
This command works to move the single most recent file in my download directory to my current directory:
mv "`perl -e '$p = $ARGV; opendir $h, $p or die "cannot opendir $p: $!"; @f = sort { -M $a... (2 Replies)
Hey guys,
I have wrote the following script to apply a module named "trinity" on my files. (it takes two input files and spit a trinity.fasta as output)
#!/bin/bash -l
#SBATCH -p node
#SBATCH -A <projectID>
#SBATCH -n 16
#SBATCH -t 7-00:00:00
#SBATCH --mem=128GB
#SBATCH --mail-type=ALL... (1 Reply)
Discussion started by: @man
1 Replies
LEARN ABOUT DEBIAN
smbc
SMBC(1) Samba Commander SMBC(1)NAME
smbc - Text mode SMB network commander.
DESCRIPTION
Samba Commander is a text mode SMB network commander. With SMBC, you can browse your local network or use the search function to find files
in a share. You can also download/upload files and directories or create them both locally and remotely. SMBC features the resume capabil-
ity and UTF-8 encoding support.
OPTIONS -V
--version
Displays the version of Smbc.
-h
--help
Prints a help message describing all Smbc's command-line options.
-f
--flush
Flushes all download lists. All files from ~/.smbc/ with dulist* name will be removed. In next run of Smbc the download/upload list
will be empty.
-l
--list
Shows all download lists from ~/.smbc/.
-s INT
--show=INT
Displays all items from list with INT number. You can get all numbers from the list executing smbc -l command.
-p
--sleep
Sleeps Smbc. Smbc doesn't download/upload any files when executing even if some file is waiting in queue.
-m STRING
--message=STRING
Receives message from samba. If you want that Smbc receives WinPopup message you must add the line below to smb.conf
message command = /path_to/smbc -m 'message from %f on %m' -i %s; rm %s
Now if you have running Smbc and someone sends you a WinPopup message Smbc immediately displays it. If you don't run a Smbc all WinPopup
messages wait for executing a Smbc.
-i STRING
--file=STRING
Sets file with samba message, usage only with -m.
MENUS AND KEYS
At top of the main menu is mini status bar. There is displayed small help with functions. When Smbc downloads/uploads any file in mini sta-
tus bar is displayed progress of downloading/uploading.
main menu - keys
(arrow-up) (p) - move one item up
(arrow-down) (o) - move one item down
(tab) (i) - change selected column
(t) - group/ungroup catalog or files
(end) (u) - go to the end off list
(home) (y) - go to the start off list
(F5) (d) - download/upload selected files and directories
(w) - reverse sorting
(enter) (x) - execute a workgroup, host, share or directory
(insert) (a) - select or unselect one item
(page up) (l) - move one screen up
(page down) (k) - move one screen down
(F8) (ctrl+d) - delete selected files and directories
(F7) (c) - create directory
(F3) (v) - view text file, execute workgroup, host, share or directory
(g) - go to workgroup, host, share in remote host
(e) - change type of sorting
(s) - edit download/upload list
(m) - send a WinPopup message
(b) - bookmark
(bb) - add item to bookmark
(q) - exit from Smbc
download/upload list menu - keys
(q) - exit from this menu
(del) (d) - set selected item to delete
(u) - set selected item to undelete
(m) - mark/unmark selected item
(space) - pause/resume selected item download
(ctrl+d) - delete all dirs and subdirs for selected item
(ctrl+f) - flush all items
(arrow-right) (.) - add 1 second to delay time
(arrow-left) (,) - take off 1 second from delay time
(shift+arrow-right) (>) - add 60 seconds to delay time
(shift+arrow-left) (<) - take off 60 seconds from delay time
(;) - add 1 second to delay time for all items
(') - take off 1 second from delay time for all items
(:) - add 60 seconds to delay time for all items
(") - take off 60 seconds from delay time for all items
(|) - copy current item delay time to all items
(n) - set try download now to select item
(N) - set try download now to all items
bookmark list menu - keys
(q) - exit from this menu
(b) - add item to bookmark and exit
(del) (d) - set selected item to delete
(u) - set selected item to undelete
(m) - mark/unmark item
(enter) (x) - go to selected item
message when connection broken - keys
(arrow-up) (.) - add 1 second to delay time
(arrow-down) (,) - take off 1 second from delay time
(shift+arrow-up) (>) - add 60 seconds to delay time
(shift+arrow-down) (<) - take off 60 seconds from delay time
find file menu - keys
> input items <
(enter) (tab) - go to the next item
(ctrl+p) - enable/disable interactive filtering
(ctrl+k) - exit from find file menu
> select items <
(tab) - go to the next item
(enter) - go to selected file
(q) - quit
AVAILABILITY
The latest version of this program can be found at http://smbc.airm.net.
SEE ALSO
README
BUGS
You are welcome to send bug reports about Smbc to
<smbc@airm.net>.
SEE ALSO smbc(1)AUTHOR
Originally written by Rafal Michniewicz <rafim@data.pl>.
SMBC Version 1.1.2 February 2005 SMBC(1)