Friday, 7 December 2012

Let DropBox Cloudify your Singleplayer Minecraft game

A description replete with adverts of how to do this can be found on lifehacker here. It suggests installing a little tool which not everyone will have, so to do this on most any Windows workstation in Powershell just follow these steps in a powershell console while logged on in your desired Windows profile (minecraft saves game files per user.)
Run Powershell as an administrator (reuqired to create a symbolic link)

cd $env:appdata
cd .minecraft   # note the prceeding dot here on the foldername <-- span="span">
mkdir $env:userprofile\DropBox\Minecraft -force # Assuming your dropbox folder is still the default.
cmd /C "mklink /D $env:userprofile\DropBox\Minecraft\MySaves" $pwd
# running this in cmd is the easiest way to path to mklink from powershell that I know


symbolic link created for C:\Users\conradb\DropBox\Minecraft\MySaves <<===>> C:\Users\conradb\AppData\Roaming\.minecraft

Dropbox will start adding all your saves into the cloud, just watch your space consumption! Do this on each PC, and viola.

Thursday, 15 November 2012

Random Holiday destinations in Powershell

We can probably list all the recognised countries in the world by pulling out all of the timezone and internationalization data burned into Windows. To list all windows cultures

But we want to focus on just the country names, so lets move on to
[System.Globalization.Cultureinfo]::getcultures([System.Globalization.CultureTypes]::SpecificCultures)| ?{$_.englishname -eq "English (United Kingdom)"}|fl
Which produces this:
Parent                         : en
LCID                           : 2057
KeyboardLayoutId               : 2057
Name                           : en-GB
IetfLanguageTag                : en-GB
DisplayName                    : English (United Kingdom)
NativeName                     : English (United Kingdom)
EnglishName                    : English (United Kingdom)
TwoLetterISOLanguageName       : en
ThreeLetterISOLanguageName     : eng
ThreeLetterWindowsLanguageName : ENG
CompareInfo                    : CompareInfo - 2057
TextInfo                       : TextInfo - 2057
IsNeutralCulture               : False
CultureTypes                   : SpecificCultures, InstalledWin32Cultures, FrameworkCultures
NumberFormat                   : System.Globalization.NumberFormatInfo
DateTimeFormat                 : System.Globalization.DateTimeFormatInfo
Calendar                       : System.Globalization.GregorianCalendar
OptionalCalendars              : {System.Globalization.GregorianCalendar, System.Globalization.GregorianCalendar}
UseUserOverride                : True
IsReadOnly                     : False
And is clearly just a list of locales :-(
We want a political listing, this list has only got 210 locales.
OK, so that was fun, but did not produce the answer we wanted, so here is a possible solution if you do have an internet connection at the time you want the actual data.
It's a web-service, and the logical choice for live data. If you are paranoid like me, an interresting test-case is to validate a recently added country, such as 'South Sudan' named in July 2011. So now you are starting to squeek, help, I can't use web services in Powershell! Whoa!!!!  Nope, remember this is Powershell, and anything BASH can do, this can do also; so lets get moving.

Thursday, 11 October 2012

Good old MODE.EXE

This is another of those spot-the-error posts where I have had a console do somethng strange or even just funny artefacts I've uncovered.

Friday, 28 September 2012

15w x2 amplifier built

So far it does not have a case to go in, I have installed it in a biscuit tin. Which has been a good exercise since it has let me work out the dimensions better by practical layout of the parts in an enclosure. It's always hard to judge how much clearance for things will look neat inside a box, and how crowded the rear will look with all the connections.
I'm looking for this box or similar as a minimum size:

My biscuit tin is 230x230, and 80mm deep, which is too deep, but made it easy to set everything into the front and back by drilling and cutting with a craft-knife.

Although I just found this item on ebay, for a lot less, and it's the right color. Will have to think it over.