Markdown file view in Windows terminal



For PowerShell v6.1 or later, use command like this:

> Show-Markdown [file name]

https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.utility/show-markdown?view=powershell-7.4


From CMD, you can call the cmdlet like below, after installing PowerShell 7.4:

"C:\Users\<your username>\AppData\Local\Microsoft\WindowsApps\Microsoft.PowerShell_8wekyb3d8bbwe\pwsh.exe" -Command "Show-Markdown %1"


You can install the latest PowerShell,
  1. Using App Store

  2. winget search Microsoft.PowerShell
    winget install --id Microsoft.Powershell --source winget

Or, you can use this utility, https://github.com/charmbracelet/glow

No comments:

Powered by Blogger.