Aarebrot.net

Frodes website about Sharepoint and other stuff...

  • Increase font size
  • Default font size
  • Decrease font size

PowerShell GeSHi Language File

E-mail Print
User Rating: / 0
PoorBest 

I use GeSHi to highlight code snippets on my webpage. Unfortunately GeSHi didn't already support PowerShell highlighting, and the only one I could find didn't match the PowerGUI colors that I've become used to. Hence I sat down and made my own language file to work with PowerShell.

I've tried to stay as true to the PowerGUI colors as possible, but I couldn't get everything to match 100%. It's still pretty close though, and I'm quite happy with it (for now). If you have any comments or suggestions, please let me know.

You can download the language file below.

  1. # Find all .ps1 scripts
  2. $files = Get-ChildItem | where { $_ -like "*.ps1" }
  3. # for loop
  4. for($count = 0; $count -lt 10; $c++)
  5. {
  6. "Hello world!"
  7. $empty = 6 + 3
  8. $empty--
  9. }

Attachments:
 posh.zip[PowerShell GeSHi language file]4 KbFeb-11-2010 6:17pm
Last Updated on Tuesday, 24 June 2008 14:54  
Comments (1)
nice work!
1 Sunday, 19 April 2009 03:52
bb
Thanks for sharing your file. I was also looking for a way to get the PowerGui colors into geshi....

Add your comment

Your name:
Subject:
Comment:
  The word for verification. Lowercase letters only with no spaces.
Word verification: