Sponsored Content
Top Forums Shell Programming and Scripting Add file extensions to files EXCEPT the script that is issuing Post 302894845 by jeffs42885 on Thursday 27th of March 2014 03:53:09 PM
Old 03-27-2014
A bit past my scripting skills but I will look into it. Can you provide an example of how I might accomplish this
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

List Files by Extensions

I have a unix directory with 500 plus files . When I do a ls -lR I can see ALL the files here . How can I sort this by the files extensions ? I can't enter ls -lR *.ext1 *.ext2 *.ext3 etc in case I miss out some files . (2 Replies)
Discussion started by: newbienix
2 Replies

2. Shell Programming and Scripting

Find files with 3 different extensions

Hi all, From one directory I need to fetch only files of type *.xls,*.csv,*.txt. I tried the find . -name '*.txt,*.csv,*.xls' -print. But it throws me error. Please do help me on this. Thanks Mahalakshmi.A (11 Replies)
Discussion started by: mahalakshmi
11 Replies

3. Shell Programming and Scripting

Sorting Files according to their Extensions...

I am trying to write a Korne Shell Script wherein we have to sort files according to their extensions(for eg. 1.sh, 5.sh, 9.sh together; 4.csh, 120.csh, 6.csh together and 7.ksh, 2.ksh, 59.ksh together) and move them to their respective directories viz. sh, csh and ksh... I think,... (1 Reply)
Discussion started by: marconi
1 Replies

4. Shell Programming and Scripting

Rename files extensions

Hello ! i have a few files like ... setup.001 setup.002 setup.003 setup.004 // to setup.095 and i would like to rename those files to ... setup.r01 setup.r02 setup.r03 setup.r04 // to setup.r95 (7 Replies)
Discussion started by: Putazo
7 Replies

5. Shell Programming and Scripting

Shell script regex help: accept only 3 file extensions

This regex is supposed to accept files with extensions 270, 276, and "txt" only. Everything else should be discarded. This is what I have. I'll spare you the rest of the code. ext =".\$" #ext =".\$" #ext =".\$" #ext =".\$" for xfile in `ls $dir | grep "$ext" | xargs`; do... (9 Replies)
Discussion started by: grep01
9 Replies

6. Shell Programming and Scripting

rename file, add extensions

Hi Guys, I have files named myfileaa,myfileab,myfileac,myfilesad.... till myfileav. Now i needs to rename all these files to myfileaa.txt ,myfileab.txt,myfileac.txt. Please help me how to do the same. Thanks in advance..!!! (4 Replies)
Discussion started by: jaituteja
4 Replies

7. Shell Programming and Scripting

looping through files with different extensions

Hi all, I am trying to make a for loop invoking files with different extensions (*.ugrd and *.vgrd) and I cant just make it work. Cant figure out how to load the files so as to use them in subsequent commands like the ones in this pseudo code. the files are arranged such that in one date for... (8 Replies)
Discussion started by: ida1215
8 Replies

8. Shell Programming and Scripting

adding file extensions to split output files

Hello, I've searched this forum and others for a solution to my problem but nothing seems just right, I'm hoping I can get some help (seems like this should be easy, and I apologize if I've missed something on the forum): I have several large .fastq DNA sequence files (~20million reads,... (2 Replies)
Discussion started by: ljk
2 Replies

9. AIX

AIX : Find files ignoring certain file extensions

Hi All, I am scripting a program to find and archive files. There are certain file types that I do not want to archive. Below is the scenario. I have created a lookup file which has details on folders days and file extensions that needs to be ignored I have separated the individual into... (4 Replies)
Discussion started by: kavinmjr
4 Replies

10. Shell Programming and Scripting

Mv all files with different extensions to a new name

Hello all! I want to move several files foo.aux foo.log foo.pdf foo.tex to bar_foo.aux bar_foo.pdf bar_foo.tex I am on tcsh % mv foo.* bar_!#:1 is not working. Thank you for your help marek (11 Replies)
Discussion started by: marek
11 Replies
SIEVEC(1)						      General Commands Manual							 SIEVEC(1)

NAME
sievec - Sieve script compiler for the Dovecot secure IMAP server SYNOPSIS
sievec [-d] [-x "extension extension ..."] script-file [out-file] DESCRIPTION
The sievec command is part of the Sieve implementation for the Dovecot secure IMAP server. Sieve (RFC 5228) is a simple and highly extensi- ble language for filtering e-mail messages. It can be implemented for any type of mail access protocol, mail architecture and operating system. The language cannot execute external programs and in its basic form it does not provide the means to cause infinite loops, making it suitable for running securely on mail servers where mail users have no permission run arbitrary programs. Using the sievec command, Sieve scripts can be compiled into a binary representation. The resulting binary can be used directly to process e-mail messages during the delivery process. The delivery of mail messages and therefore also the execution of Sieve scripts is performed by Dovecot's local delivery agent (LDA) called deliver. Usually, it is not necessary to compile the Sieve script manually using sievec, because deliver will do this automatically if the binary is missing. However, in some cases deliver does not have permission to write the compiled binary to disk, forcing it to recompile the script every time it is executed. Using the sievec tool, this can be performed manu- ally by an authorized user to increase performance. The sievec command accepts two arguments: the script-file argument specifies the script to be compiled and the out-file argument specifies where the (binary) output is to be written. This Sieve implementation reconizes files with a .sieve extension as Sieve scripts and corre- sponding files with a .svbin extension as the associated compiled binary. This means for example that Dovecot's deliver process will look for a binary file 'dovecot.svbin' when it needs to execute 'dovecot.sieve'. Such filename is chosen automatically for the binary output when the out-file argument is missing. If the script-file argument is a directory, all files in that directory with a .sieve extension are compiled into a corresponding .svbin binary file. The compilation is not halted upon errors; it attempts to compile as many scripts in the directory as possible. Note that the -d option and the out-file argument are not allowed when the script-file argument is a directory. The sievec command is also useful to verify Sieve scripts before using. Additionally, with the -d option it can output a textual (and thus human-readable) dump of the generated Sieve code to the specified file. The output is then identical to what the sieved(1) command produces for a stored binary file. This output is mainly useful to find bugs in the compiler that yield corrupt binaries. OPTIONS
-d Don't write the binary to out-file, but write a textual dump of the binary in stead. In this context, the out-file value '-' has special meaning: it causes the the textual dump to be written to stdout. The out-file argument may also be omitted, which has the same effect as '-'. The output is identical to what the sieved(1) command produces for a compiled Sieve binary file. Note that this option is not allowed when the out-file argument is a directory. -x "extension extension ..." Set the available extensions. The parameter is a space-separated list of the active extensions. By prepending the extension identi- fiers with + or -, extensions can be included or excluded relative to the default set of extensions. If no extensions have a + or - prefix, only those extensions that are explicitly listed will be enabled. Unknown extensions are ignored and a warning is produced. By default, all supported extensions are available, except for deprecated extensions or those that are still under development. For example -x "+imapflags -enotify" will enable the deprecated imapflags extension along with all extensions that are available by default, except for the enotify extension. AUTHOR
The Sieve implementation for Dovecot was written by Stephan Bosch <stephan@rename-it.nl>. Dovecot was written by Timo Sirainen <tss@iki.fi>. SEE ALSO
sieved(1), sieve-test(1) 4 July 2009 SIEVEC(1)
All times are GMT -4. The time now is 09:49 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy