• 0 Posts
  • 57 Comments
Joined 1 year ago
cake
Cake day: July 10th, 2023

help-circle
  • This blog does a fairly straight-forward job on explaining the basics. For me, I learn best in an interactive 1:1 or well-constructed video, so ChatGPT was priceless. I could ask it stupid questions all day long, and after throwing some different ideas around I started to see the essential parts and just let my prior knowledge of PS, .NET, and C# WPF take it from there.

    At the end of the day, all that really matters is using the PresentationFramework assembly and creating a window:

    • Add-Type -AssemblyName PresentationFramework
    • Either use Visual Studio > WPF Project and make the UI you want. Take the XAML file and use PowerShell to get the raw content:
      • $Xaml = Get-Content -Path MainWindow.xaml -Raw
      • $SanitizedXaml = $Xaml -replace “bad syntax e.g. Foreground={x:Null}” "Foreground=“Transparent” # Certain XAML syntax is incompatible with PS XML
      • [xml]$XmlReader = [System.Xml.XmlNodeReader]::new($SanitizedXaml)
      • $Window = [Windows.Markup.XamlReader]::Load($XmlReader)
    • Or, use .NET-style syntax in PS directly:
    • Then show the window:
      • $Window.ShowDialog() | Out-Null


  • Python is always something I intend to learn but never get around to. Does it natively handle GUI for process tooling or does it require a third party? What makes PowerShell so useful to me is the native ability to create visual applications without the need to compile. I can create tools for my company that launches right out of ConfigMgr Software Center and other technicians can contribute without needing a programming background.

    At home I want to mess around with tooling for home services without having to resort to web development.


  • By far it’s the object pipeline. Having structured data makes it easy to automate workflows in a predictable way. With bash everything is a string, so everything has to be parsed. It’s tedious.

    It took about a year of steady use before I came to enjoy the syntax. It shines in a production environment with other cooks in the kitchen. I never got into the C style, I like my code human readable at a glance. It’s fine if everyone’s a sage but we have a team with a mixture of skill levels and for me PowerShell gets it right.










  • Its such a weird thing to argue over, and looking at the downvotes, it seems like people here on Lemmy are just really pissed off at people these days (or they are conflict bots). No good things will come from that level of anger.

    You’ve been arguing so much in the comments that you’ve forgotten OP’s stated story and adopted your own fiction to defend. Like you said, it’s a weird thing to argue over, because what you’re talking about is not what anybody else is talking about. That’s why you’re getting down voted. But sure, convince yourself it’s pissed off people or “conflict bots,” whatever the hell that is. More fiction for your la-di-da world.

    Where I come from if someone gracefully asked if I’d be leaving soon I’d have no problem accommodating them if it suited me fine. The operative word is suited, because I don’t owe strangers anything. I can choose to be generous, or be in my right to reserve my generosity for someone who is more deserving. Doing so doesn’t make me a bad person.

    However, this is not what happened according to OP. The person suggested they hurry because they needed their table. That’s so rude I’m completely blown away at your effort here in the comments to white wash it and scold others for not being doormats like you want to be. Have fun with that.




  • I wanted to like it and I tried it over and over but I could not for the life of me get opensuse aeon or kalpa to work on my desktop when tumbleweed works perfectly. As soon as I installed the Nvidia drivers it went belly up and I couldn’t find help online.

    I’m still new to Linux so I’ll accept that I need more experience but I can’t help but feel like a degree in computer science is a recommended prereq for this stuff since there just doesn’t seem to be solid documentation to get you through it.

    That experience made me take microos off my server and put in proxmox instead.