<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><generator uri="https://jekyllrb.com/" version="3.8.7">Jekyll</generator><link href="http://powershell.one/feed.xml" rel="self" type="application/atom+xml" /><link href="http://powershell.one/" rel="alternate" type="text/html" hreflang="en" /><updated>2020-06-03T16:41:56+00:00</updated><id>http://powershell.one/feed.xml</id><title type="html">powershell.one</title><subtitle>A place for PowerShell Aficionados, professional Automation Experts, and the Home of ISESteroids.
</subtitle><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><entry><title type="html">Setting Registry Values (Smart)</title><link href="http://powershell.one/code/13.html" rel="alternate" type="text/html" title="Setting Registry Values (Smart)" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/code/13</id><content type="html" xml:base="http://powershell.one/code/13.html">&lt;p&gt;While preparing for our second day of our virtual &lt;em&gt;psconf.eu mini conference&lt;/em&gt;, my computer suddenly started to respond sluggishly, and when I investigated, I found that my &lt;em&gt;Chrome&lt;/em&gt; browser was causing excessive CPU loads. Specifically, a &lt;em&gt;softwarereporter&lt;/em&gt; tool caused the issue.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Join us for more &lt;strong&gt;PowerShell&lt;/strong&gt; deep dive in todays free virtual panel: see &lt;a href=&quot;http://powershell.love&quot;&gt;powershell.love&lt;/a&gt; for the details. If you missed it, go to &lt;a href=&quot;http://powershell.video&quot;&gt;powershell.video&lt;/a&gt; for the recordings.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Turned out that’s a tool Google uses to regularly scan the computer for unwanted software that may negatively affect &lt;em&gt;Chromes&lt;/em&gt; performance. Only that this tool degraded the performance of my entire machine.&lt;/p&gt;

&lt;p&gt;This post is not about shutting down &lt;em&gt;softwarereporter&lt;/em&gt; which was trivial by setting a bunch of registry values. It is about &lt;em&gt;setting a bunch of registry values&lt;/em&gt; itself.&lt;/p&gt;

&lt;h2 id=&quot;setting-many-registry-values-at-once&quot;&gt;Setting Many Registry Values At Once&lt;/h2&gt;

&lt;p&gt;You can use &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt; to set individual registry keys:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# setting a dummy registry value (key must exist)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Set-ItemProperty&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'HKCU:\Software'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Hello&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Value&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'I was here!'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Type&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;String&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;blockquote&gt;
  &lt;p&gt;The parameter &lt;strong&gt;-Type&lt;/strong&gt; is not &lt;em&gt;undocumented&lt;/em&gt; as is often claimed. It is a &lt;em&gt;dynamic&lt;/em&gt; parameter that shows only when the value you submitted to &lt;strong&gt;-Path&lt;/strong&gt; makes it necessary. That’s why &lt;strong&gt;-Type&lt;/strong&gt; often is missing from IntelliSense: if you are submitting a variable to &lt;strong&gt;-Path&lt;/strong&gt;, then the parser can’t figure out whether &lt;strong&gt;-Type&lt;/strong&gt; should be added.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Yet when you need to set more than one, your script code starts to look ugly. So why not set them all with just one call to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt;?&lt;/p&gt;

&lt;h3 id=&quot;pipeline-to-the-rescue&quot;&gt;Pipeline To The Rescue&lt;/h3&gt;

&lt;p&gt;Unfortunately, the cmdlet does not accept arrays so you can’t submit more than one registry value name.&lt;/p&gt;

&lt;p&gt;But all three parameters accept pipeline data by property name, so when you pipe objects into &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt; that have the properties &lt;em&gt;Name&lt;/em&gt;, &lt;em&gt;Value&lt;/em&gt;, and &lt;em&gt;Type&lt;/em&gt;, you can create as many registry values as you like with just one call.&lt;/p&gt;

&lt;p&gt;Creating these input objects is simple. Here are the three values I need to turn off &lt;em&gt;Chromes&lt;/em&gt; software reporting tool:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;s1&quot;&gt;'Name,Value,Type
ChromeCleanupEnabled,0,DWORD
ChromeCleanupReportingEnabled,0,DWORD
MetricsReportingEnabled,0,DWORD'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertFrom-Csv&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The result are three objects with the required properties:&lt;/p&gt;

&lt;div class=&quot;language-plaintext highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;Name                          Value Type 
----                          ----- ---- 
ChromeCleanupEnabled          0     DWORD
ChromeCleanupReportingEnabled 0     DWORD
MetricsReportingEnabled       0     DWORD
&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h3 id=&quot;pipeline-binding-conflict&quot;&gt;Pipeline Binding Conflict&lt;/h3&gt;

&lt;p&gt;Unfortunately, you can’t pipe these objects to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt; even though the parameters accept binding by property name: here is my first attempt, and it emits tons of exceptions and creates weird values:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;#requires -RunAsAdmin&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure you run this with ADMIN privileges because it writes to HKLM&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# CODE BELOW FAILS! READ ON FOR THE SOLUTION...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# https://powershell.one/code/13.html&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# this is where the Chrome policies are located:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'HKLM:\SOFTWARE\Policies\Google\Chrome'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure the key exists:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$null&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;New-Item&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Force&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# write the registry values:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'Name,Value,Type
ChromeCleanupEnabled,0,DWORD
ChromeCleanupReportingEnabled,0,DWORD
MetricsReportingEnabled,0,DWORD'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
  &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertFrom-Csv&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
  &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Set-ItemProperty&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The key was created, but inside I found a value called “Value”, and &lt;strong&gt;PowerShell&lt;/strong&gt; complained that &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt; was unable to convert the piped input data into the proper data types.&lt;/p&gt;

&lt;p&gt;The reason for this was a pipeline binding conflict:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;&lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Set-ItemProperty&lt;/code&gt; has a parameter &lt;strong&gt;-InputObject&lt;/strong&gt; that accepts any object by value.&lt;/li&gt;
  &lt;li&gt;So my own custom objects were not bound to the parameters &lt;strong&gt;-Name&lt;/strong&gt;, &lt;strong&gt;-Value&lt;/strong&gt;, and &lt;strong&gt;-Type&lt;/strong&gt;, and instead &lt;strong&gt;PowerShell&lt;/strong&gt; assigned them as object to &lt;strong&gt;-InputObject&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Which left me confused: why would a cmdlet have parameters that accept pipeline data by property name when at the same time another parameter would always grab all pipeline input and bind it to itself?&lt;/p&gt;

&lt;h2 id=&quot;do-it-right-setting-multiple-registry-values&quot;&gt;Do it right: Setting Multiple Registry Values&lt;/h2&gt;

&lt;p&gt;In conflicts like the one above, there is a simple trick how you can &lt;em&gt;force&lt;/em&gt; &lt;strong&gt;PowerShell&lt;/strong&gt; to bind to a parameter by property name, so this is the working example that sets the &lt;em&gt;Chrome&lt;/em&gt; policy keys, prevents the software reporter tool and high CPU loads, and is an excellent template for whenever you need to set multiple registry values:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;#requires -RunAsAdmin&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure you run this with ADMIN privileges because it writes to HKLM&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# this is where the Chrome policies are located:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'HKLM:\SOFTWARE\Policies\Google\Chrome'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure the key exists:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$null&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;New-Item&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Force&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# write the registry values:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'Name,Value,Type
ChromeCleanupEnabled,0,DWORD
ChromeCleanupReportingEnabled,0,DWORD
MetricsReportingEnabled,0,DWORD'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
  &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertFrom-Csv&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
  &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Set-ItemProperty&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$key&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Note how I just added this: &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;-Name { $_.Name }&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Whenever a parameter accepts pipeline data by property name, it also &lt;em&gt;automatically&lt;/em&gt; accepts a scriptblock, and &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;$_&lt;/code&gt; inside of this scriptblock represents the incoming pipeline object.&lt;/p&gt;

&lt;p&gt;This technique was originally designed to let you quickly do adjustments to piped data. For example, if you pipe an excel sheet into a cmdlet that requires a securestring password, you could do something like this:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# illustrates how a parameter can receive a plain text pipeline input&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# via binding by property name, and YOU get still a chance to convert it&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# to something else i.e. a secure string before the actual binding&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# takes place:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertTo-SecureString&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-AsPlainText&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Force&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;In my case, by explicitly using the parameter &lt;strong&gt;-Name&lt;/strong&gt;, I made sure &lt;strong&gt;PowerShell&lt;/strong&gt; knew which parameterset I wanted to use, and happily bound the input object to the remaining parameters &lt;strong&gt;-Value&lt;/strong&gt; and &lt;strong&gt;-Type&lt;/strong&gt;. Amazing stuff.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name></author><category term="Trick" /><category term="Registry" /><category term="Set" /><category term="Value" /><category term="Set-ItemProperty" /><summary type="html">My Chrome browser was causing high CPU load. By setting a bunch of registry values, that was easy to fix - thanks to a clever PowerShell hack.</summary></entry><entry><title type="html">Auto-Learning Auto-Completion</title><link href="http://powershell.one/code/14.html" rel="alternate" type="text/html" title="Auto-Learning Auto-Completion" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/code/14</id><content type="html" xml:base="http://powershell.one/code/14.html">&lt;p&gt;Autocompletion is awesome and makes using &lt;strong&gt;PowerShell&lt;/strong&gt; so much easier. Typically, though, the autocompletion data is provided by the engine or your function. That’s why autocompletion is available predominantly for &lt;em&gt;technical&lt;/em&gt; things such as paths, types, or prefixed lists and enumerations.&lt;/p&gt;

&lt;p&gt;They are typically &lt;em&gt;not&lt;/em&gt; able to adapt to the needs of &lt;em&gt;users&lt;/em&gt;, i.e. suggest computer names in use in your infrastructure. And you as a &lt;strong&gt;PowerShell&lt;/strong&gt; author can’t help this because you don’t know the suggestions that would be useful for a &lt;em&gt;user&lt;/em&gt; of your function.&lt;/p&gt;

&lt;p&gt;Let’s change that.&lt;/p&gt;

&lt;h2 id=&quot;add-auto-learning-auto-completion&quot;&gt;Add Auto-Learning Auto-Completion&lt;/h2&gt;

