Code Monkey home page Code Monkey logo

Comments (30)

seankhl avatar seankhl commented on May 18, 2024 7

tmux-256color is not happy with this. You can alias micro to

TERM=xterm-256color micro ...

to get around it.

from micro.

zyedidia avatar zyedidia commented on May 18, 2024 2

This should be fixed in v1.4.1 without the need for the mkinfo program.

from micro.

kiasaki avatar kiasaki commented on May 18, 2024 1

@hughrawlinson did you end up making it work? I have the same setup but when running env, TERM is set to screen-256color.

from micro.

fifty-six avatar fifty-six commented on May 18, 2024 1

I had my TERM as xterm-termite and changing it to xterm-256color temporarily worked well. Aliasing micro to TERM=xterm-256color micro as @seanlaguna said works well.

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

This is a tcell error (tcell is the terminal library micro uses).

Here is a description of the error:

ErrTermNotFound indicates that a suitable terminal entry could
not be found. This can result from either not having TERM set,
or from the TERM failing to support certain minimal functionality,
in particular absolute cursor addressability (the cup capability)
is required. For example, legacy "adm3" lacks this capability,
whereas the slightly newer "adm3a" supports it. This failure
occurs most often with "dumb".

I'm sorry but I don't think I can provide more help than this.

from micro.

hughrawlinson avatar hughrawlinson commented on May 18, 2024

No worries 😄 I'll play around with my config, and let you know if I come up with a solution.

from micro.

bentranter avatar bentranter commented on May 18, 2024

This works for me in the same setup as you @hughrawlinson -- OS X, zsh, iterm, tmux, and no tmux/iterm integration, so maybe I could provide some help, or we could compare our environments/configs?

from micro.

Anachron avatar Anachron commented on May 18, 2024

My TERM is xterm-termite and I get the same error.

from micro.

aoloe avatar aoloe commented on May 18, 2024

does not work for inside of dvtm in iterm2...

echo $TERM
dvtm-256color

from micro.

zQueal avatar zQueal commented on May 18, 2024
λ echo %term%
cygwin
λ micro
no suitable screen available

Setting term to xterm-256color also did not help and I get the same error; no suitable screen available.

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

Yes unfortunately tcell does not support cygwin. See here.

from micro.

ro31337 avatar ro31337 commented on May 18, 2024

Same thing is happening for me when I use screen on Ubuntu.

Linux roman-T450 4.4.0-34-generic #53-Ubuntu SMP Wed Jul 27 16:06:39 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux

Steps to reproduce:

  • Install screen (sudo apt-get install screen)
  • Run screen: screen
  • Edit something: sudo micro /etc/apt/sources.list

The error is "terminal entry not found".

$ echo $TERM
screen.xterm-256color

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

Ok I think I have a fix for this issue. Go checkout the terminal-entry-fix branch, and recompile micro. Note to compile micro on this branch, you need to have ncurses installed (sudo apt-get install libncurses5-dev). Let me know if it fixes the issue for you -- it worked for me.

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

A lot of these problems should now be fixed since the issue I opened in tcell was closed. I'll continue to look into a more general fix though. If you have this issue please post here what terminal emulator you are using.

from micro.

techtonik avatar techtonik commented on May 18, 2024

I've got a dumb terminal that is just a pipe to remote container, and it would be nice if micro error was more descriptive - at least allowed to distinguish between "TERM is not set" and "no absolute cursor (cup capability)".

from micro.

petervaro avatar petervaro commented on May 18, 2024

unfortunately the same thing is happening, when TERM is set to screen-16color while in tmux, running inside urxvt. (Same thing without tmux, as urxvt has the same TERM setting as tmux)

from micro.

felixsanz avatar felixsanz commented on May 18, 2024

This doesn't work on st, any update on this?

from micro.

ibrokemypie avatar ibrokemypie commented on May 18, 2024

same issue on kitty, but not alacritty?
https://github.com/kovidgoyal/kitty

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

If you have this issue you should go run mkinfo. Download one of the binaries or build it from source and then run the binary with the terminal that you are having the error with.

Hopefully micro will work after that.

from micro.

zb-z avatar zb-z commented on May 18, 2024

It doesn't have to support cygwin as in run under it's mintty. It would be enough to launch as any normal/plain windows editor. Part of this might be cygwin's fault, part micro's (for respecting invokers env too much). Here is what I did and got the same error ("no suitable screen available"), $TERM=xterm-256color but that's immaterial.

I've set .gitconfig (under cygwin) to
[core]
editor = ~/bin/git-editor.sh
and the script is one-liner:
cygpath "C:\utils\micro.exe" cygpath -w $1

That's how I'm launching windows editors from cygwin/git and I was looking for a small editor since it would be just editing commit messaged and add -e patches and maybe a few other chores.

So, if micro would check/know that it is actually running on windows it wouldn't/shouldn't even touch anything from cygwin but just run, the way it runs if you double-click it, with it's own conhost and life is good :-).

P.S.
For extra points it could for example sniff around a bit, figure out that it's being lauched by something from a path that contains cygwin (or cygwin64) and then say accept unix path format.

But first things first - needs to run :-)

from micro.

jotebe avatar jotebe commented on May 18, 2024

trying to run mkinfo to support termite on Arch Linux. But, mkinfo won't run, reporting /usr/lib/libtinfo.so.5 is either not found, or has no version information available.

I believe ncurses on arch is a newer release than mkinfo wants; is there an alternative way to extract the term info to give to micro?

from micro.

SscSPs avatar SscSPs commented on May 18, 2024

So, I recently found this project and I was interested in this,
I went ahead and installed it on my cloud(ubuntu) with
curl https://getmic.ro | bash
and when I try to run it, BAM!

terminal entry not found
Micro does not recognize your terminal: screen.xterm-256color
Please go to https://github.com/zyedidia/mkinfo to read about how to fix this problem (it should be easy to fix).

So I searched for it here, and this thread comes up,
So is there any fix?

from micro.

zyedidia avatar zyedidia commented on May 18, 2024

This should be fixed now and micro will automatically generate the tcell database by reading terminfo with infocmp if it cannot find the entry in the list of precompiled terminals. https://github.com/zyedidia/mkinfo is no longer necessary.

Micro should work out of the box with st, kitty and other terminals using their own TERM variable.

from micro.

Snuggle avatar Snuggle commented on May 18, 2024

@zyedidia
image

Apologies for responding to an old issue, but this isn't the case for kitty terminal, SSHing into a Raspberry Pi with Micro. Installed using the curl https://getmic.ro | bash command.

I also can't use mkinfo either, because no ARM binaries are available. 🙁

from micro.

techtonik avatar techtonik commented on May 18, 2024

Are there any references to standards that say that apps should fallback to first part of the name like xterm if a full terminal name like xterm-kitty is unknown to a program?

from micro.

Snuggle avatar Snuggle commented on May 18, 2024

Updated with curl https://getmic.ro | bash; and sudo mv ./micro /usr/bin/micro!
Thank you so much.

from micro.

Snuggle avatar Snuggle commented on May 18, 2024

I'm now sometimes getting the following error, @zyedidia.

terminal entry not found
Fatal: Micro could not initialize a screen

Should I make a new issue?

from micro.

techtonik avatar techtonik commented on May 18, 2024

@Snuggle at least it could be visible which entry not found.

from micro.

vladfi1 avatar vladfi1 commented on May 18, 2024

I needed to run mkinfo to get micro working in gnu screen.

from micro.

efrecon avatar efrecon commented on May 18, 2024

So for me, running micro twice after installation was what solved the problem when using kitty. I guess it creates the database the first time and needs to be restarted a second time to read it properly.

from micro.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.