Method: What::Helpers.process_lines

Defined in:
lib/what/helpers.rb

.process_linesObject

Performs a simple strip of invalid UTF-8 characters on the output of ‘ps aux’



42
43
44
# File 'lib/what/helpers.rb', line 42

def self.process_lines
  `ps aux`.encode('UTF-16', invalid: :replace, undef: :replace).encode('UTF-8').split("\n")
end