class PoiseGit::GitClientProviders::System

A provider for `poise_git_client` to install from distro packages.

@since 1.0.0 @see PoiseGit::Resources::PoiseGitClient::Resource @provides poise_git_client

Public Instance Methods

git_binary() click to toggle source

Output value for the Git binary we are installing.

# File lib/poise_git/git_client_providers/system.rb, line 38
def git_binary
  # What should this be for OmniOS and SmartOS?
  "/usr/bin/git"
end

Private Instance Methods

install_git() click to toggle source

Install git from system packages.

@return [void]

# File lib/poise_git/git_client_providers/system.rb, line 48
def install_git
  install_system_packages do
    # Unlike language-ish packages, we don't need a headers package.
    dev_package false
  end
end
system_package_candidates(version) click to toggle source
# File lib/poise_git/git_client_providers/system.rb, line 65
def system_package_candidates(version)
  # This is kind of silly, could use a refactor in the mixin but just
  # moving on for right now.
  node.value_for_platform(self.class.packages) || %w{git}
end
uninstall_git() click to toggle source

Remove git from system packages.

@return [void]

# File lib/poise_git/git_client_providers/system.rb, line 58
def uninstall_git
  uninstall_system_packages do
    # Unlike language-ish packages, we don't need a headers package.
    dev_package false
  end
end