Skip to content

Instantly share code, notes, and snippets.

@AlexDaniel
Last active January 3, 2016 07:30
Show Gist options
  • Save AlexDaniel/1015a8072fb43442c81c to your computer and use it in GitHub Desktop.
Save AlexDaniel/1015a8072fb43442c81c to your computer and use it in GitHub Desktop.
Why use shell when you can pipe stuff using “run”?
#!/bin/bash
i=0
while :; do
echo "hello! $i"
((i % 100 == 0)) && beep
((i++))
done
#!/usr/bin/env perl6
my $out = run(‘./longoutput’, :out).out;
run(‘less’, :in($out));
say ‘Finished!’;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment