Sponsored Content
Top Forums Shell Programming and Scripting Change filename extensions..from command line Post 302490452 by cfajohnson on Monday 24th of January 2011 09:23:34 PM
Old 01-24-2011
Code:
cd /Downloads/3eb/
for file in album*/*.flac
do
  nf=${file#*/}
  mv "$file" "newdir/${nf%flac}mov"
done

 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How to change size of command line in unix

Hi, I'm trying to execute my program from $prompt by passing many parameters which is more than 300 charecters in line but unix not accepting those many charecters, could some one help me how to increase the size? thanks (7 Replies)
Discussion started by: krishna
7 Replies

2. Shell Programming and Scripting

Accepting filename as command line param and writing to it

Hi, Is it possible to accept a filename as command line parameter and then write to that file using command redirection? i tried the below script. outputfile=`echo $1` echo "Writing to file" > 'echo $outputfile' exit $returncode but it isnt working. is there any other way to... (9 Replies)
Discussion started by: silas.john
9 Replies

3. Shell Programming and Scripting

gzcat into awk and then change FILENAME and process new FILENAME

I am trying to write a script that prompts users for date and time, then process the gzip file into awk. During the ksh part of the script another file is created and needs to be processed with a different set of pattern matches then I need to combine the two in the end. I'm stuck at the part... (6 Replies)
Discussion started by: timj123
6 Replies

4. UNIX for Dummies Questions & Answers

Batch Renaming: Change files' extensions in many sub-directories

Hi all - I'm trying to rename a large number of files all at once and need some help figuring out the command line syntax to do it. I've already done quite a bit of research with the rename and mv commands, but so far haven't found a solution that seems to work for me. So: The files exist... (10 Replies)
Discussion started by: dave920
10 Replies

5. Shell Programming and Scripting

Using sed command to change end of line

I am looking to change a data file into a javascript string and this is the code that I am using: sed -i '' -e 's/^/str += "/' -e 's/$/";/' file.xml The first part -e 's/^/str += "/' works as intended, but the second part -e 's/$/";/' adds an additional newline to my file, so that instead of... (3 Replies)
Discussion started by: figaro
3 Replies

6. Shell Programming and Scripting

how to remove last two extensions of a filename

hi how to remove extensions of a file.. suppose i have a filename "gtk2-2.4.13-24.el4.x86_64.rpm" and i want the file name as "gtk2-2.4.13-24.el4" means want to remove last two "." extensions of a file can anyone help me in this thanks in advance srik (12 Replies)
Discussion started by: srikanthg
12 Replies

7. Shell Programming and Scripting

Multiple file rename (change in filename in unix with single command

Dear All, Please help ! i ham having 300 file with E.G. PMC1_4567.arc in seq. like PMC1_4568.arc,PMC1_4569.arc ...n and so on.. i want all those file to be rename like PMC_4567.arc ,PMC_4568.arc .. mean i want to remove 1 from first file name .. pls help.. (6 Replies)
Discussion started by: moon_22
6 Replies

8. Shell Programming and Scripting

one line command to change mode only if necessary

hi, sorry for posting this for a quick answer. Is there a one line command to change permissions on files in a directory to a given mode (say 554) and only for those files that do not already have that mode? Running chmod updates the last access/modified timestamp on the files, and i want to... (11 Replies)
Discussion started by: ysrini
11 Replies

9. Shell Programming and Scripting

How to pass a filename as a command line argument

Hi,I have a script which is given below :#!/bin/bash. ini_script.shdb2 connect to $DB_NAME user $DB2_UID using $DB2_PASSWORDfor file in `ls -1 ./sql/ddw/`do echo "Executing the file $file" echo db2 -tvf $filedonedb2 quiti want this script to accept directorie's names present in... (1 Reply)
Discussion started by: ektubbe
1 Replies

10. OS X (Apple)

Change Name of Bluetooth Device from Command Line in macOS

Mac Version 10.15.2 (macOS Catalina) Does anyone know how to change the name of a connected bluetooth device from the command line on macOS? I am having trouble with various bluetooth devices which I cannot get the "rename" option in the GUI to "save" properly and so I cannot rename a few... (0 Replies)
Discussion started by: Neo
0 Replies
RIPPERX(1)						      General Commands Manual							RIPPERX(1)

NAME
ripperX -- graphical (GTK) frontend for ripping and OGG/FLAC/MP3 encoding CD tracks SYNOPSIS
ripperX DESCRIPTION
This manual page documents briefly the ripperX command. This manual page was written for the Debian GNU/Linux distribution because the original program does not have a manual page. ripperX is an X-based program that uses cdparanoia to convert (i.e. "rip") CD audio tracks to WAV files, and then calls the Vorbis/Ogg encoder oggenc to convert the WAV to an OGG file. It can also call flac to perform loss-less compression on the WAV file, resulting in a FLAC file. Alternately, if you have an MP3 encoder installed such as toolame lame or bladeenc, it can then convert the WAV into a MP3 file. Besides a nice GUI interface, ripperX also supports CDDB queries to retrieve song and album information, progress meters, and pausing while ripping. OPTIONS
This program takes no command line arguments. After starting the application, select the Config button and cycle through the tabs to learn what options are configurable. Because Vorbis/Ogg typically uses variable bit rates, there is not a direct correlation between the bitrate selected for encoding and the rate used by oggenc. The bitrates selected in the MP3 tab of the Configuration dialog are passed to oggenc with the -b switch. Enabling or disabling VBR when using Vorbis/Ogg has no effect on the encoding process. The FLAC encoding currently does not accept any bitrate arguments, so any bitrate you specify in the config dialog will be ignored for this type of encoding. SEE ALSO
cdparanoia (1). oggenc (1). flac (1). toolame (1). Documentation in /usr/share/doc/ripperx/ BUGS
Many, to be sure... Please report them as you find them! AUTHOR
This manual page was written by tony mancill tmancill@debian.org for the Debian GNU/Linux system (but may be used by others). RIPPERX(1)
All times are GMT -4. The time now is 04:56 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy