Automator action to move a specific file type to a folder..

've started shooting pictures in raw and jpg format. After I grab the pics from my camera, I'd like to put the raw files in a separate folder.
I've played around a little but can't figure it out-- so I dunno if it's possible. Is there a way I can make an automator action where I enter or select the folder and run the action. It then makes a folder named RAW and moves all of a certain file type to the RAW folder. Is this possible with automator?
I'd like it to make a folder named RAW inside the current folder I'm in or have selected.
I think I figured this out using filter finder items, and move to specific folder, but I think I need to learn how to use variables for this to work how I want it. Do I need variables or is there another way?

the following script should do it provided your Raw image files have extensions "raw" (do they?). If they have another extension, modify next to the last line accordingly.
tell application "Finder"
set theFolderName to "Raw"
set curFolder to (folder of the front window as alias)
-- Determine whether the specified folder exists
if folder theFolderName of curFolder exists then
set theFolder to folder theFolderName of curFolder
-- Create a new folder, if it doesn't exist
else
set theFolder to make new folder at curFolder with properties {name:theFolderName}
end if
move (every file of curFolder whose name extension is "raw") to theFolder
end tell
Save the above script as an application using Script editor. To use it, select the folder you want to work on and run the script.

Similar Messages

  • How to delete a specific file type from a folder

    Hi,
    I have folders with lots of zip or rar files, once I decompress those I want to delete the compressed files specifically. Is there any way I could manage that through Automator?
    Thanks in advance.

    Thanks Niel for the script, unfortunately I am too ignorant about running these on my own, I did save it in my user script library, but I would need instructions to run it. I would be really grateful.
    I did try making up my own workflow using the given actions in Automator, the first action was to 'find specific files in finder' ending with .zip and .rar and then choosing another action which 'moves selected files to trash'. Unfortunately it ended up running only if I specify the path to the specific .zip file, which defeats the purpose. Any suggestions on the proposed workflow? Thanks in advance.

  • Comparing count and combined file sizes of specific file types in target folder and subfolders

    Hi all,
    I have a script that I use to delete files with a certain file extension in a folder and its subfolders. I would like to enhance to the script by counting the total number of files and their combined size in MB that the script is deleting and use this information
    in a popup where a message will say something like "X No. Files deleted totalling YMB
    The existing script so far is:
    get-childitem  -include *.****.rfa -recurse | foreach ($_) {remove-item $_.fullname}
    Can any advise what I need to add as I'm quite new to powershell.
    Thanks

    So you do not know how to write a simple output statement.  I think you need to start here:
    http://technet.microsoft.com/en-us/scriptcenter/dd793612.aspx
    Not specifically within Powershell no, like I said I only started looking at it this week as an alternative to VBS.
    Nothing is being declared.  You need to learn the basics of PowerShell.  We cannot teach you one line at a time.
    Really? So the author of
    this website is talking rubbish is he? ("Once data is assigned to a PowerShell variable, it’s automatically declared.")
    I never asked for line-by-line hand holding nor am I someone who wants others to write the entire code for me. Examples of previous scripts that perform similar or partial operations would have been a good way to guide a new user unfamiliar to this topic.
    Additionally posting modified(incorrect) and unfinished script examples without clearly stating what your code is doing nor that additional lines of code need to be added before the script will operate as outlined in the original post is confusing to someone
    with 0 experience in this area.
    On forums I frequent that are relevant to subjects which I have good experience with, whenever I respond to a genuine query of that has an example of what they are trying to create/modify, I will happily provide a full example and/or explain what I
    have done so the OP understands exactly what I did to achieve their request in my example. For someone with your points tally (and likely a respected poster amongst your peers on this site) responding with what is essentially "RFTM Noob" I trust you can understand
    is somewhat disappointing.

  • Pre-Configure QT 7 Installation for only specific file types

    Is there an 'ini' or similar configuration file or command line option set I can use to pre-configure QT7 to only associate with specific file types?
    I want to leave the associations for Media Player intact and have QT handle only MOV and other Apple-specific file types.

    Basic answer. No.
    You set file associations after the install of QuickTime.
    Most of it's adjustments and options are found in its Control Panel. Here you can set associations for MIME types that control the browser plug-in.
    Each user can set their own values.

  • Automator - Metadatamover dont move, only copy files

    Hello,
    i wanto to create the following service in automator to rename image files and move the renamed files to a created folder.
    My workflow will be -> mark files, right click -> choose Rename Service -> Insert target folder Name -> Folder will be created, files renamed and move from source folder to target folder.
    This will worked for me, but he only copy the files and dont move it to the target folder? Why?
    What i did:
    Download the automator action MetaDataMover from here -> http://6v8.gamboni.org/-Automator-.html
    1. MetaDatamover (Action Move same directory, overwrite)
    2. Create New Folder (Show when run)
    What it does:
    It renames the files, creates the target folder, but dont move the files, only copy the files. How can i handle this? Where is my fault?
    Thanx in advance

    Thanks Eric. I don't see that option, but I did discover what the problem is:
    Sharing/Permissions were set to:
    System - read/write
    Wheel - read/write
    Everyone - read only
    Above the options window text read: "You can only read"
    After changing permissions to: "everyone - read/write"  all functions returned to "normal", so I guess the system was seeing "me" as a user, NOT the Admin. I am the sole user of this workstation. I appear to be logged in under my name, but maybe I am not considered the "admin"?
    Any further user/admin clarification appreciated. (When computer wakes up, I log in under my name, not guest)

  • Advice on allowing specific file types to be written to USB flash drive

    We currently have all of the Removable Storage Access policies enabled (Computer Config > Policies > Admin Templates > System/Removable Storage Access) and would like to know if it is possible to allow specific file types to be exempted from this
    policy. Specifically we need to allow certain users to write to USB flash drive but need to limit to MS Office files only.  Is this possible?
    Thanks in advance for any assistance.
    -Mike

    > Specifically we need to allow
    > certain users to write to USB flash drive but need to limit to MS Office
    > files only.  Is this possible?
    Third party products can do that. GPO cannot.
    Martin
    Mal ein
    GUTES Buch über GPOs lesen?
    NO THEY ARE NOT EVIL, if you know what you are doing:
    Good or bad GPOs?
    And if IT bothers me - coke bottle design refreshment :))

  • 2012 Deduplicated volumes - hydrate only specific file types

    I have a file server with roughly 4 TB of data. We have found that turning on 2012 Dedupe feature is causing corruption with Access databases. Databases worked fine for a week or better before we turned on Dedupe. Everything else appears to work fine.
    I know I can exclude specific file types (ie. AACDB, MDB, etc).  Simply excluding them won't re-hydrate the currently deduped database files correct?
    Is there a version of the start-dedupjob -type unoptimization where I can specify a file type so that I can just hydrate specific files?

    The corruption didn't start until after I migrated these file shares over to the 2012 server and enabled dedupe
    After we first noticed the problem, we moved just the databases back to a 2008 file server and didn't have any more problems.  Due to some other issues with backups, I moved all the data on the 2012 server to another drive on the same server and left
    dedupe turned off.
    I had to wait for about a week before turning dedupe on for the new hard drive.  During that time my users were able to work in a database that didn't get moved to the 2008 server.  A couple of days after I deduped the drive they are getting corruption
    issues again.
    2012r2 file server
    Win 7 clients w/ Office 2010
    Deduplication is implemented as a filter driver over NTFS. So I can bet you have some backup application installed (SQL Server specific?) and it has own filter drivers conflicting with MS dedupe. What apps do you run on that box except SQL Server (obvious)?
    StarWind VSAN [Virtual SAN] clusters Hyper-V without SAS, Fibre Channel, SMB 3.0 or iSCSI, uses Ethernet to mirror internally mounted SATA disks between hosts.

  • How to setup a routing rule for a specific file type for the content organizer?

    Hello,
    how can I set a routing rule for a specific file type, for example for "pdf" or for "docx", for my content organizer?
    As standard I can only choose for the rules the content type, name and title of the file uploaded.
    Thank you in advance!
    JohnyG

    Hi Johny,
    Based on your description, my understanding is that you want to create a routing rule for a specific file type.
    I recommend to create rules with the conditions as the image below shows for the Document content type(for example: .docx files):
    Best regards.
    Thanks
    Victoria Xia
    TechNet Community Support

  • 10.6 Automator: Workflow to move a selected file to the idisk?

    Hi,
    I am trying to make a workflow that moves a selected file to a certain folder on my idisk.
    I am able to make a workflow that:
    1. Gets a selected file
    2. Gets a server (idisk), although IF it is already connected/mounted
    3. Copies the selected file
    However - I would like the workflow to be able to log into the server if it is not mounted already, and also display a message at the end with the URL of the file I just copied.
    Anyone with experience with automator that could elabourate on these two issues?
    Sincerely regards,
    Kjell Are Refsvik

    Should be straight forward...consider a similar message in the AppleScript forum:
    http://discussions.apple.com/forum.jspa?forumID=724
    See you there, thanks.

  • SQL query/report for "count of specific file type"?

    I figured this would be a good first post, as I have found every question I have had to date by browsing the forums, but I am stumped with this one. I recently expressed some concern to HR regarding the use of...lets call it "unauthorized content"
    on our network. Getting little to no response, I would like to produce a report containing a total count based on specific file type. For example, how many .mp3 files are stored on company equipment, how many torrent files (sadly, this is true), etc.
    Having very basic knowledge of SQL, I am puzzled where to start. I am currently using SCCM SP3 and SQL 2008 R2 with both basic reporting and SSRS enabled on the site.

    You'll first need to inventory those file types then here's some reports for you.
    Get the pstreports from my skydrive, import them and you can cange the file type to mp3 or whatever you need. I monitor mp3 files too.
    http://cid-6a8d30f2bc0666d0.office.live.com/browse.aspx/SCCM%20Custom%20Reports
    John Marcum | http://myitforum.com/cs2/blogs/jmarcum/|

  • Search For Specific File Type (eg .txt)

    I know how how to find files in a folder using Java but how do you search for specific file types. I am looking only include files with the extension .txt in my search.

    Cheers. I already looked at that. Got a program that parses a XML and had a play about with it. Can print the contents of tags in my XML. Its just that im trying to parse my XML and have the contents of the starts_with tag to appear in startsWith(or a variable to which this has been assigned) and the contents of the extension tag to appear in endsWith. Totally clueless on how to go about it.
    Below is my class. Would be greatful if you have any ideas.
    import java.io.File;
    public class FindLatestFile {
                 public static File getLatest(File thisDir){
                         long latestModDate = -1;
                         File latestFile = null;
                         File[] fileList = thisDir.listFiles();
                         for(int i=0; i < fileList.length; i++){
                             File file = fileList;
         if (file.lastModified() > latestModDate & (file.getName().startsWith("A") & file.getName().endsWith(".txt"))) {
         latestModDate = file.lastModified();
         latestFile = file;
                             return latestFile;

  • MDT 2013 USMT customization to exclude specific file types

    Hi,
    I have a need to exclude a specific file type from migration with USMT within MDT 2013.
    So far, I think I know the following:
    I have to create a custom XML file.
    I have to place the custom XML file in the deployment share's Tools\x86|x64\USMT5 folder.
    I have to reference the custom XML file customsettings.ini using USMTMigFiles003 (1 and 2 are used by the default files).
    I think I'll need to use unconditionalExclude.
    However, I am having trouble finding a proper example of a custom XML file. I can find the reference documentation, but actually having a single example isn't as easy to find.
    Specifically, I want to exclude all VMDK (VMware virtual hard disks) from being migrated, regardless of where on the machine they are.
    Thanks for any assistance,
    SA.

    You need something like the below. You can find it in the provided link:
    <unconditionalExclude>
    If you want to exclude a file type from the migration, regardless of the other <include> or <exclude> rules, you can use the <unconditionalExclude> element. This element excludes objects globally across all components. For example, you
    should use this element if you want to exclude all .mp3 files from the computer.
    <migration urlid="http://www.microsoft.com/migration/1.0/migxmlext/excludefiles">
    <component context="System" type="Documents">
    <displayName>Test</displayName>
    <role role="Data">
    <rules>
    <unconditionalExclude>
    <objectSet>
    <script>MigXmlHelper.GenerateDrivePatterns ("* [*.mp3]", "Fixed")</script>
    </objectSet>
    </unconditionalExclude>
    </rules>
    </role>
    </component>
    </migration>
    http://technet.microsoft.com/en-us/library/cc722303%28v=ws.10%29.aspx#Ex1
    Dustin Estes - MCP | www.dustinestes.com

  • Can I only search for specific file types?

    Oftentimes I need to pickup just the InDesign file. I sort by type but there are word docs, images (lots of them!), web pages, etc. Is there a way to search in Client A's folder and all sub-folders for just InDesign files? Thx.

    You can use the filter panel for this. Click on the triangle in front of
    File Type (if it is not already open yet because it does so the moment there
    are two or more different File types in the folder you pointed Bridge to)
    Click on the File type you want to show and only those will appear in the
    content window
    Is there a way to
    search in Client A's folder and all sub-folders for just InDesign files? Thx.

  • Is it possible to move the temporary files and history settings folder to a second drive in Firefox 6.0, windows 7?

    <blockquote>Locking duplicate thread.<br>
    Please continue here: [[/questions/881940]]</blockquote>
    Internet Explorer 8 has this feature under the Internet Options heading. Does the Firefox 6.0 have a similar feature for placing all or part of the browsing history on a drive other than the one containing the operating system?

    You can use the Profile Manager to create a profile folder on the other drive.<br />
    You can't move only specific files.<br />
    Be sure to select a new and empty folder to be used exclusively as profile folder.<br />
    *http://kb.mozillazine.org/Profile_Manager
    *https://support.mozilla.com/kb/Managing-profiles

  • Find Specific File Type Group in Specific Folder

    Hi, I dont know how to find a specific group of files (i.e. all movies, all music etc) in one specific folder (and its sub folders) on Snowleopard.
    I do know how to find a single file type (i.e. .mov, .mp3)
    Thanks for the help.

    Hi,
    And, Welcome to Apple Discussions!
    In the search box, type
    kind:
    (that's "kind" followed by a colon) followed by either
    movie
    image
    or
    music
    I just tested it myself (I've never actually used it!) and it works a treat.
    HTH,
    S.
    Message was edited by: SiRGadaBout

Maybe you are looking for