diff options
Diffstat (limited to 'examples/avahi.hs')
-rw-r--r-- | examples/avahi.hs | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/examples/avahi.hs b/examples/avahi.hs deleted file mode 100644 index e5567875..00000000 --- a/examples/avahi.hs +++ /dev/null | |||
@@ -1,16 +0,0 @@ | |||
1 | {-# LANGUAGE NoImplicitPrelude #-} | ||
2 | |||
3 | import BasePrelude | ||
4 | import Network.Tox.Avahi | ||
5 | |||
6 | exampleNodeId :: NodeId | ||
7 | exampleNodeId = read $ replicate 43 'a' | ||
8 | |||
9 | main :: IO () | ||
10 | main = do | ||
11 | [hostname, port, nodeId] <- getArgs | ||
12 | void $ forkIO $ announceToxServiceWithHostname | ||
13 | hostname (fromMaybe 54321 $ readMaybe port) | ||
14 | (fromMaybe exampleNodeId $ readMaybe nodeId) Nothing | ||
15 | void $ forkIO $ queryToxService (curry print) | ||
16 | void $ getLine | ||