class Usmu::Github::Pages
Constants
- VERSION
The current version string for the gem
Public Class Methods
new()
click to toggle source
# File lib/usmu/github/pages.rb, line 10 def initialize @log = Logging.logger[self] @log.debug("Initializing usmu-github-pages v#{VERSION}") end
Public Instance Methods
command_deploy(args, options)
click to toggle source
# File lib/usmu/github/pages.rb, line 41 def command_deploy(args, options) Usmu::Github::Pages::Commands::Deploy.new(args, options).run(config) end
command_init(args, options)
click to toggle source
# File lib/usmu/github/pages.rb, line 37 def command_init(args, options) Usmu::Github::Pages::Commands::Init.new(args, options).run(config) end
commands(ui, c)
click to toggle source
@see Usmu::Plugin::CoreHooks#commands
# File lib/usmu/github/pages.rb, line 16 def commands(ui, c) @log.debug('Adding commands from usmu-github-pages.') @ui = ui c.command(:'gh-pages init') do |command| command.syntax = 'usmu gh-pages init' command.description = 'Ensures that your repository is compatible and setup correctly for Github Pages.' command.action(&method(:command_init)) end c.command(:'gh-pages deploy') do |command| command.syntax = 'usmu gh-pages deploy' command.description = 'Generates a site and commits it to Github.' command.action(&method(:command_deploy)) end end
config()
click to toggle source
# File lib/usmu/github/pages.rb, line 33 def config @config ||= Configuration.new(@ui.configuration['plugin', 'github-pages', default: {}]) end