The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Operating Systems > OS X (Apple)
.
google unix.com



OS X (Apple) OS X is a line of Unix-based graphical operating systems developed, marketed, and sold by Apple.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Using grep - check the permissions of the file searched Johny001 Shell Programming and Scripting 8 09-26-2008 06:46 AM
Grep or other ways to output line above and/or below searched line sammac UNIX for Dummies Questions & Answers 2 07-24-2008 03:28 AM
How to print the files names that being searched umen Shell Programming and Scripting 2 12-26-2007 02:49 AM
Please Help. Strings in file 1 need to be searched and removed from file 2 mjs3221 Shell Programming and Scripting 4 08-18-2006 04:13 PM
Unix ISO's for FTP, I've searched the other Posts killrazor UNIX for Dummies Questions & Answers 3 10-11-2002 11:05 AM

 
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
Prev Previous Post   Next Post Next
  #1 (permalink)  
Old 11-18-2008
virgo virgo is offline
Registered User
  
 

Join Date: Nov 2008
Posts: 1
I have searched, but I am confused

Please forgive me if a similar question has already been asked.

I have searched and found many possible solutions to my query.
I would appreciate it if someone can point me to a thread to accomplish my task.

I am trying to change values from a Master file to a File to be modified

Since there are about thousands of entries, I am trying to do this with a script and not manually.

Here is an example of one such entry.
Master file
Code:
Y:\Music\iTunes\iTunes Music\Andain\Beautiful Things\04 Beautiful Things (Photon Project remix).mp3	Beautiful Things (Photon Project remix)	Andain	138.00
File to be modified
Code:
<ENTRY MODIFIED_DATE="2008/11/16" MODIFIED_TIME="61889" AUDIO_ID="Ajw83d3d3d3d3d3d3d2p3d3d3d3d3d3d3d3azd3d3d3uuZZmd2VVj///////////////7P///////////////e/////////////////////////////////////////////////WVnd3h3msyqh7uJiM7+3O7cy7eKqqqrzczLu6qs3d3LvN3d7///3v///////////////J///////////////+//////////////////7N7cvszf/v/v7//////////////////////////////////+7/////////////////////////////////////////////////QQAAAA==" TITLE="Beautiful Things (Photon Project remix)" ARTIST="Andain"><LOCATION DIR="/Users/virgo/Music/iTunes/iTunes Music/Andain/Beautiful Things/" FILE="04 Beautiful Things (Photon Project remix).mp3" VOLUME="Macintosh HD" VOLUMEID="Macintosh HD"></LOCATION>
<ALBUM TRACK="4" TITLE="Beautiful Things"></ALBUM>
<INFO BITRATE="320000" GENRE="Trance" LABEL="Robbins Entertainment" COMMENT="Trance" COVERARTID="112:QHQJABBQRRIX0AZ3X5NXAUFX2EXD" PLAYCOUNT="4" PLAYTIME="571" RANKING="0" IMPORT_DATE="2008/11/4" LAST_PLAYED="2008/11/7" FILESIZE="22432"></INFO>
<TEMPO BPM="137.000473" BPM_QUALITY="100"></TEMPO>
<LOUDNESS PEAK_DB="-1.1137042" PERCEIVED_DB="-2.310534"></LOUDNESS>
<CUE_V2 NAME="AutoGrid" DISPL_ORDER="0" TYPE="4" START="3.6027959554479541" LEN="0" REPEATS="-1" HOTCUE="0"></CUE_V2>
</ENTRY>
The value I need to change in this example is from:
Code:
<TEMPO BPM="137.000473"
to
Code:
<TEMPO BPM="138.00"
What would the best approach be?
awk, sed or...?

Thanks

Last edited by virgo; 11-18-2008 at 12:36 AM..
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 08:18 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0