Welcome, Register for free! or Login below:
EduGeek.net RSS Feeds Register FAQ Members Social Groups User Map Calendar Search Today's Posts Mark Forums Read

Scripts If you need or have any scripts then get 'em here.

Go Back   EduGeek.net Forums > Coding and Web Development > Scripts
Reply
 
LinkBack Thread Tools Search Thread
Sponsored Links
Old 03-07-2009, 02:31 PM   #1
 
burgemaster's Avatar
 
Join Date: Aug 2007
Posts: 182
uk
Thanks: 9
Thanked 14 Times in 9 Posts
Rep Power: 7 burgemaster will become famous soon enough
Default A directory list of SWF and MP3 - but EXCLUDING "ICT Work" and "ICT Music" Folders?

We are looking to cut down on the amount of MP3 and SWF in students areas.

Off the top of anyones heads, do you think it would be easy to run a script that would list all the SWF and MP3 in our students drives, but not list anything that is in thier "ICT Work" or "Music Work" folders.

and also Visa Versa ?

So once i have deleted all the files from thier home drives, the teacher can then have a regular log of all the SWF located in the ICT Work folders?

Thanks in advance
  Reply With Quote
Old 03-07-2009, 03:02 PM   #2
 
OutToLunch's Avatar
 
Join Date: Feb 2006
Location: Derbyshire
Posts: 1,262
uk
Thanks: 131
Thanked 189 Times in 152 Posts
Rep Power: 49 OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of OutToLunch has much to be proud of
Default

From the top level directory where the home directories are stored - old school CMD prompt action...

dir *.mp3 *.swf /s /b | find /i /v "\ICT Work" | find /i /v "\Music Work" > badlist.txt

Edit - just noticed the vice versa - for this one you'd have to use three lines...

dir *.mp3 *.swf /s /b | find /i "\ICT Work" | > goodlist1.txt
dir *.mp3 *.swf /s /b | find /i "\Music Work" | > goodlist2.txt
type goodlist1.txt >> goodlist2.txt

Goodlist2 would end up being a joined list of everything found in ICT Work + Music Work.

Last edited by OutToLunch; 03-07-2009 at 03:35 PM..
  Reply With Quote
Thanks to OutToLunch from:
burgemaster (06-07-2009)
Old 11-08-2009, 11:08 AM   #3
 
scsitsupport's Avatar
 
Join Date: Jan 2009
Posts: 7
uk
Thanks: 1
Thanked 0 Times in 0 Posts
Rep Power: 0 scsitsupport is an unknown quantity at this point
Default Powershell alternative

Hi Guys,

Just thought I'd throw this in as an alternative. It's a powershell script that will find all files for a specified file type (swf at the present) but ignore them if it's a particular file name. It will then move them to an alternate location but recreate the file structure so should you catch anything that is legitimate then it can easily be moved back.

We've set up a share that only the staff can access where these files get moved to so that they don't have to find one of us techies should they need it moving back.

Hope it helps. Here's the link.

PS - Find Files & Move Maintaining Hierarchy

*Requires Powershell V2
  Reply With Quote
Reply

EduGeek.net Forums > Coding and Web Development > Scripts

Similar Threads
Thread Thread Starter Forum Replies Last Post
Anyone had experience with "Turn IT On!" ICT support? AngryTechnician Recommended Suppliers 0 25-04-2009 08:30 PM
"Unexpected Error" when binding 10.4.11 clients to 10.5.4 Open Directory SteveMC Mac 1 31-08-2008 03:07 PM
"Error 403" & "Moved to here" message tech_guy Windows 4 24-01-2008 02:07 PM
Exams organiser >> "EDI directory does not exist" ittech MIS Systems 2 18-12-2007 10:25 AM
Office 2k3 "Insert Image from File" and "Mail Merge" prob Gatt Windows 6 28-09-2006 07:06 PM



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search Thread
Search Thread:

Advanced Search

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 06:46 PM.
Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.
Copyright EduGeek.net




website uptime

© 2005 - 2009 EduGeek.net
SERVER: 4
no new posts