• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Merge all names into 1 file
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Merge all names into 1 file


  • Subject: Re: Merge all names into 1 file
  • From: Andrew Oliver <email@hidden>
  • Date: Mon, 6 Nov 2006 09:51:38 -0800


On Nov 6, 2006, at 2:09 AM, Jan Bultereys wrote:

Hi all,

I have 7 tekst files (in TextEditor) with content like this:

A00166                         
A00167                         
BE_00020_MCLOCKMAN             
BE_00020_MMO_008
BE_99972_MPRLMGLAS2            
BE_99972_MPRLMUG
F83879                         
F83880
....

Is it possible to merge the 7 files into ONE where all the “duplicated” names are merged into one:
Meaning, for example if image A00166 is also in textfile 2 and 4 it should be repeated only 1 time into the “new merged” textfile.
And of course if the name of the image is only in one of the files it should also be in the “new merged” textfile.

Many thanks for any idea’s

This is trivial to do in a shell script:

do shell script "cat /path/to/files/* | sort -u > ~/Desktop/merged.txt"

Andrew
:)
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/mailman//archives/applescript-users

This email sent to email@hidden

References: 
 >Merge all names into 1 file (From: Jan Bultereys <email@hidden>)

  • Prev by Date: Re: Merge all names into 1 file
  • Next by Date: Re: Merge all names into 1 file
  • Previous by thread: Re: Merge all names into 1 file
  • Next by thread: detect power-saving mode
  • Index(es):
    • Date
    • Thread