Update code snippet in README.
authorDavid Thompson <dthompson2@worcester.edu>
Mon, 14 Jul 2014 01:21:26 +0000 (21:21 -0400)
committerDavid Thompson <dthompson2@worcester.edu>
Mon, 14 Jul 2014 01:21:26 +0000 (21:21 -0400)
* README.md (Usage): Update high-level API code snippet.

README.md

index f296e33..c7995db 100644 (file)
--- a/README.md
+++ b/README.md
@@ -18,9 +18,14 @@ To use the high-level API:
 ```
 (use-modules (tox))
 
-(with-tox (make-tox)
-  ;; TODO: Call your friend to ask if they've read their SICP today.
-  (display "Hello, Tox!\n"))
+(define tox (make-tox))
+
+(set-tox-name tox "Tox User")
+(set-tox-status-message tox "Happily hacking")
+;; TODO: Call your friend to ask if they've read their SICP today.
+(while #t
+  (tox-do tox)
+  (usleep (* (tox-do-interval tox) 1000)))
 ```
 
 To use the low-level API: