plasma-disassembler / plasma

Plasma is an interactive disassembler for x86/ARM/MIPS. It can generates indented pseudo-code with colored syntax.
GNU General Public License v3.0
3.05k stars 275 forks source link

v command not working, 256 colors problem #58

Closed ibrahimkaraguzel closed 8 years ago

ibrahimkaraguzel commented 8 years ago

Hello; i have compiled plasma with all dependencies. I run plasma with your test binaries. And the "x" command works. Like i enter "x main" and enter, i see a good-looking disassembly.

Bu the the v command doesn't work, it gives a traceback error : `# plasma -i /var/pisi/plasma-0.0-1/work/plasma-0.0/tests/server.bin plasma> v main

Traceback (most recent call last): File "/usr/lib/python3.4/site-packages/plasma/lib/ui/console.py", line 526, in exec_command c.callback_exec(args) File "/usr/lib/python3.4/site-packages/plasma/lib/ui/console.py", line 655, in exec_v Visual(self.gctx, ctx, self.analyzer, self.api) File "/usr/lib/python3.4/site-packages/plasma/lib/ui/visual.py", line 102, in __init curses.init_pair(1, 253, 66) # for the highlight search _curses.error: init_pair() returned ERR plasma>`

ghost commented 8 years ago

It looks like your terminal doesn't support 256 colors. What is your terminal ? Run this command to see if it returns "256" : tput colors. Thanks.

ibrahimkaraguzel commented 8 years ago

the command returns 8 what shall i do to turn it to 256

ghost commented 8 years ago

What terminal are you using ?

ibrahimkaraguzel commented 8 years ago

Os X terminal with solarized theme (it is colorful though?)

ghost commented 8 years ago

Try to add this line in your bashrc (or equivalent) : export TERM=xterm-256color

Or try this (I'm not a mac user) : http://deploymentzone.com/2012/03/08/solarized-vim-256-colors-terminal-app-and-osx-lion/

ibrahimkaraguzel commented 8 years ago

ok i got the situation! default os x termial is already 256! No problem But under my machine i am working with a docker machine which uses a linux distribution. And that linux terminal is 8 colored. Thanks anyway :)