jesseduffield / lazygit

simple terminal UI for git commands

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

promptToReturnFromSubprocess not working

joshmedeski opened this issue · comments

Describe the bug
I see "Press enter to return to lazygit" when promptToReturnFromSubprocess: false.

+ bash -c nvim "mackup/.config/nvim/nvim-config/plugins.vim"

Error detected while processing function <SNR>105_Callback[3]..<lambda>17[1]..<SNR>105_GetCapabilitiesResult[2]..<SNR>105_AgentRequest[3]..<SNR>105_Send:
line    3:
Can't send data to closed stream
Press enter to return to lazygit

To Reproduce
Steps to reproduce the behavior:

  1. Open lazygit
  2. Edit a file by pressing e on an item in the buffer (via neovim)
  3. Quit neovim (:q)
  4. See "Press enter to return to lazygit"

Expected behavior
The promptToReturnFromSubprocess, when set to false, is supposed to skip this message and go directly back to lazygit.

If applicable, add screenshots to help explain your problem.

Screen Shot 2022-05-05 at 11 51 00 AM

Desktop (please complete the following information):

  • OS: macOS Monterey (v12.3)
  • Lazygit Version stable 0.34 (bottled) (via homebrew)
lazygit -v
commit=, build date=, build source=unknown, version=unversioned, os=darwin, arch=arm64

Additional context
Here is my config file, I've confirmed that it is properly loading other config values.

Click to view my lazygit config file
# cSpell:ignore brightblack unstaged unstage lazygit submodule repos pgup pgdown
  # stuff relating to the UI
  scrollHeight: 2 # how many lines you scroll by
  scrollPastBottom: true # enable scrolling past the bottom
  sidePanelWidth: 0.3333 # number from 0 to 1
  expandFocusedSidePanel: false
  mainPanelSplitMode: 'flexible' # one of 'horizontal' | 'flexible' | 'vertical'
  language: 'auto' # one of 'auto' | 'en' | 'zh' | 'pl' | 'nl'
    lightTheme: false # For terminals with a light background
      - magenta
      - bold
      - brightblack
      - brightblack
      - black
      - yellow
      - blue
      - cyan
      - gray
    show: true
  mouseEvents: true
  skipUnstageLineWarning: false
  skipStashWarning: true
  showFileTree: false # for rendering changes files in a tree format
  showListFooter: false # for seeing the '5 of 20' message in list panels
  showRandomTip: true
  showCommandLo: true
  commandLogSize: 8
  authorColors: # in case you're not happy with the randomly assigned colour
    'joshmedeski': '#ff0000'
    colorArg: always
    useConfig: true
    pager: delta --dark --paging=never --24-bit-color=never line-numbers
    # only applicable to unix users
    manualCommit: false
    # extra args passed to `git merge`, e.g. --no-ff
    args: ''
  skipHookPrefix: WIP
  autoFetch: true
  branchLogCmd: 'git log --graph --color=always --abbrev-commit --decorate --date=relative --pretty=medium {{branchName}} --'
  allBranchesLogCmd: 'git log --graph --all --color=always --abbrev-commit --decorate --date=relative  --pretty=medium'
  overrideGpg: false # prevents lazygit from spawning a separate process when using GPG
  disableForcePushing: false
  parseEmoji: false
  editCommand: '' # see 'Configuring File Editing' section
  editCommandTemplate: '{{editor}} {{filename}}'
  openCommand: ''
  refreshInterval: 10 # file/submodule refresh interval in seconds
  fetchInterval: 60 # re-fetch interval in seconds
  method: prompt # can be: prompt | background | never
  days: 14 # how often an update is checked for
