samsave 156 B

1234567891011121314
  1. #!/bin/rc
  2. file=$1
  3. switch($#*){
  4. case 1
  5. echo -n $file'?'
  6. yn=`{read < /dev/cons}
  7. if(~ $yn y){
  8. cat > $file
  9. }
  10. case 2
  11. /bin/echo $file
  12. /bin/cat > $file
  13. }