Skip to content

Instantly share code, notes, and snippets.

@dyoo
Created May 4, 2012 16:53
Show Gist options
  • Save dyoo/2596189 to your computer and use it in GitHub Desktop.
Save dyoo/2596189 to your computer and use it in GitHub Desktop.
test program to raise error
#lang racket/base
(require racket/gui/base
racket/class)
(define (do-the-build)
(define f (new frame% [label "Building..."]))
(define t (new text% [auto-wrap #t]))
(define c (new editor-canvas% [parent f] [editor t]))
(send f show #t)
(void (thread (lambda ()
(parameterize ([current-output-port (open-output-text-editor t)])
(thread (lambda ()
(printf "Writing program #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/eli-number-puzzle.js>
Skipping writing resource #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/excanvas.js>; already exists
Skipping writing resource #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/canvas.text.js>; already exists
Skipping writing resource #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/optimer-normal-normal.js>; already exists
Writing html #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/eli-number-puzzle.html>
Writing manifest #<path:/gpfs/main/home/dyoo/work/whalesong/examples/eli-number-puzzle/eli-number-puzzle.appcache>
Build complete."))))))))
(define f (new frame% [label "test"]))
(new button% [parent f]
[label "build!"]
[callback (lambda (button event) (do-the-build))])
(send f show #t)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment