Sha256: abed246382da9437416b17f33a7dc12730dd25d4ef23f9d06a7b0b3c29dc0bfb

Contents?: true

Size: 1.53 KB

Versions: 17

Compression:

Stored size: 1.53 KB

Contents

class Bard < Thor
  {
    "SubmoduleDirtyError"       => "You have uncommitted changes to a submodule!\n  Please see Micah about this.",
    "SubmoduleUnpushedError"    => "You have unpushed changes to a submodule!\n  Please see Micah about this.",
    "NonFastForwardError"       => "Someone has pushed some changes since you last pulled.\n  Kindly run bard pull, ensure that your your changes still work, and try again",
    "MasterNonFastForwardError" => "The master branch has advanced since last deploy, probably due to a bugfix.\n  Rebase your integration branch on top of it, and check for breakage.",
    "NotInProjectRootError"     => "You are not in the project's root directory!",
    "OnMasterBranchError"       => "You are on the master branch!\n  This is almost always a bad idea. Please work on a topic branch. If you have made changes on this branch, please see Micah for assistance.",
    "WorkingTreeDirtyError"     => "You have uncommitted changes!\n  Please run git commit before attempting to push or pull.",
    "StagingDetachedHeadError"  => "The staging server is on a detached HEAD!\n  Please see Micah for assistance."
  }.each do |error, message|
    eval <<-RUBY
    class #{error} < Bard::Error
      def message
        %q{#{message}}
      end
    end
  RUBY
  end
  
  class TestsFailedError < Bard::Error
    def message
      "Automated tests failed!\n  See #{super} for more info."
    end
  end

  class TestsAbortedError < Bard::Error
    def message
      "Automated tests aborted!\n  See #{super} for more info."
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
bard-0.19.0 lib/bard/error.rb
bard-0.18.0 lib/bard/error.rb
bard-0.17.1 lib/bard/error.rb
bard-0.17.0 lib/bard/error.rb
bard-0.16.1 lib/bard/error.rb
bard-0.16.0 lib/bard/error.rb
bard-0.15.5 lib/bard/error.rb
bard-0.15.4 lib/bard/error.rb
bard-0.15.3 lib/bard/error.rb
bard-0.15.2 lib/bard/error.rb
bard-0.15.0 lib/bard/error.rb
bard-0.14.2 lib/bard/error.rb
bard-0.14.1 lib/bard/error.rb
bard-0.14.0 lib/bard/error.rb
bard-0.13.2 lib/bard/error.rb
bard-0.13.1 lib/bard/error.rb
bard-0.13.0 lib/bard/error.rb