OK, so ScriptingGames are started. First task looks pretty cool. I’m not very familiar with working on a registry keys using PowerShell, so it’s great opportunity to start using it also for reg-related tasks. First problem I went into is mkdir behaviour within this PRProvider.
On filesystem it’s not very hard to create even longest path, just type:
Everything (maybe except drive) might not be there, command will create full path. Not so in registry… So first thing I did was prepare something to check if given key exists and prepare all folders (keys) from top to bottom. I’m not sure if my way is the best, probably not. Has two main advantages: it works and it’s MINE! 😀
So let’s assume $RegistryPath does not exist. What should I do?
Well, no I know, use –Force parameter…. 😉 But I first tried harder way… 😀
Now what left is:
* take care about ACL (Yak! I’m admin, you see, I don’t really care! 😉 )
* extend error/ information handling