&lt;p&gt;With the magic of &lt;a href=&quot;https://powershell.one/powershell-internals/attributes/custom-attributes&quot;&gt;transformation attributes&lt;/a&gt;, you can effortlessly add auto-learning auto-completion to the parameters of your functions that a &lt;em&gt;user&lt;/em&gt; trains.&lt;/p&gt;

&lt;p&gt;Run this to see for yourself:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;For the most part, this script is defining the new attributes that you can later reuse throughout your functions. So when you collapse the region at the beginning, you’ll see that there is just very little code to digest.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region adding the new attributes&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;class&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;AutoLearnAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;System&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Management&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Automation&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;ArgumentTransformationAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define path to store hint lists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$&lt;/span&gt;&lt;span class=&quot;nn&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;temp&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;\hints&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define id to manage multiple hint lists:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'default'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define prefix character used to delete the hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;char&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ClearKey&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'!'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define parameterless constructor:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AutoLearnAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define constructor with parameter for id:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AutoLearnAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# Transform() is called whenever there is a variable or parameter assignment, and returns the value&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# that is actually assigned:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;object&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Transform&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Management.Automation.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;EngineIntrinsics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$engineIntrinsics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;object&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure the folder with hints exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$null&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;New-Item&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ItemType&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Directory&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# create filename for hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'{0}.hint'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-f&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Join-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ChildPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# use a hashtable to keep hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;@{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# read hint list if it exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-Content&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Encoding&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Default&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# remove leading and trailing blanks&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ForEach-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Trim&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# remove empty lines&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Where-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;IsNullOrEmpty&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# add to hashtable&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ForEach-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# value is not used, set it to $true:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$true&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# does the user input start with the clearing key?&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Data.StartsWith&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ClearKey&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# remove the prefix:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Data.SubString&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# clear the hint list:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Clear&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# add new value to hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;IsNullOrWhiteSpace&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$true&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# save hints list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Keys&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Sort-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Set-Content&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Encoding&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Default&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
        
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# return the user input (if there was a clearing key at its start,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# it is now stripped):&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;class&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;System&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Management&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Automation&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;ArgumentCompleterAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define path to store hint lists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$&lt;/span&gt;&lt;span class=&quot;nn&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;temp&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;\hints&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define id to manage multiple hint lists:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'default'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define parameterless constructor:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# define constructor with parameter for id:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# create a static helper method that creates the scriptblock that the base constructor needs&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# this is necessary to be able to access the argument(s) submitted to the constructor&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# the method needs a reference to the object instance to (later) access its optional parameters:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;hidden&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;static&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;ScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoCompleteAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$scriptblock&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# receive information about current state:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$commandName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$parameterName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$wordToComplete&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$commandAst&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fakeBoundParameters&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
   
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# create filename for hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'{0}.hint'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-f&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Join-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ChildPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# use a hashtable to keep hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;@{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# read hint list if it exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-Content&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Encoding&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Default&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# remove leading and trailing blanks&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ForEach-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Trim&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# remove empty lines&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Where-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;IsNullOrEmpty&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# filter completion items based on existing text:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Where-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;LogName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-like&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$wordToComplete&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;*&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# create argument completion results&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Foreach-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
                  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Management.Automation.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CompletionResult&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'ParameterValue'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;GetNewClosure&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$scriptblock&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region CacheCredential&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# attribute [CacheCredential()] transforms strings to creds and caches values:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;class&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;CacheCredentialAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;System&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Management&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;Automation&lt;/span&gt;&lt;span class=&quot;err&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nc&quot;&gt;ArgumentTransformationAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$&lt;/span&gt;&lt;span class=&quot;nn&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;temp&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;\hints&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'default'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;char&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ClearKey&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'!'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;CacheCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;CacheCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;object&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Transform&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Management.Automation.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;EngineIntrinsics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$engineIntrinsics&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;object&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# make sure the folder with hints exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$null&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;New-Item&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ItemType&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Directory&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# create filename for hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'{0}.xmlhint'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-f&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Join-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ChildPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# use a hashtable to keep hint list&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;@{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# read hint list if it exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Test-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# hint list is xml data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# it is a serialized hashtable and can be &lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# deserialized via Import-CliXml if it exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# result is a hashtable:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Collections.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Hashtable&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Import-Clixml&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# if the argument is a string...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-is&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;])&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# does username start with &quot;!&quot;?&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;bool&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$promptAlways&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Data.StartsWith&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ClearKey&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# if not,...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;!&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$promptAlways&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# ...check to see if the username has been used before,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# and re-use its credential (no need to enter password again)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ContainsKey&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                    &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;else&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# ...else, remove the &quot;!&quot; at the beginning and prompt&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# again for the password (this way, passwords can be updated)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Data.SubString&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;mi&quot;&gt;1&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# delete the cached credentials&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
                &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Clear&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# ask for a credential:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cred&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$engineIntrinsics&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Host&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;UI&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;PromptForCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Enter password&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Please enter user account and password&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# add the credential to the hashtable:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cred&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;UserName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cred&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# update the hashtable and write it to file&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# passwords are automatically safely encrypted:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Export&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Clixml&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# return the credential:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cred&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# if a credential was submitted...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;elseif&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-is&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;PSCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;])&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# save it to the hashtable:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Data.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;UserName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# update the hashtable and write it to file:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Export&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Clixml&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# return the credential:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$input&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Data&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;throw&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;InvalidOperationException&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'Unexpected error.'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;


