Sponsored Content
Top Forums Shell Programming and Scripting Simply Bash Script to Confirm that there are 2 Files in Same Folder Post 303027607 by gull04 on Thursday 20th of December 2018 07:45:27 AM
Old 12-20-2018
Hi,

I'll suggest that it's the way your search parameters are configured, as a simple example see below;

Code:
/-> touch a.txt A.txt
 /-> find / -name "[a,A].txt" -printf '%h\n'
/home/e434069
/home/e434069
 /-> find / -name a.txt -o -name A.txt -printf '%h\n'
/home/e434069
/->

As you can see there are implications for how you configure the find with the or option.

Regards

Gull04
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

script for Finding files in a folder and copying to another folder

Hi all, I have a folder '/samplefolder' in which i have some files like data0.txt, data1.txt and data2.txt. I have to search the folder for existence of the file data0.txt first and if found have to copy it to some other file; next i have to search the folder for existence of file... (5 Replies)
Discussion started by: satish2712
5 Replies

2. Shell Programming and Scripting

bash - batch processing folder of files by name

Hello Everyone!!! I need some help with a shellscript to batch process a folder of files with the imagemagick convert -append/+append command. The folder contains some hundred or thousand of small images in .png format which I would like to join together in order of their filenames. The... (3 Replies)
Discussion started by: imtombi
3 Replies

3. Shell Programming and Scripting

Bash folder manipulation - selecting/copying specified files

Bash/scripting newbie here - I feel this might be a trivial problem, but I'm not sure how to tackle it. I've got a folder of a year's worth of files, with some random number of files generated every day of the year (but at least one per day). I'm writing a script to automatically grab the file with... (6 Replies)
Discussion started by: WildGooseChased
6 Replies

4. UNIX for Dummies Questions & Answers

Bash script to rename all files within a folder...

Hi. I don't have any experience with making scripts in bash. I need a simple script to rename all files in a folder to the format file1.avi, file2.avi, file3.avi, and so on..... Please note that the original files have different filenames and different extensions. But they all need to be... (2 Replies)
Discussion started by: dranzer
2 Replies

5. Shell Programming and Scripting

URGENT!!! bash script to sort files into folder according to a string in the filename

Hi all. I am very new to linux scripting and i have a task i can only solve with a script. I need to sort files base on the date string in their filenames and create a folder using the same date string then move the files to their respective folders. Scenario: Folder Path:... (1 Reply)
Discussion started by: ace47
1 Replies

6. Shell Programming and Scripting

Bash script to sort files into folder according to a string in the filename

Hi all. I am very new to linux scripting and i have a task i can only solve with a script. I need to sort files base on the date string in their filenames and create a folder using the same date string then move the files to their respective folders. Scenario: Folder Path:... (1 Reply)
Discussion started by: ace47
1 Replies

7. UNIX for Dummies Questions & Answers

Do I need to extract the entire tar file to confirm the tar folder is fine?

I would like to confirm my file.tar is been tar-ed correctly before I remove them. But I have very limited disc space to untar it. Can I just do the listing instead of actual extract it? Can I say confirm folder integrity if the listing is sucessful without problem? tar tvf file1.tar ... (1 Reply)
Discussion started by: vivien_chu
1 Replies

8. Shell Programming and Scripting

Simply bash script

I have a bash script that has 13 variables and runs commands on them. I've copied the commands 13 times but I'd like to simplify it to simply add 1 to the previous and run 13 times. The variables are dir01=/path/to/dir01 dir01=/path/to/dir02 ... up to 13. (more may be added later) ...... (6 Replies)
Discussion started by: scribling
6 Replies

9. Shell Programming and Scripting

Bash script read specific value from files of an entire folder

Hello, I heva a problem creating a script that read specifc value from all the files of an entire folder I have a number of email files into a directory and i need to extrect from each file 2 specific values. After that i have to put them into a new file that looks like that: To: value1 ... (1 Reply)
Discussion started by: ahmenty
1 Replies

10. Shell Programming and Scripting

Request for Shell script to move files from Subfolder to Parent folder and delete sub folder

Hi Team, I am new to shell script and there is a requirement where files should be moved from Subfolder to parent folder. Eg: parent folder --> /Interface/data/test/IN Sub folder -->/Interface/data/test/IN/Invoice20180607233338 Subfolder will be always with timestamp... (6 Replies)
Discussion started by: srivarun15
6 Replies
oggdec(1)							   Vorbis Tools 							 oggdec(1)

NAME
oggdec - simple decoder, Ogg Vorbis file to PCM audio file (WAV or RAW). SYNOPSIS
oggdec [ -Qhv ] [ -b bits_per_sample ] [ -e endianness ] [ -R ] [ -s signedness ] [ -o outputfile ] file ... DESCRIPTION
oggdec decodes Ogg Vorbis files into PCM-encoded ("uncompressed") audio files, either WAV or RAW format. For each input file, oggdec writes to a filename based on the input filename, but with the extension changed to ".wav" or ".raw" as appro- priate. If the input file is specified as - , then oggdec will read from stdin, and write to stdout unless an output filename is specified. Like- wise, an output filename of - will cause output to be to stdout. Writing WAV format to stdout is a bad idea. WAV requires a seekable medium for the header to be rewritten after all the data is written out; stdout is not seekable. OPTIONS
-Q, --quiet Suppresses program output. -h, --help Print help message. -v, --version Display version information. -b n, --bits=n Bits per sample. Valid values are 8 or 16. -e n, --endian=n Set endianness for 16-bit output. 0 (default) is little-endian (Intel byte order). 1 is big-endian (sane byte order). -R, --raw Output in raw format. If not specified, writes WAV file (RIFF headers). -s n, --sign=n Set signedness for output. 0 for unsigned, 1 (default) for signed. -o filename, --output=filename Write output to specified filename. This option is only valid if one input [file] is specified. EXAMPLES
Decode a file enabler.ogg to enabler.wav as little-endian unsigned 16-bit (default options): oggdec enabler.ogg Decode a file enabler.ogg to enabler.raw as headerless little-endian unsigned 16-bit: oggdec --raw=1 enabler.ogg Decode enabler.ogg to enabler.crazymonkey as unsigned 8-bit: oggdec -b 8 -s 0 -o enabler.crazymonkey enabler.ogg Decode enabler.ogg to enabler.raw as big-endian signed 16-bit (any of the following): oggdec -R -e 1 -b 16 enabler.ogg oggdec -R -e 1 -b 16 -o enabler.raw - < enabler.ogg oggdec -R -e 1 -b 16 - < enabler.ogg > enabler.raw Mass decoding (foo.ogg to foo.wav, bar.ogg to bar.wav, quux.ogg to quux.wav, etc.): oggdec *.ogg SEE ALSO
ogg123(1) AUTHORS
Program Authors Michael Smith <msmith@xiph.org> Manpage Authors Frederick Lee <phaethon@linux.ucla.edu>, assisted by a few million monkeys armed with keyboards in irc://irc.openprojects.net/#vorbis 2002 July 03 oggdec(1)
All times are GMT -4. The time now is 11:25 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy