这是indexloc提供的服务,不要输入任何密码
Skip to content

custom commands dont work in windows #686

@ES0T

Description

@ES0T

Describe the bug

if i put the following in my config file :

keybindings:
  universal: []
  issues: []
  prs:
    - key: k
      name: squash
      command: gh pr --repo {{.RepoName}} {{.PrNumber}} -s

when i press k on the approved PR, i get Whoops, got an error: exec: "sh": executable file not found in %PATH%

this is because on windows sh nor SHELL ENV do not exist by default.
see code executeCustomCommand

To Reproduce

  1. add above to config
  2. press k, on windows

Expected behavior
i expect the PR to be squashed and merged when k is pressed.
i expect custom commands on windows to work

Desktop (please complete the following information):

  • OS: windows 11 in powershell

my main request is i want a way to squash and merge, and not just merge a PR.
but, besides that, it seems like the above keybinding should be made to work.
on windows, i think the logic should be to default to powershell

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions