private @NotNull String getTypedShellCommand() {
      if (myTypings.get() == 0) {
        return "";
      }
      TerminalLine terminalLine = processTerminalBuffer(this::getLineAtCursor);
      if (terminalLine != myTerminalLine) {
        return "";
      }
      String lineTextUpToCursor = getLineTextUpToCursor(terminalLine);
      if (lineTextUpToCursor.startsWith(myPrompt)) {
        return lineTextUpToCursor.substring(myPrompt.length());
      }
      return "";
    }
private @NotNull String getTypedShellCommand()