Class: Awestruct::Commands::GitHubPages
- Inherits:
-
Object
- Object
- Awestruct::Commands::GitHubPages
- Defined in:
- lib/awestruct/commands/git_hub_pages.rb
Instance Method Summary collapse
-
#initialize(site_path) ⇒ GitHubPages
constructor
A new instance of GitHubPages.
- #run ⇒ Object
Constructor Details
#initialize(site_path) ⇒ GitHubPages
Returns a new instance of GitHubPages.
7 8 9 10 |
# File 'lib/awestruct/commands/git_hub_pages.rb', line 7 def initialize( site_path ) @site_path = site_path @git = Git.open(".") end |
Instance Method Details
#run ⇒ Object
12 13 14 |
# File 'lib/awestruct/commands/git_hub_pages.rb', line 12 def run @git.status.changed.empty? ? publish_site : (:existing_changes) end |