Using cedet semantic wisent-ruby

I'm just starting to set up cedet by following various guides, including Alex Ott's.

Here is what I have in my initialization file.

(require 'cedet) (semantic-load-enable-code-helpers) ;; imenu breaks if I don't enable this (global-semantic-highlight-func-mode 1) (global-semantic-tag-folding-mode) 

I really like code folding because semantics know more about code than packages like hideshow, etc.

I would like to have the same crease for a ruby. I know there is something else cedet does, but right now I'm just dipping my fingers.

So, I see in the contrib / wisent-ruby.el folder. He is sure semantics know how to parse Ruby. INSTALL says that it should be installed "automatically." I open a Ruby file, but there are no code folded magic triangles. Now what?

+6
source share
1 answer

As I see in contrib-loaddefs.el , the correct hooks and startups are generated only for php and C # modes. You can explicitly download wisent-ruby and set the appropriate hook, as in the following example:

 (require 'wisent-ruby) (add-hook 'ruby-mode-hook #'wisent-ruby-default-setup) 

but I did not check if the folding works for Ruby or not (because I also do not know the status of the Ruby analyzer). You can write to the cedet mailing list with additional questions about wisent-ruby ...

+4
source

Source: https://habr.com/ru/post/898378/


All Articles