Parallels – Disable Adverts

So, you’ve forked out for Parallels – wise choice, its a great bit of software, but annoyingly, you get bombarded with adverts, bit annoying when they’ve already got your business, but there is a solution – and by entering the following into a Terminal window, the nuisance will end

 

defaults write com.parallels.Parallels\ Desktop ProductPromo.ForcePromoOff -bool YES

 

Enjoy your advert free Parallels experience

Remove Multiple ‘Open With’ Menu Items – Command Line

Command Line Network Configuration
So, I had this annoying situation the other day, when I CTRL Clicked on a file and chose Open With, I was presented with this menu

openwith

Multiple versions of Excel and Word to choose from, probably caused by software updates, anyway, I didn’t like this, it made the menu looked cluttered, so to remove it, you need to open Terminal and enter the following line of code

/System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/LaunchServices.framework/Versions/A/Support/lsregister -kill -r -domain local -domain system -domain user

It takes a few seconds to work, but afterwards you should end up with less cluttered menus

newopenwith

You may need to relaunch Finder, which is done by pressing CTRL, ALT and clicking on the Finder icon in the Dock, then click on relaunch

Creating never booted images – 10.8 – InstaDMG

System_Image_Utility

I’m going to run through the process of creating a never booted image using InstaDMG on Mac OS X 10.8, Once this has been done it will be ready to deploy using Deploystudio.

First, you will need to ensure that you have the Command Line Tools installed, you can download them from the Apple Developer site

You will need to create an account, but you don’t need to sign up for any of the paid programs to gain access to the tools we need

Go here to register

developer.apple.com/programs/register/

Once registered, click on the link below, this will take you to the downloads page, where you can get the Command Line Tools, we are after the Command Line Tools for OS X Mountain Lion

Command Line Tools (OS X Mountain Lion) for Xcode – January 2013

it’s roughly 120MB download, once you have it, install the package and we can get started.

First, open Terminal, then enter the following, this will change to your home directory, create an InstaDMG folder, then move you into the newly created folder

cd ; mkdir InstaDMG ; cd InstaDMG

next you will need to download InstaDMG, you do this by entering the following command into Terminal

svn checkout http://instadmg.googlecode.com/svn/trunk .

this shouldn’t take long, if you already have InstaDMG installed from a while ago, then it will be worth updating it, you can do this by entering the following into Terminal

cd ~/InstaDMG/
svn update

Next, you need to move your copy of the 10.8 InstallESD.dmg file into the InstaDMG installer disc folder

You need to have the Install Mac OS X Mountain Lion app in /Applications, if you don’t then you need to download it from the Mac App Store

When you have it, open Terminal and enter the following

sudo cp /Applications/Install\ OS\ X\ Mountain\ Lion.app/Contents/SharedSupport/InstallESD.dmg ~/InstaDMG/InstallerFiles/InstallerDiscs/

Next you need to make a change to the catalog file (10.8_vanilla.catalog) located at

~/InstaDMG/AddOns/InstaUp2Date/CatalogFiles

At the time of writing this points to an older Java installation file which will cause errors when trying to create the image, so we need to edit this, open Terminal and enter the following

nano ~/InstaDMG/AddOns/InstaUp2Date/CatalogFiles/10.8_vanilla.catalog

delete this line

Java for OS X 2012-006  http://support.apple.com/downloads/DL1572/en_US/JavaForOSX.dmg  sha1:eff777cdc39b4e3336b3477f60e8ad769ded8532

replace with this line

Java for OS X 2013-002 http://support.apple.com/downloads/DL1572/en_US/JavaForOSX2013-002.dmg sha1:47e38cf089a6a7bba9e2b0b387fe09e2b77e10a6

make sure there are tabs rather than spaces between each line, otherwise it will error when trying to build the image

then press CTRL X

then Y

then ENTER

this saves the file and you shouldn’t encounter any problems

next we need to make the image, which is all done in Terminal, so enter the following

cd ~/InstaDMG/AddOns/InstaUp2Date/

sudo ./instaUp2Date.py -p 10.8_vanilla

this took around 30 minutes on a 2012 MacBook Pro, times will vary on different models, but this should give you a rough idea

Managed Preferences – Cache Flush

wgm

The other day I was trying to access some restricted preferences on a 10.6 client, bound to a 10.6 Server that no longer existed, and because of this, I had no way of removing the restrictions

Or so I thought, thankfully Apple had provided a Knowledge Base article detailing how to manually flush the cache, enabling access to the previously restricted preferences.

To do this, I opened up Terminal and input the following command all on one line

dscl . -list Computers | grep -v "^localhost$" | while read computer_name ; 
do sudo dscl . -delete Computers/"$computer_name" ; done

This worked, I was able to amend the settings needed, I have provided the link to the Apple page below, in case you need information on how to do this on earlier OS’s

http://support.apple.com/kb/HT3540

Add a user to the Print Operator group

To add a non administrative user to the Print Operators group, you need to enter the following command into a Terminal window

sudo dseditgroup -o edit -u ADMINISTRATOR -p -a USER -t user _lpadmin

You will need to replace ADMINISTRATOR with the shortname of an admin account & you will need to replace USER with the shortname of the account you wish to add to the print operators group

when you hit enter then you will be prompted for your admin password, so enter that, but you will then be prompted “Please enter user password”, enter the password associated with the admin account mentioned in the command

To check if the user has been added to the Print Operators group then enter the following into a Terminal window

dscl . -read /Groups/_lpadmin GroupMembership