@grips The weird thing is that it doesn't.
@grips "V souboru zadaném druhým argumentem spoÄÃtá poÄet Åádků a pÅedá ÄÃslo na standardnà výstup a úspÄÅ¡nÄ skonÄà (pokud soubor existuje). Pokud soubor zadaný druhým Åádkem neexistuje, musà skript skonÄit neúspÄÅ¡nÄ (tj. s nenulovým návratovým kódem, použijte napÅ. exit 1) a souÄasnÄ musà pÅedat chybové hlášenà (libovolné, neprázdné) na standardnà chybový výstup"
@grips Yeah
@matrix Wait a second⦠second argument? Whatâs the first for then?
@grips just -v it just does echo "verze"
@matrix Aight. Disregarding that part:
#!/bin/bash out=$(wc -l "$2") if [ $? == 0 ]; then echo $out | cut -d " " -f 1 exit 0 else echo "oh boy you goofed up :^)" >&2 exit 1 fi
fookin hell
@grips That's a mouthful
Thanks it works
@grips
Thanks, I'm probably fine. Just one script and Vi remaining.
Trying to think about something not too verbose but it's hard... maybe in a few minutes.