Triple dot iTerm locks command window - why does this occur and how to unlock the console? - command-line

I accidentally entered ... into my iTerm console, which led to a locked console session - what is the meaning behind this behaviour? Couldn't unlock the command line until i closed the session and now I'm really curious about what's going on. Found no fitting explanation elsewhere, thanks in advance!

Related

vim emulation extension in VScode causing problems

I've been using VS Code in "VIM mode" for years now without a problem. I'm on v1.46 now. I fired it up today and immediately couldn't type and other keys like escape failed to register. In the lower left corner, I'd intermittently see the following:
I went into extensions and disabled the Vim Emulator which now allow me to edit the file normally... without the vim functionality, of course.
I saw a bug filed through GitHub that looked like it might have addressed it, but it was closed due to lack of info provided.
Any ideas what might be going on or how I can get my vim functionality back?
UPDATE
Here's a bit more info:
I reinstalled and updated both VSCode and plugin - same behavior
Sometimes the whole thing failed from the get and other times (after restarting), it seemed to fail 1 key at a time - for example I'd be typing along and then all of a sudden hitting backspace produces an error message in the lower right corner to the effect of command 'extension.vim_backspace' not found - here's the closed issue on github - https://github.com/microsoft/vscode/issues/22365 for that specific message, but I also got errors with the escape and other keys
I also tried switching to NeoVim (on mac) which I thought was working, but eventually ended up going the same route (esc stopped working first typically)
I was having a similar problem with Vim in VS Code, and I noticed at the bottom-left when it reads --NORMAL-- or --VISUAL-- I typed the letter "i" and --INSERT-- appeared and allows me to type. I typed "i" because when I could type that is what I saw in the bottom-left corner of the screen.
Hope this is helpful.

Is it possible to send commands to an existing xterm process?

I have a running xterm and I want to get a program to pipe some commands to it. Is this possible? If yes, how could this be done?
Not without help. Someone recently asked a similar question about screen. It turns out that screen can accept commands, as discussed in Run commands in screen after creating one per bash.
So, you could run (a named session of) screen in an xterm and send commands to that.

Calling elisp code when awakening from sleep

I'd like to configure emacs a little differently when coming in over remote desktop. I can detect the rdp session, but I'd like to automatically run the function that checks when emacs wakes from sleep. I believe Windows issues a PBT_APMRESUMESUSPEND event when awakening because of user activity -- is there a way to hook this from within emacs?
This would be for emacs 24.4 on Windows. Some code or a pointer to the right documentation would be great. I've looked but am not seeing anything -- maybe I'm not looking in the right place. Thanks in advance.
I don't know of any hooks that are triggered in your situation, would it be possible to solve your situation using the input focus hooks?
Specifically, focus-in-hook.

In emacs, what does "Terminal 7 is locked, cannot read from it" mean?

When using emacs, I occasionally get the error Terminal 7 is locked, cannot read from it. What does this error mean?
Currently, I am receiving the error while I try to connect to an IRC server using erc, but I have received it before, though I don't remember for what. When it happened before, I was able to retry and eventually it worked, but now I get the same error every time.
I'm running a server session with emacs --daemon and have connected various clients with emacsclient -t.
I have searched for this online, but the only thing I can find is this. Aside from not being the exact question I have, it has no accepted answer. :(
This error means that some Elisp code is trying to read from the minibuffer (for example) while in the middle of some other command in another "terminal" (e.g. another tty). "In the middle" here means for example that you're using a minibuffer in that other terminal, or that you've hit a prefix key.
I suggest you try to come up with a reproducible way to trigger this error and then send it via M-x report-emacs-bug.

Emacs switches to old buffers when a stale command is quit

I must be in the habit of leaving the mini-buffer in the middle of a command. From there I will change buffers and continue working. Later (sometimes much later) I'll notice that I had a command dangling incomplete in the mini-buffer. If I go to cancel it with a C-g, Emacs will often swap buffers in my open windows to an earlier state.
I suppose this may be a feature, but in my flow of work I find it rather annoying. Is there a way to stop this behavior or prevent it from happening, such as a warning that There is an incomplete command?
I think that the answer to another question will help you solve this. It can be an annoying behavior, but the solution limits some of the flexibility found in Emacs.
The answer is: How can I prevent the mini-buffer from displaying previous commands in Emacs? (I call it stop-using-minibuffer).