&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# attribute [SuggestCredential()] suggests cached credentials&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;class&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Management.Automation.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;ArgumentCompleterAttribute&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$&lt;/span&gt;&lt;span class=&quot;nn&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;temp&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;\hints&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'default'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  
    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;base&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;))&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$this&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;hidden&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;static&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;ScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;_createScriptBlock&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;([&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredentialAttribute&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$scriptblock&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$commandName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$parameterName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$wordToComplete&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$commandAst&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fakeBoundParameters&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
   
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'{0}.xmlhint'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-f&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Join&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$instance&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-ChildPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$filename&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Test&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$exists&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# read serialized hint hashtable if it exists...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Collections.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Hashtable&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Import&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Clixml&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Path&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hintPath&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

            &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# hint the sorted list of cached user names...&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
            &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$hints&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Keys&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Where&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# ...that still match the current user input:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Where&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;LogName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;-like&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$wordToComplete&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;*&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
              &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Sort&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;|&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# return completion results:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Foreach&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Object&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; 
                  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Management.Automation.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CompletionResult&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;new&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'ParameterValue'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;bp&quot;&gt;$_&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
              &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;GetNewClosure&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;return&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$scriptblock&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;


&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# function uses a parameter -Credential that accepts both&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# strings (username) and credentials. If the user submits a&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# string, a cached credential is returned if available.&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# only if there is no cached credential yet, the user gets&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# prompted for a password, and the string is transformed&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# into a credential.&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# when the user prefixes a username with &quot;!&quot;, all cached&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# credentials are deleted´.&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# see: https://powershell.one/powershell-internals/attributes/custom-attributes&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;function&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Connect&lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-MyServer&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Parameter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Mandatory&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoLearn&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoComplete&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ComputerName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;PSCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CacheCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# expose password:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;GetNetworkCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$username&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;UserName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;hello &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Username&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;, connecting you to &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ComputerName&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt; using password &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$password&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;.&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;The code important for &lt;em&gt;you&lt;/em&gt; is just this part:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# make sure you ran the code above to define the new attributes!&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;function&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Connect-MyServer&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Parameter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Mandatory&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoLearn&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoComplete&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ComputerName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;PSCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CacheCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# expose password:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;if&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;GetNetworkCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;()&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Password&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
      &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$username&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;UserName&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

    &lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;hello &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Username&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;, connecting you to &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ComputerName&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt; using password &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$password&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;.&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;}&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;Once you run the code, you have one function &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Connect-MyServer&lt;/code&gt; which has two parameters: &lt;strong&gt;-ComputerName&lt;/strong&gt; and &lt;strong&gt;-Credential&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Run &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Connect-MyServer&lt;/code&gt;a couple of times, and you’ll notice that autocompletion &lt;em&gt;learns&lt;/em&gt; from you.&lt;/p&gt;

&lt;p&gt;It will suggest computer names and credentials that you entered previously. So this is a perfect user-centric scenario where you and your functions just provide the &lt;em&gt;ability&lt;/em&gt; for the user to teach the computer names and credentials to &lt;em&gt;your&lt;/em&gt; function over time.&lt;/p&gt;

&lt;p&gt;Due to a bug in all &lt;strong&gt;PowerShell&lt;/strong&gt; versions, autocompletion will generally &lt;em&gt;never&lt;/em&gt; work inside the very same editor pane where you defined the attributes. It works like a charm in any other editor window, and of course in the interactive &lt;strong&gt;PowerShell&lt;/strong&gt; console.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;The cache is persistent and works across restarts. Credentials are stored encrypted. To clear the cache list, prepend the argument with “!”.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;how-this-works&quot;&gt;How this works&lt;/h3&gt;

&lt;p&gt;There is just a minor change to the &lt;strong&gt;param()&lt;/strong&gt; block to enable this for &lt;em&gt;any&lt;/em&gt; &lt;strong&gt;PowerShell&lt;/strong&gt; function or script:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;kr&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;string&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Parameter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Mandatory&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoLearn&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;AutoComplete&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'server'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ComputerName&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;PSCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CacheCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)][&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;SuggestCredential&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'account'&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
        &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$Credential&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
    &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;p&gt;For string-based parameters, use the new attributes &lt;em&gt;[AutoLearn()]&lt;/em&gt; and &lt;em&gt;[AutoComplete()]&lt;/em&gt;, and submit a keyword. The keyword basically defines the cache list, and if you want parameters to share the same cache list, use the same keyword.&lt;/p&gt;

&lt;p&gt;For credential-based parameters, use the new attributes &lt;em&gt;[CacheCredential()]&lt;/em&gt; and &lt;em&gt;[SuggestCredential()]&lt;/em&gt;, and again submit a keyword. Like before, you should use the same keyword for the same credential cache list.&lt;/p&gt;

&lt;h3 id=&quot;further-reading&quot;&gt;Further Reading&lt;/h3&gt;

&lt;p&gt;This article is just a short version of &lt;a href=&quot;https://powershell.one/powershell-internals/attributes/custom-attributes&quot;&gt;this&lt;/a&gt; way more elaborate background article. It is basically a proof-of-concept up for grabs, and there are a lot of things you might want to add.&lt;/p&gt;

&lt;p&gt;For example, you might want to polish attribute naming. You could hook up the credentials cache to some secret vault or credentials manager instead of saving the values to an encrypted xml file (as it is done right now).&lt;/p&gt;

&lt;h2 id=&quot;wish-list-for-the-powershell-team&quot;&gt;Wish List for the PowerShell Team&lt;/h2&gt;

&lt;p&gt;I believe this approach is so useful and adds so much advantage to the usability of any &lt;strong&gt;PowerShell&lt;/strong&gt; function or script that my hope is that these attributes might be added to &lt;strong&gt;PowerShell&lt;/strong&gt; natively at one time.&lt;/p&gt;

&lt;p&gt;Currently, because of how the &lt;strong&gt;PowerShell&lt;/strong&gt; engine works, there is the requirement for &lt;em&gt;two&lt;/em&gt; attributes, one dealing with autocompletion and another dealing with caching. That is something only the &lt;strong&gt;PowerShell&lt;/strong&gt; engine can fix and consolidate into &lt;em&gt;one&lt;/em&gt; simple attribute.&lt;/p&gt;

&lt;p&gt;Another challenge currently is that &lt;strong&gt;PowerShell&lt;/strong&gt; modules do not support classes, so you cannot add the attribute definitions to modules. That, too, would be overcome when &lt;strong&gt;PowerShell&lt;/strong&gt; shipped these attributes out of the box. Let’s keep fingers crossed!&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name></author><category term="Trick" /><category term="AutoCompletion" /><category term="Attribute" /><category term="TransformationAttribute" /><summary type="html">Increase usability for your PowerShell functions by adding automatic parameter completion that learns from the user.</summary></entry><entry><title type="html">PowerShell IoT (and GUIs, too)</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/iot" rel="alternate" type="text/html" title="PowerShell IoT (and GUIs, too)" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/IoT</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/iot">&lt;p&gt;This is our &lt;em&gt;all-purpose&lt;/em&gt; section where we combine topics like &lt;em&gt;IoT&lt;/em&gt;,  the brand-new notebooks (see below if you think I am talking about laptops), and GUI creation.&lt;/p&gt;

&lt;p&gt;Only, there are no GUI sessions available. Originally, we planned to have them as well, illustrating how you can create user interfaces from &lt;strong&gt;PowerShell&lt;/strong&gt;. Even though &lt;strong&gt;PowerShells&lt;/strong&gt; intention originally was to do away with user interfaces and automate, it became so successful that it today is a valid rapid development architecture for small tools and software, so GUI creation always has caught a lot of attention. Due to Corona, we were unable to record &lt;em&gt;all&lt;/em&gt; sessions, and so some sessions from Adam Driscoll about his awesom &lt;em&gt;Digital Dashboard&lt;/em&gt; are missing.&lt;/p&gt;

&lt;p&gt;Nevertheless, we will include GUI into our live panel, and if you have questions about IoT or GUI, please meet us:&lt;/p&gt;

&lt;p&gt;We cordially invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting &lt;strong&gt;PowerShell&lt;/strong&gt; IoT, Notebooks, GUI. It is taking place &lt;strong&gt;June 3, 2020&lt;/strong&gt; at &lt;strong&gt;8pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other security experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;powershell-iot-v2---whats-new-what-changed-and-what-ive-learned&quot;&gt;PowerShell IoT v2 - What’s new, what changed and what I’ve learned&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Daniel Silva&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/RLivWxWKBco&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;&lt;strong&gt;PowerShell.IoT&lt;/strong&gt; is a free, Open Source module that allows you to interact with IoT hardware.&lt;/p&gt;

&lt;p&gt;Since I’ve become a maintainer of this repo, I’ve been working to migrate the code to use &lt;strong&gt;System.Devices&lt;/strong&gt; from the dotnet team.&lt;/p&gt;

&lt;p&gt;In this session, I will share with you what has changed, what’s new, and what I’ve learned since I’ve started to contribute to Open Source software, and also why you should too!&lt;/p&gt;

&lt;h3 id=&quot;powershell-on-raspberry-pi---making-a-connected-greenhouse&quot;&gt;PowerShell on Raspberry PI - Making a connected greenhouse&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Jakob Gottlieb&lt;/a&gt;  from the &lt;strong&gt;PowerShell&lt;/strong&gt; team&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/lcQaMyA9yyI&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;After the success at Ignite 2019, on popular demand, here comes the deep dive on how to run and use PowerShell on Raspberry PI.&lt;/p&gt;

&lt;p&gt;Join me as I tell the story about how I connected my backyard greenhouse to azure. Besides metrics, this includes automated watering and much more.&lt;/p&gt;

&lt;p&gt;We will dive into configuring and running PowerShell on Raspberry PI, for newcomers, but also including more advanced tips and tricks for the experienced PoshPI’er.&lt;/p&gt;

&lt;p&gt;You will learn how Azure is a great platform for IoT projects like this. We’ll be touching multiple services such as Log Analytics and Azure Functions combined with simple code in PowerShell.&lt;/p&gt;

&lt;p&gt;And What about Docker?! who would use that in their 4m2 greenhouse?! Me!, I mean, Who wants to configure IoT Devices by hand?!&lt;/p&gt;

&lt;h3 id=&quot;powershell-in-notebooks&quot;&gt;PowerShell in Notebooks&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Rob Sewell&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/gOxvS4ScceE&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;

&lt;p&gt;&lt;strong&gt;Jupyter Notebooks&lt;/strong&gt; are best known as tools for Data Scientists to display Python, Spark or R scripts.&lt;/p&gt;

&lt;p&gt;Azure Data Studio is a data professional tool based on Visual Studio Code. Azure Data Studio includes PowerShell Notebooks in addition to SQL notebooks.&lt;/p&gt;

&lt;p&gt;A notebook enables you to share words, images, code AND code results and will be extremely useful in many scenarios. I am already using it with clients for Incident Resolution Repeatable tasks Demoing new features.&lt;/p&gt;

&lt;p&gt;In this session, we will examine PowerShell Notebooks and show you how useful they could be for you in your daily work-life&lt;/p&gt;

&lt;h3 id=&quot;notebooks--vs-code&quot;&gt;Notebooks + VS Code&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Sydney Smith&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/G428GfBJprM&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;

&lt;p&gt;&lt;em&gt;Visual Studio Code&lt;/em&gt; has been called the recommended editor for PowerShell 7.&lt;/p&gt;

&lt;p&gt;Learn how to get started with VSCode using features like “ISE mode”, and then how to build your skill set to take advantage of Visual Studio Code’s rich feature set.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Jupyter notebooks&lt;/strong&gt; allow you combine rich text elements with executable code. Learn how to get started building, and sharing PowerShell notebooks to take your documentation, and support to the next level!&lt;/p&gt;

&lt;p&gt;&lt;em&gt;VSCode&lt;/em&gt; and Jupyter notebooks are two tools that the PowerShell team has recently been investing in. Learn why we these tools are so valuable and, how to get started developing with them.&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><category term="GUI" /><category term="IoT" /><category term="Notebooks" /><category term="Yupyter" /><summary type="html">Ever wanted to control hardware and robots? Interested in Yupyter Notebooks? Want to Create GUIs?</summary></entry><entry><title type="html">Pester and ScriptAnalyzer</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/pester" rel="alternate" type="text/html" title="Pester and ScriptAnalyzer" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/Pester</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/pester">&lt;p&gt;We are proud to present to you this years’ &lt;strong&gt;psconf.eu&lt;/strong&gt; sessions related to &lt;em&gt;Pester&lt;/em&gt; and &lt;strong&gt;PowerShell ScriptAnalyzer&lt;/strong&gt;. And of course we are happy to see that &lt;em&gt;Pester&lt;/em&gt;-inventor &lt;em&gt;Jakub&lt;/em&gt; is delivering a talk - there can’t be a more authoritative coverage, and you can ask him all your questions in our live panel.&lt;/p&gt;

&lt;p&gt;We invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting Pester and ScriptAnalyzer. It is taking place &lt;strong&gt;June 2, 2020&lt;/strong&gt; at &lt;strong&gt;8pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other &lt;strong&gt;PowerShell&lt;/strong&gt; experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;building-powershell-its-vs-code-extension-and-debugging-it&quot;&gt;Building PowerShell, its VS-Code extension and debugging it&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Christoph Bergmeister&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/NJixozClEbU&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;We all use PowerShell, it’s VS-Code extension or &lt;em&gt;PSScriptAnalyzer&lt;/em&gt; in some way or another. Sometimes we’d like to either add a feature or have a customized version of it for some reason or need to debug a bug in those tools.&lt;/p&gt;

&lt;p&gt;I will show how to build and debug those tools. Furthermore I will show features that I have made in various areas to the tools in the past and demo some small examples.&lt;/p&gt;

&lt;h3 id=&quot;whats-new-in-pester-v5&quot;&gt;What’s new in Pester v5?&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Jakub Jareš&lt;/a&gt; from Finnland&lt;/p&gt;

&lt;iframe width=&quot;560&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/xC8SfYHQ_i4&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;

&lt;p&gt;&lt;em&gt;Pester 5&lt;/em&gt; brings multiple new features, many fixes and also some significant breaking changes.&lt;/p&gt;

&lt;p&gt;In this talk I will demo the most significant improvements to the framework, point out differences from version 4 and give a quick guide to migrating to the new framework version.&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><category term="Pester" /><category term="ScriptAnalyzer" /><summary type="html">Watch our sessions related to Pester and PowerShell ScriptAnalyzer, and meet us in our live Q&amp;A!</summary></entry><entry><title type="html">PowerShell 7</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/powershell-7" rel="alternate" type="text/html" title="PowerShell 7" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/PowerShell-7</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/powershell-7">&lt;p&gt;We are proud to present to you this years’ &lt;strong&gt;psconf.eu&lt;/strong&gt; sessions related to &lt;strong&gt;PowerShell 7&lt;/strong&gt;, future paths, guidance to &lt;strong&gt;PowerShell&lt;/strong&gt;, and anything related. For other topics, please see the other pages on &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/about&quot;&gt;powershell.one&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;We also invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting these topics. It is taking place &lt;strong&gt;June 3, 2020&lt;/strong&gt; at &lt;strong&gt;5pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other security experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;powershell-71-a-next-gen-shell&quot;&gt;PowerShell 7.1: A Next Gen Shell&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Steve Lee &amp;amp; Jason Helmick&lt;/a&gt; from the &lt;strong&gt;PowerShell&lt;/strong&gt; team.&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/yhr-1KOZvFo&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Modern shells should help you be successful as soon as you start typing. Tab completion and IntelliSense are just the beginning.&lt;/p&gt;

&lt;p&gt;In this session, Steve Lee and Jason Helmick discuss some of the new shell improvements in 7.0 and the exciting plans we have in store for making 7.1 the most productive shell ever!&lt;/p&gt;

&lt;p&gt;Join us to discuss the future of the shell.&lt;/p&gt;

&lt;h3 id=&quot;powershellget-30&quot;&gt;PowerShellGet 3.0&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Sydney Smith&lt;/a&gt; from the &lt;strong&gt;PowerShell&lt;/strong&gt; team.&lt;/p&gt;

&lt;iframe width=&quot;560&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/YI9Lw1NOxgU&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;The PowerShell team has done a complete re-architecture of the &lt;strong&gt;PowerShellGet&lt;/strong&gt; module.&lt;/p&gt;

&lt;p&gt;We will explain what changes this will mean for your user experience, and demo some of the latest features.&lt;/p&gt;

&lt;h3 id=&quot;the-seven-deadly-sins-of-powershell&quot;&gt;The Seven Deadly Sins of PowerShell&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Friedrich Weinmann&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/a7_YFviCOg0&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Father forgive me, for I have sinned. Life is a sinful thing, and we all commit the odd bad deed in our lives.&lt;/p&gt;

&lt;p&gt;But there are a few unforgivable sins out there. Foul deeds that no penance can excuse. You know what I am talking about: &lt;em&gt;The Seven Deadly Sins … of PowerShell!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Introducing the greatest sins you can commit in PowerShell, WHY they are bad, why people commit them and good ways to meet the same ends without loading up immense technical debt.&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><category term="PowerShell 7" /><summary type="html">Watch our sessions related to PowerShell 7, PowerShellGet, future paths, and general guidance, and meet us in our live Q&amp;A!</summary></entry><entry><title type="html">PowerShell Deep Shit</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/powershell-deep-shit" rel="alternate" type="text/html" title="PowerShell Deep Shit" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/PowerShell-Deep-Shit</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/powershell-deep-shit">&lt;p&gt;&lt;strong&gt;psconf.eu&lt;/strong&gt; originally is a place for &lt;strong&gt;PowerShell&lt;/strong&gt; experts and professionals to come together and brainstorm about new things, edge cases, secrets, and un(der)documented features - so no wonder we have rich content in this discipline!&lt;/p&gt;

&lt;p&gt;What’s even better: you can meet all the speakers and experts live in our Q&amp;amp;A to ask all the long standing questions you never really found good answers for.&lt;/p&gt;

&lt;p&gt;If you’d like to look at different topics and maybe are more interested in security or basic questions, please see the other videos and pages on &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/about&quot;&gt;powershell.one&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;We cordially invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting &lt;strong&gt;PowerShell&lt;/strong&gt; deep shit topics. It is taking place &lt;strong&gt;June 3, 2020&lt;/strong&gt; at &lt;strong&gt;7pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other security experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;querying-wikidata-with-a-glimpse-of-sparql&quot;&gt;Querying Wikidata with a glimpse of SPARQL&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Thorsten Butz&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/b7erBmbaVR4&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Wikidata represents the underlying basement of Wikipedia, it’s the collaboratively edited knowledge base filling up Wikipedia with data.&lt;/p&gt;

&lt;p&gt;Querying Wikidata enables you to gain access to to a universe of information, just in case you know how to answer the right questions.&lt;/p&gt;

&lt;p&gt;This session provides an insight to wikidata/wikimedia queries by SPARQL, the semantic query language from W3C.&lt;/p&gt;

&lt;h3 id=&quot;module-system-deep-dive&quot;&gt;Module System Deep-Dive&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Rob Holt&lt;/a&gt;  from the &lt;strong&gt;PowerShell&lt;/strong&gt; team&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/jWXe-xnpLsI&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;The &lt;strong&gt;PowerShell&lt;/strong&gt; module system, whereby commands are portioned into convenient collections of functionality, is a twisted beast that has to make functionality separable but still convenient and accessible from the command line (a problem that module systems in other languages don’t have).&lt;/p&gt;

&lt;p&gt;In this talk, we take a deep look at what actually happens when you run cmdlets like &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Import-Module&lt;/code&gt; and &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Get-Module&lt;/code&gt;, how commands are resolved from modules, how module manifests work compared to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Export-ModuleMember&lt;/code&gt;, and some of the quirks and edge cases that occur because of the complexities of modules in PowerShell.&lt;/p&gt;

&lt;h3 id=&quot;classes--runspaces-together---async-logging-in-powershell&quot;&gt;Classes &amp;amp; runspaces together - Async logging in PowerShell&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Jan-Henrik Damaschke&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/aoH4I3WJneg&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;After you watched this session you will have an understanding of multithreading, especially with runspaces in &lt;strong&gt;PowerShell&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;You will also have knowledge about how to abstract complex constructs with classes in PowerShell.&lt;/p&gt;

&lt;p&gt;Did you ever had some issues with multithreading in PowerShell? In this session you will see a practical example for when multithreading in PowerShell really makes sense.&lt;/p&gt;

&lt;p&gt;We will take a look at how to implement asynchronous logging and how to abstract a reusable class with PowerShell classes.&lt;/p&gt;

&lt;h3 id=&quot;i-compare-powershell-edition&quot;&gt;I Compare: PowerShell Edition&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Mathias R. Jessen&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/zggWL-0gefo&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;This session will focus on sorting and comparison of collections in PowerShell, specifically how to implement &lt;em&gt;IComparer&lt;/em&gt; and &lt;em&gt;IComparable&lt;/em&gt; types using PowerShell classes and how to leverage these with appropriate sorted built-in generic collection types.&lt;/p&gt;

&lt;p&gt;To get everyone up to speed, in the first half we’ll cover:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Introduction to .NET generics and reusable types&lt;/li&gt;
  &lt;li&gt;Ordering 101: Ordered vs Sorted vs Grouped - PowerShell classes and inheritance&lt;/li&gt;
  &lt;li&gt;Then dive into: - Custom ordering using Sort-Object&lt;/li&gt;
  &lt;li&gt;IComparable - type-intrinsic sorting&lt;/li&gt;
  &lt;li&gt;IComparer - custom sorting&lt;/li&gt;
  &lt;li&gt;Sorted Collections (SortedList, SortedDictionary, SortedSet)&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;become-a-parameter-ninja&quot;&gt;Become a parameter ninja&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;James O’Neill&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/LMw_mfYRHYI&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;PowerShell parameters. Easy, right ? We write them most days without even thinking.&lt;/p&gt;

&lt;p&gt;But the functions we create could be better to use, with code which is clearer and shorter – in other words easier -if we got their parameters absolutely right.&lt;/p&gt;

&lt;p&gt;This session will start with tips for recognizing and improving parameters which ask their questions in the wrong way, or which don’t take the input that users want to supply.&lt;/p&gt;

&lt;p&gt;This leads into when to declare parameter types and when not to and good and bad use of validation attributes. It will look at parameters sets, and when dynamic parameters are a good idea (and when they should be avoided).&lt;/p&gt;

&lt;p&gt;It will cover the importance of argument completers, and different ways to write them which leads into the Ninja skills needed to create custom parameter attributes for tab-completing, transforming and validating values.&lt;/p&gt;

&lt;h3 id=&quot;dont-be-scared-of-calling-apis&quot;&gt;Don’t be scared of calling APIs!&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Graziella Iezzi&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/t66ZgGeykug&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Everyone has heard the word API, but what are they? What are they used for in web applications? How can they make your life easier on a daily basis?&lt;/p&gt;

&lt;p&gt;What can you actually automate? What limitations you can face, even using enterprise applications?&lt;/p&gt;

&lt;p&gt;This talk will give you an answer to those questions based on my experience working with third-party web applications like &lt;em&gt;Jira&lt;/em&gt;, &lt;em&gt;Trello&lt;/em&gt;, &lt;em&gt;BlueJeans&lt;/em&gt;, &lt;em&gt;Slack&lt;/em&gt;, &lt;em&gt;Workplace&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;I’ll show you a few examples of scripts I developed in PowerShell to automate how to grant user permissions, how I worked around when certain information was not exposed, how it was hard to me to set up my first header and body to &lt;code class=&quot;language-plaintext highlighter-rouge&quot;&gt;Invoke-RestMethod&lt;/code&gt;, how I used &lt;strong&gt;PSCustomObject&lt;/strong&gt; to validate data and return results, and to send a report by email, how to handle the different types of pagination.&lt;/p&gt;

&lt;h3 id=&quot;just-git-it&quot;&gt;Just git it!&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Bartek Bielawski&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/UAmlPhjjbyk&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;You simply don’t git it! People will tell you why you should git, when you should git it, but how…?&lt;/p&gt;

&lt;p&gt;Join me for fun ride where I will git you from zero to… git enough!&lt;/p&gt;

&lt;p&gt;I won’t shy away from answering “why” and “when” question, but will git past that and see just how good git can get. Tools, modules and tips included!&lt;/p&gt;

&lt;h3 id=&quot;building-a-custom-powershell-host&quot;&gt;Building a Custom PowerShell Host&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Adam Driscoll&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/B-uvhmbnMx4&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;This session will dive into building a custom PowerShell host.&lt;/p&gt;

&lt;p&gt;It will show you how to do things like process input, output progress, write to the screen and accept input for non-PowerShell command-line tools.&lt;/p&gt;

&lt;h3 id=&quot;beyond-lab-scripting-at-scale&quot;&gt;Beyond lab: Scripting at Scale&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Evgenij Smirnov&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/WkdnpfgYnDs&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;This is a compressed version of the two-part real-world data gathering workshop.&lt;/p&gt;

&lt;p&gt;We will look at some epic failures of scripts that look OK and work well in a small environment, then explore some routes of action to deal with huge amounts of data coming in from real-world scale sources like Active Directory, SQL or log stash.&lt;/p&gt;

&lt;h3 id=&quot;powershell-scoping-for-mere-mortals&quot;&gt;PowerShell Scoping for Mere Mortals&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Anthony Allen&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/aCpQ5IPw-Sk&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;In this session we will have a look from the ground up at how scoping in &lt;strong&gt;PowerShell&lt;/strong&gt; works.&lt;/p&gt;

&lt;p&gt;We’ll start off from the basics of the differences between dynamic and lexical scoping, working our way through modifying variables in different scopes and digging into what session state is and how we can use it to modify variables and even function definitions in runspaces.&lt;/p&gt;

&lt;p&gt;We will also look at the mechanisms of how &lt;strong&gt;PowerShell&lt;/strong&gt; implements scoping behind the scenes to get a solid understanding of the principles shown.&lt;/p&gt;

&lt;p&gt;This is the session for you who is a visual learner, there will be plenty of visualizations as well as lots of code examples, and dives into the &lt;strong&gt;PowerShell&lt;/strong&gt; source code to demonstrate what we have learnt.&lt;/p&gt;

&lt;h3 id=&quot;going-native-a-non-developers-tale&quot;&gt;Going native: A non-developer’s tale&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Evgenij Smirnov&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/o2WXIBoTayg&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;The integrative power of &lt;strong&gt;PowerShell&lt;/strong&gt; wouldn’t be what it has become if it weren’t for its ability to incorporate native APIs.&lt;/p&gt;

&lt;p&gt;Not all of them, however, have been designed in a way that makes immersion of native functionality into your &lt;strong&gt;PowerShell&lt;/strong&gt; scripts and modules easy.&lt;/p&gt;

&lt;p&gt;Not a developer myself, I invite fellow non-devs to join me on a journey towards successful integration of select Windows APIs into PowerShell - including obstacles I met along the way and recipes on how to overcome those.&lt;/p&gt;

&lt;p&gt;After this talk, you will be more prepared to extend your PowerShell-fu towards native platform functionality and hopefully forewarned about some pitfalls to avoid and appropriate moments to give up and look for other ways.&lt;/p&gt;

&lt;p&gt;After this talk, you will be more prepared to extend your PowerShell-future towards native platform functionality and hopefully forewarned about some pitfalls to avoid and appropriate moments to give up and look for other ways.&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><category term="Deep Shit" /><summary type="html">Watch sessions about mindblowing and fun PowerShell techniques, learn advanced know-how, and meet us in our live Q&amp;A!</summary></entry><entry><title type="html">Security</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/security" rel="alternate" type="text/html" title="Security" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/Security</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/security">&lt;p&gt;We are proud to present to you this years’ &lt;strong&gt;psconf.eu&lt;/strong&gt; sessions related to &lt;strong&gt;PowerShell Security&lt;/strong&gt;. For other topics, please see the other pages on &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/about&quot;&gt;powershell.one&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;We also invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting security topics. It is taking place &lt;strong&gt;June 2, 2020&lt;/strong&gt; at &lt;strong&gt;7pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other security experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;managing-secrets-from-your-dev-box-to-the-cloud&quot;&gt;Managing Secrets from your dev box to the cloud&lt;/h2&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Sydney Smith&lt;/a&gt; from the &lt;strong&gt;PowerShell&lt;/strong&gt; team.&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/uP4nhnLbXdo&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Advanced scripts that touch many systems require multiple secrets and types of secrets particularly when orchestrating across heterogeneous clouds.&lt;/p&gt;

&lt;p&gt;The best practice is to not hard code any secrets in scripts, but currently this requires custom code on different platforms to handle securely.&lt;/p&gt;

&lt;p&gt;Learn how the new secrets management model will allow you to securely use secrets to automate, manage and develop. Find out how to enhance your local and remote development experience with PowerShell secrets management.&lt;/p&gt;

&lt;h2 id=&quot;abusing-azure-active-directory-who-would-you-like-to-be-today&quot;&gt;Abusing Azure Active Directory: Who would you like to be today?&lt;/h2&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Dr. Nestori Syynimaa&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/tJkjOnxcw6w&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Azure AD is used by Microsoft Office 365 and over 2900 third-party apps. Although Azure AD is commonly regarded as secure, there are serious vulnerabilities regarding identity federation, pass-through authentication, and seamless single-sign-on.&lt;/p&gt;

&lt;p&gt;In this session, using my &lt;strong&gt;AADInternals&lt;/strong&gt; &lt;strong&gt;PowerShell&lt;/strong&gt; module, the exploitation of these vulnerabilities to create backdoors, impersonate users, and bypass MFA are demonstrated. The purpose of this session is to rise awareness of the importance of the principle of least privilege and the role of on-prem security to cloud security.&lt;/p&gt;

&lt;h2 id=&quot;building-the-ultimate-azure-ad-hacking-tool&quot;&gt;Building the ultimate Azure AD hacking tool&lt;/h2&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Dr. Nestori Syynimaa&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/NN1nIbp-z70&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;How did I built the ultimate Azure AD hacking tool from the scratch AADInternals is an open-source toolkit for hacking and administering Azure AD and Office 365.&lt;/p&gt;

&lt;p&gt;Come to see and learn how did I build the script-only module (seen in action at BlackHat USA &amp;amp; Europe 2019 Arsenal), what obstacles I had, and how I managed to overcome them!&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;AAD Internals&lt;/strong&gt; is a &lt;strong&gt;PowerShell&lt;/strong&gt; module where I’ve tried to put all the knowledge I’ve gained during the years spent with Office 365 and Azure AD. It is a result of hours of reverse-engineering and debugging of Microsoft tools related to Azure AD, such as PowerShell modules, directory synchronisation, and admin portals.&lt;/p&gt;

&lt;p&gt;I decided to make the module a plain PowerShell script module, so that everyone could copy and paste the code to their own scripts as needed. In this session, attendees will learn real-life experiences of making one’s knowledge available to the community in the form of easy-to-use PowerShell module. As such, the session contains a lot of war stories and live demos - just what the devs are looking for!&lt;/p&gt;

&lt;p&gt;You can open this web page in a separate window during the live event to submit live questions in real-time.&lt;/p&gt;

&lt;h3 id=&quot;what-the-log-so-many-events-so-little-time&quot;&gt;What the log?! So many events, so little time…&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Miriam Wiesner&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/nLoL7nj4aqU&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Detecting adversaries is not always easy. Especially when it comes to correlating Windows Event Logs to real-world attack patterns and techniques.&lt;/p&gt;

&lt;p&gt;Join me to find out how to match Windows Event Log IDs with the &lt;em&gt;MITRE ATT&amp;amp;CK&lt;/em&gt; framework and methods to simplify the detection in your environment.&lt;/p&gt;

&lt;p&gt;The PowerShell edition: see how to correlate events not only via the GUI, now you can automate it..!&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><summary type="html">Watch our sessions related to PowerShell Security, and meet us in our live Q&amp;A!</summary></entry><entry><title type="html">Cloud, Azure and DSC</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/cloud" rel="alternate" type="text/html" title="Cloud, Azure and DSC" /><published>2020-06-02T00:00:00+00:00</published><updated>2020-06-02T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/cloud</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/cloud">&lt;p&gt;This is not about &lt;em&gt;DSC in the Cloud&lt;/em&gt; but rather we are combining the topics &lt;em&gt;Cloud&lt;/em&gt;, &lt;em&gt;Azure&lt;/em&gt;, and &lt;em&gt;DSC&lt;/em&gt; in one panel. Below you find the awesome session videos touching on these topics, and we’d love to meet you live in our panel to discuss any questions you may have:&lt;/p&gt;

&lt;p&gt;We cordially invite you to participate in our &lt;a href=&quot;http://powershell.one/psconfeu/psconf.eu-2020/about#schedule&quot;&gt;live Q&amp;amp;A&lt;/a&gt; targeting &lt;strong&gt;PowerShell&lt;/strong&gt; Cloud, Azure &lt;em&gt;or&lt;/em&gt; DSC. It is taking place &lt;strong&gt;June 3, 2020&lt;/strong&gt; at &lt;strong&gt;6pm CEST&lt;/strong&gt;, and you’ll have a chance to meet the speakers, other security experts, and ask any question you may have.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Please note that &lt;strong&gt;psconf.eu&lt;/strong&gt; organizer and speakers are volunteers. While we are passionately committed to provide an awesome experience for you, we cannot &lt;em&gt;guarantee&lt;/em&gt; that things will always go according to plan. There is especially no guarantee that every speaker who delivered free content below can in fact join the Q&amp;amp;A.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;is-dsc-dead&quot;&gt;Is DSC Dead?&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Gael Colas &amp;amp; Michael Greene&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/hXS-rzs3Hak&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Unless you are heavily involved with &lt;em&gt;Desired State Configuration&lt;/em&gt; (DSC), and you’ve been paying attention to the DSC planning updates, the DSC Community Calls, you might have trouble seeing what’s going on with DSC.&lt;/p&gt;

&lt;p&gt;In this session, we’ll try to briefly review the why and what of DSC, decrypt all the recent news and see how it looks today, and finally make some predictions on its evolution.&lt;/p&gt;

&lt;p&gt;We’ll review DSC’s core principles and components, the differences between platform, solutions, resources and the community behind &lt;a href=&quot;https://www.youtube.com/redirect?redir_token=1da1pKx6IEkoqHFydjnIi7VPq4B8MTU5MTE3ODM2M0AxNTkxMDkxOTYz&amp;amp;event=video_description&amp;amp;v=hXS-rzs3Hak&amp;amp;q=https%3A%2F%2Fdsccommunity.org&quot;&gt;https://dsccommunity.org&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;We will discuss how third parties, such as Chef, Puppet, Ansible, but also AWS, VMWare, Cisco are leveraging the technology. Next, we’ll see a demo the work done by the PowerShell team to make invoking DSC resources work from PowerShell 7 on any platform from the RFC I wrote.&lt;/p&gt;

&lt;p&gt;We will discuss scenarios, current limitations and some tricks and tips you may find useful. Finally, we can’t talk about the future of DSC without spending some time on Azure Policy Guest Configuration, which leverages the new codebase of a DSC agent (sometimes called DSCv2 or LCMv2).&lt;/p&gt;

&lt;p&gt;We’ll look at how you can leverage DSC resources, enact changes, and how hybrid scenarios can be addressed with Azure ARC.&lt;/p&gt;

&lt;p&gt;As I’ve been lucky to be contracted by the DSC team to work with them and the PowerShell team for several months, feel free to bring your questions and feedback as I’m happy to forward your feedback!&lt;/p&gt;

&lt;h3 id=&quot;authoring-class-based-dsc-resources--notes-from-the-field&quot;&gt;Authoring class based DSC resources – notes from the field&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Bartek Bielawski&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/1Gxk5seP6oc&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;PowerShell classes were added to PowerShell language to improve experience for DSC resource authors.&lt;/p&gt;

&lt;p&gt;In this session, you will learn how you can extend DSC with resources written in a form of &lt;strong&gt;PowerShell&lt;/strong&gt; classes, complete with tips, lessons learned and common pitfalls.&lt;/p&gt;

&lt;p&gt;We will also look into testing of authored resources to make sure that resource gets the job done.&lt;/p&gt;

&lt;h3 id=&quot;automated-application-testing-with-azure-spot-vms--devops-pipelines&quot;&gt;Automated Application Testing With Azure Spot VMs &amp;amp; DevOps Pipelines&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Ben Reader &amp;amp; Friends&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/E50CUQ7Yr3M&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Automated Application Testing: How to make Azure Spot VMs and DevOps Pipelines do the work for you!&lt;/p&gt;

&lt;p&gt;PowerShell classes were added to PowerShell language to improve experience for DSC resource authors.&lt;/p&gt;

&lt;p&gt;In this session, you will learn how you can extend DSC with resources written in a form of PowerShell classes, complete with tips, lessons learned and common pitfalls.&lt;/p&gt;

&lt;p&gt;We will also look into testing of authored resources to make sure that resource gets the job done.&lt;/p&gt;

&lt;h3 id=&quot;captain-kusto-do-we-have-the-power&quot;&gt;Captain Kusto, do we have the Power?&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Mateusz Czerniawski&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/QK5yF3x1jek&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Azure Log Analytics (ALA) - what’s in it for me?&lt;/p&gt;

&lt;p&gt;We all ❤ logs. But the True Power of Logs comes with what you can do with them.&lt;/p&gt;

&lt;p&gt;Interested in building your own solution in under 15 minutes? It’s really easy with PowerShell to streamline the whole process Let’s talk about Logs as a Service - affordable, always available, easily customized and OS independent.&lt;/p&gt;

&lt;p&gt;After this session you’ll know more about:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Azure Monitor&lt;/li&gt;
  &lt;li&gt;Kusto Query Language (KQL)&lt;/li&gt;
  &lt;li&gt;Rest API for ALA&lt;/li&gt;
  &lt;li&gt;Azure Dashboards&lt;/li&gt;
  &lt;li&gt;Power BI reports&lt;/li&gt;
  &lt;li&gt;Alert rules&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;azure-devops-for-powershell&quot;&gt;Azure DevOps for PowerShell&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Barbara Forbes&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/ShBEpQlL6HE&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;Azure DevOps provides some great tooling for a DevOps working process.&lt;/p&gt;

&lt;p&gt;But what about PowerShell? In this session, I will show you the different ways you can make use of Azure DevOps when working with PowerShell.&lt;/p&gt;

&lt;p&gt;We will cover the basics: Connecting with GitHub, using the Azure DevOps repositories and creating CI/CD pipelines.&lt;/p&gt;

&lt;p&gt;With the help of some practical demo’s and you will be able to get started for yourself right after this session.&lt;/p&gt;

&lt;h3 id=&quot;azure-functions-in-a-hybrid-world&quot;&gt;Azure Functions in a hybrid world&lt;/h3&gt;

&lt;p&gt;by &lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/speakers&quot;&gt;Jan Egil Ring&lt;/a&gt;&lt;/p&gt;

&lt;iframe width=&quot;100%&quot; height=&quot;315&quot; src=&quot;https://www.youtube.com/embed/W_tAwZqsdbI&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;p&gt;In this session we will start by looking into scenarios for using Azure Functions in hybrid environments, before we dive into the different options for running Azure Functions in your on-premises networks.&lt;/p&gt;

&lt;p&gt;We will also look into best practices on how to organize and structure your functions, as well as see how we can store and retrieve global variables and credential assets.&lt;/p&gt;

&lt;h2 id=&quot;asking-questions&quot;&gt;Asking Questions&lt;/h2&gt;

&lt;p&gt;While live Q&amp;amp;A sessions are in progress, you can ask your questions by using our Q&amp;amp;A widget below. Note that you can also vote on questions others have submitted.&lt;/p&gt;

&lt;p&gt;The live Q&amp;amp;A widget is closed when there is no live session in progress. Use our form at &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; to submit questions before or after live sessions.&lt;/p&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;!&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have an organizational question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><category term="Questions" /><category term="Deep Shit" /><summary type="html">Watch sessions about mindblowing and fun PowerShell techniques, learn advanced know-how, and meet us in our live Q&amp;A!</summary></entry><entry><title type="html">psconf.eu Virtual Mini Conference</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/about" rel="alternate" type="text/html" title="psconf.eu Virtual Mini Conference" /><published>2020-05-30T00:00:00+00:00</published><updated>2020-05-30T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/About</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/about">&lt;h2 id=&quot;free-virtual-mini-conference&quot;&gt;Free Virtual Mini Conference&lt;/h2&gt;

&lt;p&gt;We kick this off &lt;strong&gt;June 2, 2020&lt;/strong&gt; at &lt;strong&gt;5pm CEST&lt;/strong&gt;, and you can watch it here:&lt;/p&gt;

&lt;div style=&quot;padding:56.25% 0 0 0;position:relative;&quot;&gt;&lt;iframe src=&quot;https://player.vimeo.com/video/424258187&quot; frameborder=&quot;0&quot; allow=&quot;autoplay; fullscreen&quot; allowfullscreen=&quot;&quot; style=&quot;position:absolute;top:0;left:0;width:100%;height:100%;&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;blockquote&gt;
  &lt;p&gt;If you are a speaker, we’ll send you a private invite link by Monday so you can join the panels and be “on stage”.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Our 25+ conference sessions are &lt;a href=&quot;https://www.youtube.com/channel/UCxgrI58XiKnDDByjhRJs5fg/feed?disable_polymer=1&quot;&gt;live already&lt;/a&gt;, and you can start watching them immediately: &lt;a href=&quot;http://powershell.video&quot;&gt;powershell.video&lt;/a&gt;. Please do so now and in the next days.&lt;/p&gt;

&lt;p&gt;Our &lt;em&gt;live&lt;/em&gt; sessions that we broadcast on this page June 2+3 are addressing your questions. That’s why we’d love you to watch the sessions now and then submit your questions.&lt;/p&gt;

&lt;p&gt;To submit your question (&lt;em&gt;anything&lt;/em&gt; &lt;strong&gt;PowerShell&lt;/strong&gt;-related that is on your mind), please use our &lt;a href=&quot;http://powershell.help&quot; target=&quot;_blank&quot;&gt;form&lt;/a&gt;. To ask questions in &lt;em&gt;real-time&lt;/em&gt; during a live session, use our Q&amp;amp;A widget:&lt;/p&gt;

&lt;h3 id=&quot;asking-questions-in-real-time&quot;&gt;Asking Questions in Real-Time&lt;/h3&gt;

&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;.&lt;/p&gt;

  &lt;p&gt;Real-time questions are available only when live sessions are in progress.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258187/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You might want to open the live Q&amp;amp;A widget in a &lt;a href=&quot;/psconfeu/psconf.eu-2020/live-questions&quot; target=&quot;_blank&quot;&gt;separate window&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;submitting-questions-offline&quot;&gt;Submitting Questions Offline&lt;/h3&gt;

&lt;p&gt;Feel free to submit as many &lt;strong&gt;PowerShell&lt;/strong&gt; questions as you like via &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; any time!&lt;/p&gt;

&lt;p&gt;We collect your questions and make sure they get addressed in the live panels. You can relax, lean back and watch the live sessions - knowing that your questions are already in the pipeline and will be asked on your behalf.&lt;/p&gt;

&lt;h2 id=&quot;schedule&quot;&gt;Schedule&lt;/h2&gt;

&lt;p&gt;There’s one single track. Below is our schedule.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Starting times of global events can be confusing. All times below are CEST (Central European Summer Time). Just click on any time below to automatically convert it to your local time, and you’ll never miss any session.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;june-2-2020&quot;&gt;June 2, 2020&lt;/h3&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Date &amp;amp; Time&lt;/th&gt;
      &lt;th&gt;Topic&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17&quot; target=&quot;_blank&quot;&gt;5:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Conference Opening&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17.5&quot; target=&quot;_blank&quot;&gt;5:30pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Keynote with Jeffrey Snover &amp;amp; Joey Aiello&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=18.75&quot; target=&quot;_blank&quot;&gt;6:45pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Keynote Q&amp;amp;A&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=19&quot; target=&quot;_blank&quot;&gt;7:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Security&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=20&quot; target=&quot;_blank&quot;&gt;8:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Pester &amp;amp; PowerShell Script Analyzer&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=21&quot; target=&quot;_blank&quot;&gt;9:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Remoting&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;h3 id=&quot;june-3-2020&quot;&gt;June 3, 2020&lt;/h3&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Date &amp;amp; Time&lt;/th&gt;
      &lt;th&gt;Topic&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17&quot; target=&quot;_blank&quot;&gt;5:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Suggestions, PS7, and PS Tips &amp;amp; Tricks&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=18&quot; target=&quot;_blank&quot;&gt;6:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Cloud and DSC (Desired State Configuration)&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=19&quot; target=&quot;_blank&quot;&gt;7:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Deep Shit&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=20&quot; target=&quot;_blank&quot;&gt;8:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell GUIs and IoT&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;h3 id=&quot;powershell-time-converter&quot;&gt;PowerShell Time Converter&lt;/h3&gt;

&lt;p&gt;If you’d like to use &lt;strong&gt;PowerShell&lt;/strong&gt; to convert times from &lt;em&gt;our&lt;/em&gt; timezone to &lt;em&gt;your&lt;/em&gt; timezone, you can use this:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# ask for the session start time, i.e.: 6:45pm&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Parameter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Mandatory&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;DateTime&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$time&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region formatting preferences&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# you can adjust these things to adopt the code to other use cases:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$culture&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'en-us'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$format&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;  &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'h:mm:ss tt'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cultureInfo&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Globalization.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CultureInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;CreateSpecificCulture&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$culture&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion formatting preferences&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region conversion details&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# timezone to convert from:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fromTimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-TimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'W. Europe Standard Time'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# timezone to convert to:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$toTimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-TimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion conversion details&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region perform conversion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$localTime&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertTimeBySystemTimeZoneId&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$time&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fromTimeZone&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ToTimeZone&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ToString&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$format&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cultureInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion perform conversion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# output result&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Make sure you enter the session by &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$localTime&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;!&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;quick-notes&quot;&gt;Quick Notes&lt;/h2&gt;

&lt;p&gt;Please help us spread the word by twitter and other channels. Simply point people to &lt;a href=&quot;http://powershell.love&quot;&gt;http://powershell.love&lt;/a&gt;!&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Please keep in mind that we all (speakers &amp;amp; organizers) run this event as &lt;em&gt;volunteers&lt;/em&gt;. We are &lt;em&gt;no&lt;/em&gt; video or virtual conference experts, and we have a life, partners, kids, and a job.&lt;/li&gt;
  &lt;li&gt;There can be things going wrong, and in fact, with slightly adapted words of the titanic engineer: &lt;em&gt;It’s not a question whether things go wrong but rather when&lt;/em&gt;. So let’s all together enjoy the best of this, and &lt;em&gt;learn&lt;/em&gt;.&lt;/li&gt;
  &lt;li&gt;Our main focus is solid technology, so the first (and most important) part of this event is almost fail-safe: our sessions are recorded and available via a video platform for download and viewing. They will stay available, just like all the other sessions from previous years: &lt;a href=&quot;https://www.youtube.com/channel/UCxgrI58XiKnDDByjhRJs5fg/feed?disable_polymer=1&quot;&gt;powershell.video&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;The &lt;em&gt;live&lt;/em&gt; part on &lt;strong&gt;June 2+3&lt;/strong&gt; is a great way for &lt;em&gt;you&lt;/em&gt; and &lt;em&gt;us&lt;/em&gt; to connect, ask questions, have fun, and talk. See video feed and Q&amp;amp;A widget above to view the live stream and interact and ask live questions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;thank-you&quot;&gt;Thank You!&lt;/h3&gt;

&lt;p&gt;This virtual event was made possible by:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Our sponsors &lt;em&gt;Microsoft&lt;/em&gt;, &lt;em&gt;SystemFrontier&lt;/em&gt;, &lt;em&gt;ScriptRunner&lt;/em&gt; and &lt;em&gt;PowerShellOne&lt;/em&gt; decided to stick with the event this year and support the free virtual event.&lt;/li&gt;
  &lt;li&gt;Our speakers who agreed to record part of their original sessions for &lt;em&gt;you&lt;/em&gt;.&lt;/li&gt;
  &lt;li&gt;Our core volunteers team consisting of &lt;a href=&quot;https://twitter.com/sqldbawithbeard&quot;&gt;Rob Sewell&lt;/a&gt;, &lt;a href=&quot;https://twitter.com/alexandair&quot;&gt;Aleksandar Nikolic&lt;/a&gt;, and &lt;a href=&quot;https://twitter.com/TobiasPSP&quot;&gt;myself&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Our trusted video processor &lt;a href=&quot;https://istream.pl/&quot;&gt;iStream&lt;/a&gt; who is supporting us and the entire event industry in these unusual times with advice and services.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you’ve never been at &lt;strong&gt;psconf.eu&lt;/strong&gt;, the best way to get a feeling for the welcoming spirit is a video from the last conference:&lt;/p&gt;

&lt;iframe width=&quot;800&quot; height=&quot;600&quot; src=&quot;https://www.youtube.com/embed/oYFw8YNSWAg&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have a question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><summary type="html">Join our virtual Mini Conference June 2+3, 2020, 5pm CEST! Below are the details. Our prerecorded sessions are live already.</summary></entry><entry><title type="html">psconf.eu Virtual Mini Conference</title><link href="http://powershell.one/psconfeu/psconf.eu-2020/about" rel="alternate" type="text/html" title="psconf.eu Virtual Mini Conference" /><published>2020-05-30T00:00:00+00:00</published><updated>2020-05-30T00:00:00+00:00</updated><id>http://powershell.one/psconfeu/psconf.eu-2020/About</id><content type="html" xml:base="http://powershell.one/psconfeu/psconf.eu-2020/about">&lt;h2 id=&quot;free-virtual-mini-conference&quot;&gt;Free Virtual Mini Conference&lt;/h2&gt;

&lt;p&gt;We kick this off &lt;strong&gt;June 2, 2020&lt;/strong&gt; at &lt;strong&gt;5pm CEST&lt;/strong&gt;, and you can watch it here:&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;If you do not see sliding images and hear music &lt;em&gt;ten minutes prior to launch&lt;/em&gt;, then please &lt;strong&gt;clear your browser cache&lt;/strong&gt;, or open this page in an incognito browser window. Apparently, on some systems the still image is cached a bit too long.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;div style=&quot;padding:56.25% 0 0 0;position:relative;&quot;&gt;&lt;iframe src=&quot;https://player.vimeo.com/video/424258225&quot; frameborder=&quot;0&quot; allow=&quot;autoplay; fullscreen&quot; allowfullscreen=&quot;&quot; style=&quot;position:absolute;top:0;left:0;width:100%;height:100%;&quot;&gt;&lt;/iframe&gt;&lt;/div&gt;
&lt;blockquote&gt;
  &lt;p&gt;We sent all speakers a private invite link so you can join the panels and be “on stage”. If you haven’t received the link by now, please contact us.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Our 25+ conference sessions are &lt;a href=&quot;https://www.youtube.com/channel/UCxgrI58XiKnDDByjhRJs5fg/feed?disable_polymer=1&quot;&gt;live already&lt;/a&gt;, and you can start watching them immediately: &lt;a href=&quot;http://powershell.video&quot;&gt;powershell.video&lt;/a&gt;. Please do so now and in the next days:&lt;/p&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Topic&lt;/th&gt;
      &lt;th&gt;Watch Videos (we turned them into collections)&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;PowerShell 7 &amp;amp; beyond&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/powershell-7&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/powershell-7&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;PowerShell Deep Shit&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/powershell-deep-shit&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/powershell-deep-shit&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Security&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/security&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/security&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Pester, VSCode, PSScriptAnalyzer&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/pester&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/pester&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;Cloud, Azure, &lt;em&gt;or&lt;/em&gt; DSC&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/cloud&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/cloud&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;IoT&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/iot&quot;&gt;https://powershell.one/psconfeu/psconf.eu-2020/iot&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;p&gt;Our &lt;em&gt;live&lt;/em&gt; sessions that we broadcast on this page June 2+3 are addressing your questions that you may have &lt;em&gt;after&lt;/em&gt; watching the videos (which coincidentally is why we ask you to watch them before the live sessions).&lt;/p&gt;

&lt;p&gt;But don’t worry. You can watch them later, too. In our live panels, feel free to ask &lt;em&gt;any&lt;/em&gt; &lt;strong&gt;PowerShell&lt;/strong&gt;-related question that comes to your mind. Please do ask questions to get things rolling - we’re hoping for your input!&lt;/p&gt;

&lt;p&gt;To submit your question (&lt;em&gt;anything&lt;/em&gt; &lt;strong&gt;PowerShell&lt;/strong&gt;-related that is on your mind), please use our &lt;a href=&quot;http://powershell.help&quot; target=&quot;_blank&quot;&gt;form&lt;/a&gt;. To ask questions in &lt;em&gt;real-time&lt;/em&gt; during a live session, use our Q&amp;amp;A widget:&lt;/p&gt;

&lt;h3 id=&quot;asking-questions-in-real-time&quot;&gt;Asking Questions in Real-Time&lt;/h3&gt;

&lt;blockquote&gt;
  &lt;p&gt;You do not need to have a Vimeo account nor do you need to log in. Simply choose the option to &lt;strong&gt;Chat as a Guest&lt;/strong&gt;.&lt;/p&gt;

  &lt;p&gt;Real-time questions are available only when live sessions are in progress.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;iframe src=&quot;https://vimeo.com/live-chat/424258225/&quot; width=&quot;100%&quot; height=&quot;600&quot; frameborder=&quot;0&quot;&gt;&lt;/iframe&gt;
&lt;blockquote&gt;
  &lt;p&gt;You might want to open the live Q&amp;amp;A widget in a &lt;a href=&quot;/psconfeu/psconf.eu-2020/live-questions&quot; target=&quot;_blank&quot;&gt;separate window&lt;/a&gt;. We’ll also monitor &lt;a href=&quot;https://twitter.com&quot; target=&quot;_blank&quot;&gt;twitter&lt;/a&gt;, please use hashtag &lt;a href=&quot;https://twitter.com/search?q=psconfeu&quot; target=&quot;_blank&quot;&gt;#psconfeu&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;submitting-questions-offline&quot;&gt;Submitting Questions Offline&lt;/h3&gt;

&lt;p&gt;Feel free to submit as many &lt;strong&gt;PowerShell&lt;/strong&gt; questions as you like via &lt;a href=&quot;http://powershell.help&quot;&gt;http://powershell.help&lt;/a&gt; any time!&lt;/p&gt;

&lt;p&gt;We collect your questions and make sure they get addressed in the live panels. You can relax, lean back and watch the live sessions - knowing that your questions are already in the pipeline and will be asked on your behalf.&lt;/p&gt;

&lt;h2 id=&quot;schedule&quot;&gt;Schedule&lt;/h2&gt;

&lt;p&gt;There’s one single track. Below is our schedule.&lt;/p&gt;

&lt;blockquote&gt;
  &lt;p&gt;Starting times of global events can be confusing. All times below are CEST (Central European Summer Time). Just click on any time below to automatically convert it to your local time, and you’ll never miss any session.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3 id=&quot;june-2-2020&quot;&gt;June 2, 2020&lt;/h3&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Date &amp;amp; Time&lt;/th&gt;
      &lt;th&gt;Topic&lt;/th&gt;
      &lt;th&gt;Moderator&lt;/th&gt;
      &lt;th&gt;See Also&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17&quot; target=&quot;_blank&quot;&gt;5:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Conference Opening&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/TobiasPSP&quot; target=&quot;_blank&quot;&gt;Tobias&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17.5&quot; target=&quot;_blank&quot;&gt;5:30pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Keynote with Jeffrey Snover &amp;amp; Joey Aiello&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/TobiasPSP&quot; target=&quot;_blank&quot;&gt;Tobias&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=18.75&quot; target=&quot;_blank&quot;&gt;6:45pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Keynote Q&amp;amp;A&lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=19&quot; target=&quot;_blank&quot;&gt;7:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Security&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/alexandair&quot; target=&quot;_blank&quot;&gt;Aleksandar&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/security&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=20&quot; target=&quot;_blank&quot;&gt;8:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Pester &amp;amp; PowerShell Script Analyzer&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/sqldbawithbeard&quot; target=&quot;_blank&quot;&gt;Rob&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/pester&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=21&quot; target=&quot;_blank&quot;&gt;9:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Remoting&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/alexandair&quot; target=&quot;_blank&quot;&gt;Aleksandar&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt; &lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;h3 id=&quot;june-3-2020&quot;&gt;June 3, 2020&lt;/h3&gt;

&lt;table&gt;
  &lt;thead&gt;
    &lt;tr&gt;
      &lt;th&gt;Date &amp;amp; Time&lt;/th&gt;
      &lt;th&gt;Topic&lt;/th&gt;
      &lt;th&gt;Moderator&lt;/th&gt;
      &lt;th&gt;See Also&lt;/th&gt;
    &lt;/tr&gt;
  &lt;/thead&gt;
  &lt;tbody&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=17&quot; target=&quot;_blank&quot;&gt;5:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell 7, PowerShellGet, General PowerShell Chat&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/sqldbawithbeard&quot; target=&quot;_blank&quot;&gt;Rob&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/powershell-7&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=18&quot; target=&quot;_blank&quot;&gt;6:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;Cloud and DSC (Desired State Configuration)&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/alexandair&quot; target=&quot;_blank&quot;&gt;Aleksandar&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/cloud&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=19&quot; target=&quot;_blank&quot;&gt;7:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell Deep Shit&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/TobiasPSP&quot; target=&quot;_blank&quot;&gt;Tobias&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/powershell-deep-shit&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
    &lt;tr&gt;
      &lt;td&gt;&lt;a href=&quot;http://www.timebie.com/std/centraleuropeansummer.php?q=20&quot; target=&quot;_blank&quot;&gt;8:00pm CEST&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;PowerShell GUIs and IoT&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://twitter.com/sqldbawithbeard&quot; target=&quot;_blank&quot;&gt;Rob&lt;/a&gt;&lt;/td&gt;
      &lt;td&gt;&lt;a href=&quot;https://powershell.one/psconfeu/psconf.eu-2020/iot&quot;&gt;view&lt;/a&gt;&lt;/td&gt;
    &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

&lt;h3 id=&quot;powershell-time-converter&quot;&gt;PowerShell Time Converter&lt;/h3&gt;

&lt;p&gt;If you’d like to use &lt;strong&gt;PowerShell&lt;/strong&gt; to convert times from &lt;em&gt;our&lt;/em&gt; timezone to &lt;em&gt;your&lt;/em&gt; timezone, you can use this:&lt;/p&gt;

&lt;div class=&quot;language-powershell highlighter-rouge&quot;&gt;&lt;div class=&quot;highlight&quot;&gt;&lt;pre class=&quot;highlight&quot;&gt;&lt;code&gt;&lt;span class=&quot;c&quot;&gt;# ask for the session start time, i.e.: 6:45pm&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;kr&quot;&gt;param&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Parameter&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;Mandatory&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;DateTime&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
  &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$time&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region formatting preferences&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# you can adjust these things to adopt the code to other use cases:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$culture&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'en-us'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$format&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;  &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'h:mm:ss tt'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cultureInfo&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.Globalization.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;CultureInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;CreateSpecificCulture&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$culture&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion formatting preferences&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region conversion details&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# timezone to convert from:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fromTimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-TimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nt&quot;&gt;-Name&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;s1&quot;&gt;'W. Europe Standard Time'&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# timezone to convert to:&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$toTimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Get-TimeZone&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion conversion details&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#region perform conversion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$localTime&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;o&quot;&gt;=&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;p&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;System.&lt;/span&gt;&lt;span class=&quot;kt&quot;&gt;TimeZoneInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;]::&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ConvertTimeBySystemTimeZoneId&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$time&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$fromTimeZone&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$ToTimeZone&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;Id&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nf&quot;&gt;ToString&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$format&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;&lt;span class=&quot;w&quot;&gt; &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$cultureInfo&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;#endregion perform conversion&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;

&lt;/span&gt;&lt;span class=&quot;c&quot;&gt;# output result&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&quot;Make sure you enter the session by &lt;/span&gt;&lt;span class=&quot;nv&quot;&gt;$localTime&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;!&quot;&lt;/span&gt;&lt;span class=&quot;w&quot;&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/div&gt;

&lt;h2 id=&quot;quick-notes&quot;&gt;Quick Notes&lt;/h2&gt;

&lt;p&gt;Please help us spread the word by twitter and other channels. Simply point people to &lt;a href=&quot;http://powershell.love&quot;&gt;http://powershell.love&lt;/a&gt;!&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Please keep in mind that we all (speakers &amp;amp; organizers) run this event as &lt;em&gt;volunteers&lt;/em&gt;. We are &lt;em&gt;no&lt;/em&gt; video or virtual conference experts, and we have a life, partners, kids, and a job.&lt;/li&gt;
  &lt;li&gt;There can be things going wrong, and in fact, with slightly adapted words of the titanic engineer: &lt;em&gt;It’s not a question whether things go wrong but rather when&lt;/em&gt;. So let’s all together enjoy the best of this, and &lt;em&gt;learn&lt;/em&gt;.&lt;/li&gt;
  &lt;li&gt;Our main focus is solid technology, so the first (and most important) part of this event is almost fail-safe: our sessions are recorded and available via a video platform for download and viewing. They will stay available, just like all the other sessions from previous years: &lt;a href=&quot;https://www.youtube.com/channel/UCxgrI58XiKnDDByjhRJs5fg/feed?disable_polymer=1&quot;&gt;powershell.video&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;The &lt;em&gt;live&lt;/em&gt; part on &lt;strong&gt;June 2+3&lt;/strong&gt; is a great way for &lt;em&gt;you&lt;/em&gt; and &lt;em&gt;us&lt;/em&gt; to connect, ask questions, have fun, and talk. See video feed and Q&amp;amp;A widget above to view the live stream and interact and ask live questions.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3 id=&quot;thank-you&quot;&gt;Thank You!&lt;/h3&gt;

&lt;p&gt;This virtual event was made possible by:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Our sponsors &lt;em&gt;Microsoft&lt;/em&gt;, &lt;em&gt;SystemFrontier&lt;/em&gt;, &lt;em&gt;ScriptRunner&lt;/em&gt; and &lt;em&gt;PowerShellOne&lt;/em&gt; decided to stick with the event this year and support the free virtual event.&lt;/li&gt;
  &lt;li&gt;Our speakers who agreed to record part of their original sessions for &lt;em&gt;you&lt;/em&gt;.&lt;/li&gt;
  &lt;li&gt;Our core volunteers team consisting of &lt;a href=&quot;https://twitter.com/sqldbawithbeard&quot;&gt;Rob Sewell&lt;/a&gt;, &lt;a href=&quot;https://twitter.com/alexandair&quot;&gt;Aleksandar Nikolic&lt;/a&gt;, and &lt;a href=&quot;https://twitter.com/TobiasPSP&quot;&gt;myself&lt;/a&gt;.&lt;/li&gt;
  &lt;li&gt;Our trusted video processor &lt;a href=&quot;https://istream.pl/&quot;&gt;iStream&lt;/a&gt; who is supporting us and the entire event industry in these unusual times with advice and services.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you’ve never been at &lt;strong&gt;psconf.eu&lt;/strong&gt;, the best way to get a feeling for the welcoming spirit is a video from the last conference:&lt;/p&gt;

&lt;iframe width=&quot;800&quot; height=&quot;600&quot; src=&quot;https://www.youtube.com/embed/oYFw8YNSWAg&quot; frameborder=&quot;0&quot; allow=&quot;accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture&quot; allowfullscreen=&quot;&quot;&gt;&lt;/iframe&gt;
&lt;h2 id=&quot;leave-comment&quot;&gt;Leave Comment&lt;/h2&gt;

&lt;p&gt;Please feel free to leave a comment if you have a question or would like to share an idea.&lt;/p&gt;</content><author><name>Dr. Tobias Weltner</name><email>tobias@powershell.one</email></author><category term="psconf.eu" /><category term="blog" /><category term="PowerShell Conference" /><summary type="html">Join our virtual Mini Conference June 2+3, 2020, 5pm CEST! Below are the details. Our prerecorded sessions are live already.</summary></entry></feed>