I ran into an issue where I had to move files from one system to another and was running into issues because files had been set as read-only, had the archive flag set, or both. It was causing the system to skip files which wasn’t acceptable. Normally you could just use Windows to clear it in bulk, but that could potentially mess up file permissions. I needed a way to automatically just clear all flags but respect permissions.
I did some searching and didn’t find a utility that would do the job and most of the solutions I found required Powershell which wasn’t available on the system I was on. I ended up writing a quick console application in C# to do the trick. I’ve made it free and open sourced it in case anyone wants to use it.
If you need just the app, you can find the release build here with instructions. The app also prompts for input to make things a bit easier to use. There’s no install, no tracking or metrics, or anything else related to privacy concerns in this app. It’s a simple throwaway utility to get the job done and move on.
Please note that I did this in about 10 minutes for my own use so error handling is pretty much non-existent. I mention this because I did run into one issue where Windows was somehow seeing a folder with files in it as a file and it couldn’t be deleted or renamed and the utility couldn’t get past it until it was resolved. I didn’t spend much time debugging and jut used my Mac to rename the folder and Windows was able to recognize it after the change, so the utility was able to continue processing.
While setting up a new computer, Windows was throwing up warnings that filesÂ transferred from a backup drive might be unsafe. The filesÂ were text and images, so the warnings were safe to ignore but the directory had over one thousand files. Rather than unblocking each file manually, Windows PowerShell makes it easy to unblock files in bulk.
- Press Win + R on the keyboard to open the Run dialog.
- In the Run box, type powershell
For one folder without subdirectories, this snippet will do the trick.â€œ$env:userprofile\Downloadsâ€œ tells PowerShell to use the Download folder for the logged in user and unblocks all files in it. Change this to the folder path you need if it’s not the Downloads folder.
get-childitem â€œ$env:userprofile\Downloadsâ€œ | unblock-file
If you have sub-directories and need to unblock everything, use the -Recurse flag:
dir â€œ$env:userprofile\Downloadsâ€œ -Recurse | Unblock-File
Want to see a report of files to be unblocked before running it? The -WhatIf flag will show you without executing.
dir â€œ$env:userprofile\Downloadsâ€œ -Recurse | Unblock-File -WhatIf
Use a mac? You’ll want to grab Alfred App. I’m finding it an invaluable replacement for spotlight and the workflows allow me to supercharge my workflows. It’s so useful that I’ve purchased the Powerpack lifetime license.
In addition to the standard features, here are a list of the most useful workflows for dev/tech:
Kill process â€“ byÂ Nathan GreensteinÂ (@ngreenstein)
I use it as an activity monitor for CPU usage, and from there I can easily force quit any process if needed. Itâ€™s easier to see all processes on the Alfred UI instead of opening Activity Monitor on your mac. Thereâ€™s also the workflowÂ Kill Application â€“ by Sebastian Hallum ClarkeÂ (and also on his siteÂ you can find other cool workflows).
Timer â€“ by Daniel Bader
I use this one a lot. Itâ€™s super simple and by writing â€œTimerâ€ and the number ofÂ minutes, you can easily set a reminder. It’s great for anyone using theÂ PomodoroÂ technique or even if you leave something on the stove and want to go back to work.
Find Folder by Samvlu
Finds a folder by name. I find this is faster than spotlight in just about every search.
Smart Folders by Deanishe
List all the Smart Folders/Saved Searches (same thing) on your system and drill down into their contents. Works in much the same way as Alfred’s File Filter, but Smart Folders are also available outside Alfred and are a bit more flexible.
For example, you can configure a Smart Folder to show all video/audio/image files without having to specify each different filetype individually. If you already use Smart Folders, this workflow can save you the work of re-implementing them as File Filters.
What’s more, you can exclude specific filetypes with a Smart Folder, which Alfred cannot do.
Advanced Google Maps Search byÂ stuartcryan
This workflow gives you some quick and dirty shortcuts into Google Maps:
mapsethome <home address including street number, name, postcode> (i.e. what you would type into Google Maps)
mapsetwork <work address including street number, name, postcode> (i.e. what you would type into Google Maps)
Commands for Use:
maps <query> – Search Google maps for an address
dir <query> to <query> to <query> etc (seperate multiple addresses with ” to ” minus the quotes, and you will get a multiple location search)
dirfw Show directions from Work to address
dirfh Show directions from Home to address
dirtw <query> Show directions from query to Work address
dirth <query> Show directions from query to Home address
trafficw – Show traffic from Home to Work
traffich – Show traffic from Work to Home
StackOverflow Search by deanishe
If you use stackoverflow as much as I do, this is a must-have.
I find myself needing to calculate differences between dates in my personal life a lot lately. This workflow saves me a lot of time to do that. Want to know how far Christmas is away in days?Â ‘dcalc 12-25-16 – now d’ returns the number of days (assuming you’re using the US short format like I am).
Wifi Control by miroman
All my Macbooks periodically have issues with wifi. I’ve never been able to figure out what’s causing it but I use Wifi Control to restart the wifi which allows me to connect successfully.
I recently upgraded to Office 2016 on my Windows 10 desktop and was getting the error “Converter failed to save file” when double clicking on the file along with an “There was a problem sending the command to the program error” every time. I finally had enough with the annoyance to troubleshoot it and figured out a solve.
If you have the same issue, here’s how to fix it:
- Open your Default Programs configuration from the Control Panel. On Windows 10, you can hit start, type Default Programs, and it’ll open the app.
- Scroll down the list until you get to the Excel formats (XLS):
- If you see anything other than Excel as the default, you’ll need to change the default to Excel. For me, the issue was the Open XML Converter not being installed anymore after upgrading to 2016. To change the default, selectÂ the format, click the “Change Program” button and select Excel 2016 from the list of apps that pops up and click OK to set the association:
- You’ll need to do this for each format in the list to correct it. The most common formats you’ll use are XLS, XLSX, & XLT.
I’ve been spending more timeÂ switching from SVN to Git and learning the command line options. I’m finding a lot of the Mac Git terminal commands I run aren’t the same in Git Bash (Mingw64). One of the commands I use is the pbcopy command to copy the ssh key to the clipboard to paste into Github and Bitbucket accounts. I’m starting to use it more as I am learningÂ managing LinuxÂ servers and adding my key to login. I’m adding it here as a cheatsheet for myself but I thought others may find it useful.
clip < ~/.ssh/id_rsa.pub
pbcopy < ~/.ssh/id_rsa.pub
or if you want to view it in the terminal window:
Today I loaded up Visual Studio to continue work on a project and created by a random bunch of errors. All were complaints that various packages could not be loaded. The one I captured was:
I had just installed SyncFusion’s Essential Studio which apparently screwed something up. I tried doing a repair on Visual Studio which unfortunately did not work.
I was able to fix it by following these steps:
- Close Visual Studio Open the *Users*\AppData\Local\Microsoft\VisualStudio\12.0\ folder
- Rename the ComponentModelCache folder
- Restart Visual Studio.
Visual Studio should now rebuild the cache and no longer display the error messages.
Ever have a program or process that doesn’t end properly and runs in the background continuously?
I recently encountered this issue with VLC on one Windows 7 machine where it keeps the process never terminates. Since I never reboot the machine for other than Windows Updates, this amounted to 633 copies of VLC running in memory. Each process only used about 633k so it wasn’t an astronomical memory hog but multiply that by 633, you begin to feel the machine slowing down. Task Manager doesn’t let you kill multiple processes in bulk and I didn’t want to go through killing them one by one or rebooting.
The solution? Good old command line. Open up command prompt (start -> run -> cmd.exe). This snippet will kill all processes that start with the taskname:
TASKKILL /IM [TASKNAME]* /F
To kill all VLC processes, you’d use:
TASKKILL /IM vlc* /F
All running VLC processes will be terminated automatically.
Windows 7 sports tons of new features and surprises that have gotten little to no fanfare.
Did you know that Microsoft has updated the Windows Calculator with Windows 7 with some really new and useful features? Previously, most of these features often required you to open Excel or use some website to solve the problems they address. The calculator sports new features including Unit Conversion, Date Calculation, Mortgage, Vehicle Lease, Fuel Economy (in both MPG and KM no less!) You can find the different options under the View menu after opening the calculator up. See screenshots below for examples of what the calculator can do.
If youâ€™re a power user like me, youâ€™ll find Firefox will often balloon to about 1 gig of RAM usage after some time. Often times itâ€™ll hit that point and then just crash.
Iâ€™m probably in the minority but my surfing habits tend to be open a mess of tabs and then come back and read later. I never go back to bookmarks (even though I do have a delicious account and actually tag stuff). At any time, I may 25-100 tabs open in my browser.
Iâ€™ve had to install add-ons like session manager just to ensure I donâ€™t lose my tabs when working because Firefoxâ€™s built-in tools wouldnâ€™t restore my tab session when it crashed.
I recently stumbled upon Firefox Plumber (http://www.rizone3.com/2011/firefox-plumber/). Iâ€™ve been testing it for a few days now and I have to say Iâ€™m completely blown away by how well the utility works.
Currently I have 32 tabs open in Firefox. Under normal loads, the browser would utilize between 800MB-1GB of memory. With Firefox Plumber running, which is only utilizing about 708k in memory usage, Firefox is currently fluctuating between 4 and 7 MB of memory usage.
After some sleuthing, I found it accomplishes this by offloading the memory to the swap file which could present itâ€™s own issues. Iâ€™m going to stick with it for now since Firefox appears to be more stable and see how things work.