class Capistrano::Wearerequired::SlackistranoMessagingElements

Public Class Methods

new(options = {}) click to toggle source
Calls superclass method
# File lib/capistrano/wearerequired/slackistrano_messaging_elements.rb, line 7
def initialize(options = {})
  super(options)
end

Public Instance Methods

deployer() click to toggle source

Override the deployer helper to pull the best name available (git, password file, env vars).

# File lib/capistrano/wearerequired/slackistrano_messaging_elements.rb, line 12
def deployer
  name = `git config user.name`.strip.split.first
  name = nil if name.empty?
  name ||= Etc.getpwnam(ENV['USER']).gecos || ENV['USER'] || ENV['USERNAME']
  name
end