nvim-lua / nvim-lua/kickstart.nvim
enhancement: add option for using Powershell as shell
Open
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 31.5k
- Forks
- 46.6k
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 4
Description
In neovim/neovim#36881, documentation was added to show how to use powershell.exe (or pwsh.exe) as the shell. I have ported the VimScript to Lua:
if vim.fn.has("win32") == 1 then
vim.o.shelltemp = false
local shellcmdflag = "-NoLogo -NoProfile -ExecutionPolicy RemoteSigned -Command "
shellcmdflag = shellcmdflag .. "[Console]::InputEncoding=[Console]::OutputEncoding=[System.Text.UTF8Encoding]::new();"
shellcmdflag = shellcmdflag .. "$PSDefaultParameterValues['Out-File:Encoding']='utf8';"
vim.o.shellpipe = "> %s 2>&1"
vim.o.shellquote = ""
vim.o.shellxquote = ""
if vim.fn.executable("pwsh.exe") == 1 then
vim.o.shell = "pwsh.exe"
shellcmdflag = shellcmdflag .. "$PSStyle.OutputRendering = 'PlainText';"
vim.env.__SuppressAnsiEscapeSequences = "1"
else
vim.o.shell = "powershell.exe"
end
vim.o.shellcmdflag = shellcmdflag
end
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names no file or test; start by locating where kickstart.nvim configures the shell and compare that entry point with the supplied Lua snippet. The change is done when users have an option to use powershell.exe or pwsh.exe with the described settings, and the configuration remains valid on other platforms.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua, powershell
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100