Thursday, July 21, 2016

Randomized Meal Planner

A few years ago I was home with my son several days a week, and I was in charge of most of our family's meals. I had developed a library of recipes that I turned to again and again--nothing fancy, but meals that I could make and our family enjoyed.

The only tedious part for me was coming up with a plan each week of what we were going to eat. I knew it was worth it to avoid the pain of asking "what's for dinner?" each night, but I couldn't bring myself to do the work.

The solution that I came up with is a combination of a Google Docs Spreadsheet and a script written in Google Apps Script to generate a random meal plan.

I entered in all of the meals that I liked to cook, how many times in a single month I was willing to eat that meal, how "hard" it was to cook, and the "category" of the meal so I avoided having pasta 2 nights in a row, for example. Going to a menu in the spreadsheet then picks from the meals that I have listed and creates a new sheet in the workbook, listing a month's worth of meals at a time.

The advantage of using Sheets and Google Apps Script is that it is easy to update all of the meals that I wanted randomized. The disadvantage is that Google seems to have abandoned Apps Script. It is not usable on mobile devices, for example. Some day I may move this concept to a mobile app, since nowadays I tend to do meal planning on my Android phone or on the iPad much more than on a laptop.

If you want to use this for your own meal planning, just click on the link to the meal planner document and save a copy of it to your Google Drive account.  There are instructions in the workbook itself.

Tuesday, July 19, 2016

Some Miscellaneous Powershell Scripts/snippets

I've just posted a few additional scripts that I've used over the years up on GitHub.

There are a few scripts that I use mostly in auditing AD.

I've also added some snippets that I've used to add AD photos (displayed in Outlook and Sharepoint), decommission user accounts, and create a group that has a diverse number of test users from various departments.

All of the scripts were written in Powershell and most rely on the AD cmdlets, so should work in Windows Server 2008 R2 or above.