Yes, so lately I have been developing using the Ruby on Rails framework a lot. To my irony there ain't much choice nor there exist any really really good IDE or editor for Rails on Ubuntu(or rather Linux in general). You could use VIM or Emacs but for some reason that I cant understand I choose not to use them.
My favorite text editor on ubuntu was Gedit. Although by default you don't get a hell lot of features in it but the best I liked was tabbed browsing. I guess thats a common thing in most Linux GUI based applications. Ok so this is what your Gedit would look like:
Hmm.. so lets quickly start the process of changing Gedit into something close to textmate:
1) Lets quickly download Jose's Gedit bundle.
2) Edit the mime types file and add the below mentioned lines
sudo nano /etc/mime.types3) Update the new extensions mime typestext/x-ruby-source rhtml html.erb
text/x-eruby rjs
text/x-yaml yml
sudo update-mime-database /usr/share/mime
4) Copy the x-rhtml to the directory /usr/share/mime/packages
5) Copy extensions ruby.lang, rhtml.lang and rjs.lang the directory /usr/share/gtksourceview-2.0/language-specs
sudo cp gmate2/mime/x-rhtml.xml /usr/share/mime/packages
6) Update pluginssudo cp gmate2/langs/*.lang /usr/share/gtksourceview-2.0/language-specs
7) Copy the snippets (cuts)cp -R gmate2/plugins/* ~/.gnome2/gedit/plugins/
8) Copy the colorscp -R gmate2/snippets/* ~/.gnome2/gedit/snippets/
9) Remove a directory of your gnome settings
cp gmate2/styles/Rubycius.xml ~/.gnome2/gedit/styles/
where warlock is your username.rm -Rf /tmp/gconfd-warlock
10) Open the Gedit and on the menu: Edit> Preferences> Plugins tab and:
- Gemini (May auto complete parentheses, quotation marks, brackets, etc.)
- Snippets
- Snap Open (the key combination of CTRL + ALT + O opens a dialog where you can find the files you want)
12) Finally, if you want in the menu: Edit> Preferences tab "View" can: Show line numbers, and current line Highlight Show right margin.
If for some reason the formating dont appear then quickly go to the terminal and hit
If everything is done right you should get this sort of output(text highlighting) for your files you open:sudo update-mime-database /usr/share/mime
=================================================
||My FREE services||
ParkingWHOIS is now not only a domain parking lookup, but now also has reviews on Parking Companies.
=================================================
7 comments:
Cool, thanks!
Thanks, this really helped me to get yml highlighting into my favorite editor :D
thanks a loooot
this has helped my kungfu a little bit
wouldn't it be converting textmate into gedit? textmate is inspired by gedit.... but i do love textmate, but the problem is i use linux. i hate os x and i hate windows. so what am i to do? well, someone came up with a nice textmate bundle convert to gedit... because there are seemingly more people who make bundles for textmate than gedit... this is handy too: http://www.notgeeklycorrect.com/geek-stuff/2009/05/05/tmsnippets2gedit-transform-textmate-snippets-bundle-to-gedit-xml-snippet-file/
just change the following lies and line numbering will be visible in white color.
open
.gnome2/gedit/styles/Rubycius.xml
in your favorite text editor. There you will see following line
color name="gris" value="#000000"/>
change the value="#ffffff"
and you will get white colored line numbers.
Nice thanks! Only thing I want to add is: there are better places for all those files (where better means access without sudo):
- ~/.local/share/mime/packages
- ~/local/share/gtksourceview-2.0/language-specs
Post a Comment