1

After starting terminal the cursor appears, but cannot type any character. I tried:

  1. To start Midnight Commander from Application list, but only blank terminal window started with blinking cursor;
  2. Installed Terminator, but starting it still a cursor appeared. Couldn't type anything, too.
  3. In IntelliJ IDEA I opened Console, but the symptoms were the same.
  4. Pressing ctrl+alt+F3 I could log in to tty3, the prompt appeared but couldn't type...

The keyboard works as usual... Any idea? Thanks in advance!

enter image description here

IntelliJ IDEA's console

Csongi77
  • 151
  • 1
    Probably there is something wrong with the startup files like /etc/profile, .profile, .bashrc, etc. etc. You haven't mentioned what did you do before this problem started. You can try with a newly created user. – FedKad Jul 12 '22 at 19:38
  • @FedKad Thank you! I created simple test user and the Terminal worked as usual but with my account still not working. – Csongi77 Jul 13 '22 at 04:07
  • 1
    I would start comparing "start-up" script files in the users' home directories: .profile, .bash_profile, .bashrc, .bash_aliases, .bash_completion, ... – FedKad Jul 13 '22 at 08:32
  • Thank you @FedKad I checked those files. – Csongi77 Jul 13 '22 at 15:20

2 Answers2

4

Thanks to @FedKad, I found the solution: in .bashrc I deleted the following lines:

# Load Angular CLI autocompletion.
source <(ng completion script)

and now it works perfectly!

FedKad
  • 10,515
Csongi77
  • 151
0

Here is a version of the solution if you want to keep Angular CLI autocompletion:

  1. Find the source <(some command) line in your .bashrc, in this case ng completion script
  2. In another terminal, run some command > ~/.ng.autocompletion.for.bashrc
  3. Replace the original source <(some command) line with source ~/.ng.autocompletion.for.bashrc

These steps will precalculate the output of the ng completion script command. There shouldn't be any major disadvantages with this because the output ng completion script is just a small wrapper that calls the actual ng --get-yargs-completions. In the unlikely case an Angular update breaks it, you can rerun step 2.

The cause of the original problem is that ng is written in Javascript running on Node.js, and Node.js programs are slow because they have to load a bunch of files from disk (my related answer).

Daniel T
  • 4,594