What type of object is $: (such as `$code:`) in Powershell?

What you’re seeing is namespace variable notation, which is a variable-based way to access the content of items in PowerShell drives whose underlying provider implements content-based access (i.e., implements the IContentCmdletProvider interface). The general syntax is: ${<drive>:<path>} # same as: Get-Content <drive>:<path> ${<drive>:<path>} = … # same as: Set-Content <drive>:<path> -Value … The enclosing {…} … Read more