Thursday, June 15, 2017

convert-ToMp3.ps1 Powershell script for ffmpeg or vlc player

6/15/2017: Sometimes, you just need to convert that video into an mp3 file. You, know, something to take along in the car. Something to spin at your next 'rave' (ho-hum). :P

So what I have here, is a Powershell 'wrapper' for ffmpeg or VLC Player's native ability to convert video's to Mp3. Sure, you could use ffmpeg's command line, (or VLC's Media > Convert\Save menu). But sometimes you want to convert a whole batch, or directory, or recursive directory tree! And that is exactly where this .ps1 comes in.

All you need to do is download and install one or both of the above. I've found that ffmpeg works more consistently and bug-free than VLC. But take your pick. And then get-content c:\path-to-videos\. and pipeline them into the script, and you're off to the mp3 races. Docs and examples are in the script comments.

Wednesday, June 14, 2017

get-ImdbSearch.ps1 Imdb search script

6/14/2017: Two Posts in a day! And both're scripts to-boot!

Source Updates (reflected at Github):
  • # 2:35 PM 3/24/2018 country: failing, they've dropped space after colon, make it optional; Language same issue; duration.innertext coming through blank, pretest and use duration.datetime instead,
  • # 9:20 PM 9/12/2017 typo fix; shifted a bunch of items to 2-stage: they were passing and handing back blank values, when matches failed. 

I like movies. A lot. Last time we moved, I donated piles of dvd's! 

Wonderful thing, moving. Clears the head!  Gives you massive perspective.
Makes you want to donate 300-400 books, and hundreds of dvd's, JUST BECAUSE YOU NEVER WANT TO MOVE THEM AGAIN! :D Ever!. Really. :^S

Anyway, on to today's script: This one runs an interactive Imdb title search (using Google - smaht!) for near-miss title-matching, then returns a console menu of the Google hits, from which to pick. Pick a movie from the menu, and it pulls some fairly decent amounts of info on the chosen flick from Imdb.

Shut 'em all down: close-WinsAll.ps1 Powershell script

6/14/2017: One of the distinct 'costs' of running Office 365/Office 2016 at the office, seems to be that I spend a lot more time:
  1. Shutting down my work box for patching (now that both centralized patch management AND Office 365, independently do their own self-scheduled patching passes),
  2. and, much more frequently and defensively rebooting my box to try to scrape a few more ounces of performance from Word/Excel2016's bloated mass and resource sucking appetite.  
Both of which motivations naturally mean I'm trying to get faster reboots through on my box -- and this is coming from a guy that for the last 4-5 years has consistently hibernated his laptop at each day's end, to try to hit the ground running the next day, from the point I left off. :^|

Anyway, needless to say, the prospects and days of running a given 'up' session of Win7 for, "a couple of weeks" a stretch, appear to be long, long gone. Well, until they hand me a 36gb laptop (and some down time from work burn, to reinstall everything back to spec). But I digress....

So what's the point of this post? Simple: I've got a small and handy script I use, to get my box knocked down and into a reboot POST-HASTE!.