Re: [IronPython] Embedding Powershell and Write-Host

2009-01-16 Thread Stephen Ng
My VC .NET is apparently too old to do this :-(. But then I realized that I could get close enough by: 1. moving the main loop of my program from Powershell to Python 2. Rewriting Write-Host to stuff strings into a global: $global_log_messages = '' function Write-Host($s) { Set-Variable -Name

Re: [IronPython] Embedding Powershell and Write-Host

2009-01-13 Thread Curt Hagenlocher
Looking at the definitions of the C# classes in that blog entry and given that you're hosting PowerShell inside of IronPython, I see no reason why you wouldn't be able to implement the derived types in Python itself. But the link seems to do a pretty good job of giving minimal implementations for

Re: [IronPython] Embedding Powershell and Write-Host

2009-01-13 Thread Stephen Ng
Ouch, I guess I have to write some C#! There's no way to do this all in IronPython? Steve On Tue, Jan 13, 2009 at 4:06 PM, Curt Hagenlocher wrote: > You might find this link helpful. It was the second hit when googling > "implement pshost", and the author talks about integration between IronRub

Re: [IronPython] Embedding Powershell and Write-Host

2009-01-13 Thread Curt Hagenlocher
You might find this link helpful. It was the second hit when googling "implement pshost", and the author talks about integration between IronRuby and PowerShell. http://bartdesmet.net/blogs/bart/archive/2008/07/06/windows-powershell-through-ironruby-writing-a-custom-pshost.aspx On Tue, Jan 13, 20