With PowerShell on Linux you’d never run dnf starting with Invoke-Expression. It’s completely unnecessary.
This feels like you either legitimately don’t know how it works so are assuming, or are making it more complicated on purpose to make bash look ‘better’.
I’m not saying PowerShell should be used on Linux over bash, but your example is not a good one.
Perfect example:
Bash:
sudo dnf install python
OR
PS: `Invoke-Expression ‘sudo dnf install package-name’
Stupid to even try and make the argument that PS is a viable solution to anything at all with its ignorant declarations of obvious usage.
With PowerShell on Linux you’d never run dnf starting with Invoke-Expression. It’s completely unnecessary.
This feels like you either legitimately don’t know how it works so are assuming, or are making it more complicated on purpose to make bash look ‘better’.
I’m not saying PowerShell should be used on Linux over bash, but your example is not a good one.