When using the open file dialog on Eclipse, many file types open in the internal editor as expected (.java,.txt). However, others open in an external editor. For example on my system attempting to open.sh file causes it to open it in emacs, and.py files open in bluefish.
...
You have two alternatives: either install an eclipse plug-in to manage the kind of file you want to edit (like e.g. pyDev for python), or go to Window > Preferences > Editors > File Associations and associate your file extensions to the built-in text editor in Eclipse.
Учитывая, что у вас установлен emacs, он стал редактором по умолчанию для .c
файлов, хотя текстовым редактором по умолчанию для текстовых файлов является gedit (Gnome Text Editor ).
Если вы сравните emacs.desktop
и org.gnome.gedit.desktop.
в /usr/share/applications
, вы увидите, что emacs регистрируется специально для файлов .c
, а gedit
только для текстовых файлов вообще. Я предполагаю, что более конкретный тип имеет приоритет.
Наконец-то я установил диск в качестве основного диска ноутбука, запустил установочный диск Ubuntu, и он заработал. Его можно перечислить и отформатировать. Я, вероятно, никогда не узнаю, почему, но проблема решена.