Using getline to change the output into a variable from a pipe