atuin
atuin copied to clipboard
Powershell Support
I absolutely love the project and would love to be able to use it within powershell
Any news on PowerShell support?
@ellie and I are not against getting some basic powershell support, but neither of us run powershell or have the time right now to get familiar.
We have started to partially and unofficially support windows builds now, so it'll be the powershell integration that needs investigating.
- how can you hook into the prompt and detect key bindings
- how can you monitor command start and end events
- how can you update the prompt line with the search selection
Might be worth noting that Powershell is not a windows-only shell. I use it on my Linux machines and it's available for OSX as well.
I've been playing around with PowerShell support, see my prototype - you can import this file from your profile.
This mostly works for adding and updating the history. It's not perfect, e.g. it will include the time to render the prompt, which can be non-trivial in some cases.
I couldn't find a clean way to use redirection to capture the result from an interactive search, so I resorted to using a temporary file. It feels pretty slow on my VM but it seems to work.
One other thing I think PowerShell needs that doesn't apply to any other currently supported shell. PowerShell's notion of the current directory goes beyond the filesystem. atuin
should have an explicit parameter like atuin history --cwd hklm:\ -- ...
so PowerShell can specify these non-filesystem paths.
@ellie and I are not against getting some basic powershell support, but neither of us run powershell or have the time right now to get familiar.
We have started to partially and unofficially support windows builds now, so it'll be the powershell integration that needs investigating.
1. how can you hook into the prompt and detect key bindings 2. how can you monitor command start and end events 3. how can you update the prompt line with the search selection
https://github.com/kelleyma49/PSFzf
This issue has been mentioned on Atuin Community. There might be relevant details there:
https://forum.atuin.sh/t/terminal-setup/165/2