class UserDocs::InstallGenerator
Installs the required files
Public Instance Methods
create()
click to toggle source
# File lib/generators/user_docs/install_generator.rb, line 10 def create check_for_version template "index", ".docs/index.html" template "_layouts/default", ".docs/_layouts/default.html" template "_includes/index", ".docs/_includes/index.html" empty_directory ".docs/_data/versions" empty_directory ".docs/versions" end
Private Instance Methods
check_for_version()
click to toggle source
# File lib/generators/user_docs/install_generator.rb, line 22 def check_for_version host_app = Rails.application.class return if defined?(host_app.module_parent::VERSION) # :nocov: abort "ERROR: version needs to defined as "\ "#{host_app.module_parent}::VERSION." # :nocov: end