You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jun 3, 2025. It is now read-only.
Repository navigation
This repository was archived by the owner on Jun 3, 2025. It is now read-only.
.tmc-autocomplete.sh should store opts on the disk instead of running tmc #389
source $HOME/.tmc-autocomplete.sh makes starting a new shell take up several seconds. Running the JVM every time you start a shell is not a good idea at all.
changed the title [-]sourcing .tmc-autocomplete.sh in rc file slows shell startup[/-][+].tmc-autocomplete.sh should store opts on the disk instead of running tmc[/+]on Aug 16, 2016
If the tmc doesn't exist. The bash script prints the following on my machine. bash: ~/tmc-cli/tmc: No such file or directory
I think we should hide any error messages from the auto-completion code.
The shell could die due to the strict mode set in your rc file. A workaround for this should be added into the launch script.
Yes, that seems to have been fixed in the master branch - I was using the latest release. Might be a good idea to draft a new one.
That being said, even with the latest version tmc still adds a short but noticeable delay when starting a new shell. Probably no big deal for anyone with a sufficiently powerful machine, but I think it would still be best if .tmc-autocomplete didn't run any Java code. Users with toasters may end up having to wait a few seconds. I keep the source line in my .bashrc commented when I'm not actively using it to speed it up.
Activity
[-]sourcing .tmc-autocomplete.sh in rc file slows shell startup[/-][+].tmc-autocomplete.sh should store opts on the disk instead of running tmc[/+]jclc commentedon Aug 16, 2016
Also, if tmc is not found, the script hangs and you won't be able to run the shell at all.
Salmela commentedon Aug 19, 2016
The problem most likely is that the tmc tries to auto update. It was fixed in commit 214f880 .
Salmela commentedon Aug 19, 2016
If the tmc doesn't exist. The bash script prints the following on my machine.
bash: ~/tmc-cli/tmc: No such file or directoryI think we should hide any error messages from the auto-completion code.
The shell could die due to the strict mode set in your rc file. A workaround for this should be added into the launch script.
jclc commentedon Aug 19, 2016
Yes, that seems to have been fixed in the master branch - I was using the latest release. Might be a good idea to draft a new one.
That being said, even with the latest version tmc still adds a short but noticeable delay when starting a new shell. Probably no big deal for anyone with a sufficiently powerful machine, but I think it would still be best if .tmc-autocomplete didn't run any Java code. Users with toasters may end up having to wait a few seconds. I keep the source line in my .bashrc commented when I'm not actively using it to speed it up.
Salmela commentedon Aug 20, 2016
Yeah It's probably pretty easy to just dump the new commands into a file in the auto-update code. I will look into it.