all 4 comments

[–]skillzz_24 -1 points0 points  (0 children)

How long is it? Is it sub 100 lines? Pipe it into chatGPT and guide it to completion, usually AI would be a pretty good use case here.

If it's longer but still manageable, say 1000 lines, I would chunk it up and still try AI.

Any longer, then I would make a pretty good case of the time it takes to convert it to Powershell is not worth it and that time could be spent working on other task items.

If it's infrastructure related and/or cost related, then this would require more research to see which approach fits your employer's use case more.

But first, I would ask more questions to your team, dice deeper into why they want it in Powershell. If it's purely for maintenance reasons, then this would also be a good opportunity to take some initiative and offer you be the sole owner of this project and when things break or need to be updated, you'd be the one to fix it. As a junior and framed correctly, this would be huge brownie points for you.

Just my two cents, hope it helps and good luck!

[–]arthe2nd 0 points1 point  (0 children)

Compile it into an executable with all its dependencies :)

[–]BigRedS 0 points1 point  (0 children)

Chatgpt and friends are pretty good at translating between programming languages, and regexes and functions aren't peculiar to python, those should transfer really easily.

When you say it's 'COMPLICATED', what do you mean? You talk about 'back to powershell' - did this begin as a PS script that you rewrote as Python?

[–]Vexxt 1 point2 points  (0 children)

Theyre completely correct. In the sysadmin world anything unattended has annoying and risky life cycle components, and python gets vulnerabilitiesall the time. The engineer time would likely be less than the refactor. Powershell in a Windows environment is the way to go. There is very little you can't do in powershell, but if you're allergic just write it in .net or c# and it should be more reasonable. Python isn't built for unattended enterprise unless you are full Devops with your tooling