Sha256: 99b1bf47867954bd037e1a52e2a0552f622bdded8a9f500e2572a4bf4ea1363e
Contents?: true
Size: 1.01 KB
Versions: 74
Compression:
Stored size: 1.01 KB
Contents
# frozen_string_literal: true require 'eac_ruby_utils/struct' module EacRubyUtils module Envs module BaseCommand module Concat AND_OPERATOR = '&&' BEFORE_OPERATOR = ';' OR_OPERATOR = '||' PIPE_OPERATOR = '|' # @param operator [Symbol] # @return [EacRubyUtils::Envs::CompositeCommand] def concat(operator, other_command) require 'eac_ruby_utils/envs/composite_command' ::EacRubyUtils::Envs::CompositeCommand.new(operator, self, other_command) end # @return [EacRubyUtils::Envs::Command] def and(other_command) concat(AND_OPERATOR, other_command) end # @return [EacRubyUtils::Envs::Command] def before(other_command) concat(BEFORE_OPERATOR, other_command) end def or(other_command) concat(OR_OPERATOR, other_command) end def pipe(other_command) concat(PIPE_OPERATOR, other_command) end end end end end
Version data entries
74 entries across 74 versions & 2 rubygems