0
我試圖用ctags的應用索引我的軌道。這樣Vim可以給我自動完成。 但是,ctags並沒有索引所有的單詞,尤其是我對外部庫的調用。 例如: 我有這個文件:的ctags不是索引所有的話我想
class MultipleChoice < ActiveRecord::Base
has_many :options, :class_name => 'MultipleChoiceOption', :foreign_key => :parent_id, :dependent => :destroy
accepts_nested_attributes_for :options, :allow_destroy => true
def question
Question.find_by_data_id_and_data_type(id, MultipleChoice.name)
end
def randomized_options
(0...options.size).to_a.shuffle.map{|index| [index, options[index]]}
end
def realized_answer(user_answer)
user_answer.blank? ? nil : options[user_answer.to_i].content
end
def answer
options.detect{|o| o.correct}.content
rescue => e
HoptoadNotifier.notify(
:error_class => "MultipleChoice",
:error_message => "Exception while call #answer: #{e.message}",
:parameters => {:multiple_choice_id => self.id}
)
nil
end
end
然後CTAGS將索引選擇題(類名),答案(方法名),但不HoptoadNotifier。
我與ctags -R *
索引有沒有去告訴CTAGS索引他們呢?