reporting: 'on' # one of: 'on' | 'off' | 'undetermined'
confirmOnQuit: false
# determines whether hitting 'esc' will quit the application when there is nothing to cancel/close
quitOnTopLevelReturn: true
disableStartupPopups: false
notARepository: 'prompt' # one of: 'prompt' | 'create' | 'skip'
promptToReturnFromSubprocess: false # display confirmation when subprocess terminates
  - key: "Z"
    command: "cz commit"
    context: "files"
    loadingText: "opening commitizen commit tool"
    subprocess: true
    quit: 'q'
    quit-alt1: '<c-c>' # alternative/alias of quit
    return: '<esc>' # return to previous menu, will quit if there's nowhere to return
    quitWithoutChangingDirectory: 'Q'
    togglePanel: '<tab>' # goto the next panel
    prevItem: '<up>' # go one line up
    nextItem: '<down>' # go one line down
    prevItem-alt: 'k' # go one line up
    nextItem-alt: 'j' # go one line down
    prevPage: ',' # go to next page in list
    nextPage: '.' # go to previous page in list
    gotoTop: '<' # go to top of list
    gotoBottom: '>' # go to bottom of list
    prevBlock: '<left>' # goto the previous block / panel
    nextBlock: '<right>' # goto the next block / panel
    prevBlock-alt: 'h' # goto the previous block / panel
    nextBlock-alt: 'l' # goto the next block / panel
    jumpToBlock: ["1", "2", "3", "4", "5"] # goto the Nth block / panel
    nextMatch: 'n'
    prevMatch: 'N'
    optionMenu: 'x' # show help menu
    optionMenu-alt1: '?' # show help menu
    select: '<space>'
    goInto: '<enter>'
    openRecentRepos: '<c-r>'
    confirm: '<enter>'
    confirm-alt1: 'y'
    remove: 'd'
    new: 'n'
    edit: 'e'
    openFile: 'o'
    scrollUpMain: '<pgup>' # main panel scroll up
    scrollDownMain: '<pgdown>' # main panel scroll down
    scrollUpMain-alt1: 'K' # main panel scroll up
    scrollDownMain-alt1: 'J' # main panel scroll down
    scrollUpMain-alt2: '<c-u>' # main panel scroll up
    scrollDownMain-alt2: '<c-d>' # main panel scroll down
    executeCustomCommand: ':'
    createRebaseOptionsMenu: 'm'
    pushFiles: 'P'
    pullFiles: 'p'
    refresh: 'R'
    createPatchOptionsMenu: '<c-p>'
    nextTab: ']'
    prevTab: '['
    nextScreenMode: '+'
    prevScreenMode: '_'
    undo: 'z'
    redo: '<c-z>'
    filteringMenu: '<c-s>'
    diffingMenu: 'W'
    diffingMenu-alt: '<c-e>' # deprecated
    copyToClipboard: '<c-o>'
    submitEditorText: '<enter>'
    appendNewline: '<a-enter>'
    extrasMenu: '@'
    toggleWhitespaceInDiffView: '<c-w>'
    checkForUpdate: 'u'
    recentRepos: '<enter>'
    commitChanges: 'c'
    commitChangesWithoutHook: 'w' # commit changes without pre-commit hook
    amendLastCommit: 'A'
    commitChangesWithEditor: 'C'
    ignoreFile: 'i'
    refreshFiles: 'r'
    stashAllChanges: 's'
    viewStashOptions: 'S'
    toggleStagedAll: 'a' # stage/unstage all
    viewResetOptions: 'D'
    fetch: 'f'
    toggleTreeView: '`'
    createPullRequest: 'o'
    viewPullRequestOptions: 'O'
    checkoutBranchByName: 'c'
    forceCheckoutBranch: 'F'
    rebaseBranch: 'r'
    mergeIntoCurrentBranch: 'M'
    viewGitFlowOptions: 'i'
    fastForward: 'f' # fast-forward this branch from its upstream
    pushTag: 'P'
    setUpstream: 'u' # set as upstream of checked-out branch
    fetchRemote: 'f'
    squashDown: 's'
    renameCommit: 'r'
    renameCommitWithEditor: 'R'
    viewResetOptions: 'g'
    markCommitAsFixup: 'f'
    createFixupCommit: 'F' # create fixup commit for this commit
    squashAboveCommits: 'S'
    moveDownCommit: '<c-j>' # move commit down one
    moveUpCommit: '<c-k>' # move commit up one
    amendToCommit: 'A'
    pickCommit: 'p' # pick commit (when mid-rebase)
    revertCommit: 't'
    cherryPickCopy: 'c'
    cherryPickCopyRange: 'C'
    pasteCommits: 'v'
    tagCommit: 'T'
    checkoutCommit: '<space>'
    resetCherryPick: '<c-R>'
    copyCommitMessageToClipboard: '<c-y>'
    popStash: 'g'
    checkoutCommitFile: 'c'
    toggleDragSelect: 'v'
    toggleDragSelect-alt: 'V'
    toggleSelectHunk: 'a'
    pickBothHunks: 'b'
    init: 'i'
    update: 'u'
    bulkMenu: 'b'
ezoic increase your site revenue