def parser
      @parser = OptionParser.new do |opts|
        opts.banner = 'Usage: obfusc <command> <arguments> <options>'
        opts.separator ''
        opts.separator 'Commands:'
        VALID_COMMANDS.each do |command|
          opts.separator "    * #{command}"
        end

        opts.separator ''
        opts.separator 'Specific options:'

        opts.on('-c', '--config FILENAME',
                'Using a different ".obfusc.cnf" filename') do |filename|
          @options[:config_path] = filename
        end

        opts.on(
          '-e',
          '--extension STRING',
          'Specify a custom file extension. (Default to "obfc")'
        ) do |extension|
          @options[:extension] = extension
        end

        opts.on(
          '-p',
          '--prefix STRING',
          'Specify a custom file prefix. (Default to "obfc")'
        ) do |prefix|
          @options[:prefix] = prefix
        end

        opts.on('-v', '--[no-]verbose', 'Run verbosely') do |v|
          @options[:verbose] = v
        end

        opts.on(
          '-s',
          '--[no-]simulate',
          'Do a simulate run without executing actions'
        ) do |v|
          @options[:simulate] = v
        end

        opts.separator ''
        opts.separator 'Common options:'

        opts.on_tail('-h', '--help', 'Show this message') do
          puts opts
          exit
        end
      end
    end
def parser
      @parser = OptionParser.new do |opts|
        opts.banner = 'Usage: obfusc <command> <arguments> <options>'
        opts.separator ''
        opts.separator 'Commands:'
        VALID_COMMANDS.each do |command|
          opts.separator "    * #{command}"
        end

        opts.separator ''
        opts.separator 'Specific options:'

        opts.on('-c', '--config FILENAME',
                'Using a different ".obfusc.cnf" filename') do |filename|
          @options[:config_path] = filename
        end

        opts.on(
          '-e',
          '--extension STRING',
          'Specify a custom file extension. (Default to "obfc")'
        ) do |extension|
          @options[:extension] = extension
        end

        opts.on(
          '-p',
          '--prefix STRING',
          'Specify a custom file prefix. (Default to "obfc")'
        ) do |prefix|
          @options[:prefix] = prefix
        end

        opts.on('-v', '--[no-]verbose', 'Run verbosely') do |v|
          @options[:verbose] = v
        end

        opts.on(
          '-s',
          '--[no-]simulate',
          'Do a simulate run without executing actions'
        ) do |v|
          @options[:simulate] = v
        end

        opts.separator ''
        opts.separator 'Common options:'

        opts.on_tail('-h', '--help', 'Show this message') do
          puts opts
          exit
        end
      end
    end
rubocop:disable BlockLength,MethodLength,AbcSize