DEV Community 👩‍💻👨‍💻

Ben Collins
Ben Collins

Posted on

Upgrading C# in your Razor files with PowerShell

git ls-files | sls web.config ` # get a list of web.config files here, but not with Get-ChildItem
  |% { (gc $_) -replace "/langversion:default","/langversion:latest" ` 
  | sc -Path $_ -Encoding UTF8 }

Top comments (0)

Create an Account!
Now it's your turn!
🗒 Share a tutorial
🤔 Reflect on your coding journey
❓ Ask a question

Create an account to join hundreds of thousands of DEV members on their journey.