File: example.sh

package info (click to toggle)
cwdaemon 0.10.2-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, sid, trixie
  • size: 1,192 kB
  • sloc: sh: 3,872; ansic: 2,425; perl: 1,181; makefile: 66
file content (12 lines) | stat: -rwxr-xr-x 180 bytes parent folder | download | duplicates (9)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh

old_tty_settings=$(stty -g)
stty -icanon
trap 'stty "$old_tty_settings"; exit 0' INT

echo "Press (CTRL-C) to interrupt..."

while true; do
  nc -u localhost 6789
done