I’ve become a huge fan of Chocolatey. I historically have a Linux developer background and I got spoilt by
apt so it always had me upset that there was no unified way in Windows of installing and keeping track of various utilities a developer would find useful in day to day life.
I had some experience in Linux shell scripting in my past, but really got into it while building data cleansing scripts using tools like curl, grep and sed for an e-commerce startup I used work for. While I did recognize immediately how powerful mastery of Powershell would offer a Windows developer like myself, it was only in the last year or so I have had the opportunity for field work to hone this (and I am still, by no means, a master of this). I hope soon to have some deeper articles on Powershell, especially now that Powershell Core is maturing and makes it a contender for cross-platform scripting in a manner that may take on the likes of traditional shell scripting shells like
For now though, let’s start at the beginning of any developer’s journey: Getting your dev workstation setup. If you’re anywhere close to my use case, where I use a Mac but spin up new Windows VMs frequently to either isolate different clients’ VPN requirements or keep their streams of work separate, this can be a task in repetition.
Thankfully there’s a simple script I wrote, that eases this into one Powershell script. The initial code I sanitised for release is simple enough to paste in this article, but I plan to update it for more complex developer environment requirements, so you should clone my EasyDevWorkstation Github repository to get these updated scripts later on.
The following lines of script, taken from this repo, when run from an administror-mode Powershell prompt, will do the following:
- Set the Execution Policy of the system to
RemoteSigned to allow the installation of Chocolatey, and in turn allow Chocolatey scripts to install software
- Download and Install
- Install via Chocolatey the following
Git, because you need version control from the beginning
- Google Chrome browser, because we’re not all Edge and IE fans
- The latest available version of
Powershell (in case you are running an older OS like Windows Server 2008 R2, Chocolatey I think requires at least one version higher than the base install version)
- Visual Studio code, which has been growing in popularity (and extensions) to allow really simple to really powerful scenarios for coding solutions, and has good Git integration
- SQL Server Management Studio, because most common developer scenarios require connecting to SQL Server databases at some point.
Here’s the script:
iwr https://chocolatey.org/install.ps1 -UseBasicParsing | iex
choco install -y --allow-empty-checksums git GoogleChrome powershell visualstudiocode sql-server-management-studio
I love my Macbook Pro, but I’m a Windows developer by profession, so marrying the two worlds required I make use of tools like Parallels for Mac, which easily allows me to integrate Windows 10 into my Mac OSX experience thru Coherence mode. At a reasonable subscription cost, it’s the best option for independent developers like myself who don’t have an Enterprise budget.
However sometimes you want that full screen Windows experience to focus for a bit.
That’s when you realise Full screen mode Windows 10 using Parallels for Mac is an awesome feature. It almost makes me forget I’m on an Apple device. Until I’m ready to go back to OSX, and then I’m stuck. How do I exit this full screen mode if there’s no Apple window title button to click to exit?
The answer is simple, press
F to activate the shortcut key combination for both entering and exitting Full Screen mode with Parallels for Mac.
Thank Google and this reference article for the information 🙂
I’m setting up a new laptop for Office 365 administration and development work, and in doing so I realised sometimes I forgot the basics to getting Office 365 Powershell commands available once again. As a reminder they are:
- Install the Microsoft Online Services Sign-in Assistant for IT Professionals
- Install the Azure Administration MSI from the Azure Active Directory Connection page
- Run the “Azure Active Directory Module for Microsoft Powershell” and test that it all works with a
Get-MsolUser command after logging in to your Office 365 tenant with the
I purposely didn’t put any links here to the downloads, since its much more detailed and well written on the Microsoft TechNet article on Office 365 Powershell setup so I’d highly recommend reading that as your guide if you’re doing this for the first time.
I was reminded by our Accounting person that I needed to submit my laptop’s serial number for inventory. Thanks to my co-worker Ian, I learnt a new command today as his Googling fingers were faster than mine 🙂
wmic bios get serialnumber
will give you this information.
Referenced support article from Microsoft
Found this great article that reinforces my little hypothesis in learning to do more with PowerShell that having configurations for reusable scripts stored in JSON files might be a good habit to build.
This page was very useful for troubleshooting why Skype wouldn’t run straight off the website installation for OpenSuse. On Linux Skype is a 32-bit application, but my version of OpenSuse was 64-bit, so this page explains the steps needed to install the missing libraries that would allow a 32-bit Skype application to run.
The OpenSuse Community Restricted Multimedia Formats page was ultra useful today for getting my xvid-encoded videos playing smoothly on my OpenSuse installation. A nice extra surprise was that it smoothened the video on Flash playing within my browser. I was getting annoyed by jerky YouTube playbacks, and this ymp file for my Gnome environment seemed to fix this.
What should a developer know before building a public web site? – Stack Overflow.
In testing the new GigJunkie site before launching it (soon), I found my team debating to the point of near argument some of the finer points of our website which this topic thread would have helped us greatly, had we read before.
As I approach this weekend’s CAMDUG meetup which is an Open Space Coding Day with Alan Hemmings and other .Net Cambridge developers I’m very excited about working with folks on the topic of a public website for CAMDUG.
I’m hoping that my contributions to the day can be helped having read this article now. StackOverflow.com continues to impress me with its wealth of developer knowledge.
This tip on using the double-quotation marks in C# helped me a bit today when it came to integrating new code for an ASP.Net web application with legacy data access code that I was unsure about the quality of. The data access code that I was referencing may or may not have null value checking, and there was no time because of an impending deadline to do code-review or quality control revision on it, but by using the ‘??’ check on values returned by it and some constant parameter values hydrated by web.config appSetting values II was able to implement default behaviour in my code for objects which did not get what was expected from the data access layer.
Of course this is just a band aid. The solution really lies in cleaning up that misbehaving code and defining standard contracts for behaviour between tiers that all the software team agrees to and which consistent code reviewing will reveal deviations from at earlier stages before integration, and perhaps the whole team becomes better developers because of it since we’re discipling ourselves on good practices for writing quality code.