Sytone's Ramblings

The occasional posts of a guy who plays with technology.

Cleanup Empty Azure Resource Groups

2021-06-23 1 min read Azure
I needed to cleanup empty groups on a test subscription I had, using the Azure Cloud shell the following script will do it for you. az group list -o tsv --query [].name | % {$resources = az resource list -g $_ -o table; if($resources) {"$_ has Resources"} else {"$_ has no resources"; az group delete -n $_ -y --no-wait}}

Import multiple calendars to Obsidian with Power Automate

2021-06-23 1 min read Obsidian
I have a family calendar in iCloud and my personal one in Outlook. I want to have a easy way to see them in Obsidian. To enable this scenario I have used Power Automate and the Template plugin with some javascript to generate the calendar for every day and then allow it to be imported. This model could be used for anything else you may want to import into Obsidian with the bonus of it working on mobile as well. Continue reading

Running Home Assistant on Windows in Docker

2021-03-21 6 min read Home Automation
I wanted to move HA to my home server, I can run Hyper-V images as needed but most service I run these days are in Docker, so looked up how to do this for Home Assistant. Introduction This was originally taken from [Guide] Hass.IO on Windows 10 WSL2 (No more VMs!) and updated as needed for how I run it on Windows. Basically this is HASS.IO running on Docker in Windows 10 WSL2 Continue reading

PowerShell Cron Script

2021-01-22 3 min read General
I was looking for a way to schedule jobs and yes windows has a task scheduler built in, however I wanted a bit more flexibility and less complexity. On the unix platform you can use cron. It is a scheduler that uses a simple format to define the time when the process should start and the process command. I was going to look at using it when I thought about the parsing that would be needed, I dod not want a system that much that I would write a cron parser. Continue reading

Service Fabric skeleton service

2021-01-04 3 min read Development
Taken from to conserve and update as needed as could not find it when I went looking for it. On Service fabric, you can either create ASP.NET Core API service or worker process. I’m going to create a worker service today Visual Studio Template Skeleton Right click on ServiceFabric project > Create a new Service Fabric service Choose “Stateless Service” for worker service, as Stateful is the new evil in cloud era. Continue reading

Changing the commit author

2020-10-14 1 min read Development
So, you made some commits and then realise you used the wrong author and email address. No problem, use the following command to update them all and then you can push with consistent happiness. This assumes you are doing this in PowerShell, if in bash you may need to escape the quotes differently. The GIT commit id is the one before the commits with the wrong author. For the Author use the format name <email@address. Continue reading

Getting a PI to update when on a network

2020-08-27 3 min read Technology
Now we have a RV I wanted the pi to copy media files over when it is on the network. I have a share for our DVR where the media files are placed (HD Homerun + Emby) and wanted to copy certain TV shows over automatically when the RV is home and I put it on the network. Now I can go down the BASH scripting route but I do not know that space very well. Continue reading
Older posts Newer posts