Sha256: 3aa2a7a057ba8c595b3bcb903d3375f7acddc1f2ec3f58e8875c37d1b05edc56

Contents?: true

Size: 745 Bytes

Versions: 7

Compression:

Stored size: 745 Bytes

Contents

# frozen_string_literal: true

module Neptuno
  module CLI
    # Init Neptuno files
    class Install < Dry::CLI::Command
      include TTY::Command
      include TTY::Prompt
      include TTY::File
      include TTY::Config
      include TTY::Which

      desc 'Installs git, docker, tmux, tmuxinator and overmind'

      CONFIG = nil

      def call(**)
        install 'git'
        install 'docker'
        install 'tmux'
        install 'overmind'
        install 'tmuxinator'
      end

      def install(package)
        if ::TTY::Which.exist?(package)
          puts "#{package} is already installed"
        else
          puts "Installing #{package}"
          system("brew install #{package}")
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
neptuno-1.0.7 lib/neptuno/cli/install.rb
neptuno-1.0.6 lib/neptuno/cli/install.rb
neptuno-1.0.5 lib/neptuno/cli/install.rb
neptuno-1.0.3 lib/neptuno/cli/install.rb
neptuno-1.0.2 lib/neptuno/cli/install.rb
neptuno-1.0.1 lib/neptuno/cli/install.rb
neptuno-1.0.0 lib/neptuno/cli/install.rb