nothingness

dev-app
Matthew Butterick 5 years ago
parent fd3a3cd38b
commit 15cf8f4e6f

@ -36,6 +36,9 @@
(current-manager-directory val) (current-manager-directory val)
(send directory-msg set-label (if val (path->string val) ""))) (send directory-msg set-label (if val (path->string val) "")))
(module+ main
(set-current-manager-directory (expand-user-path "~/git/bpt/")))
(define button-directory (define button-directory
(let ([str "Select project directory"]) (let ([str "Select project directory"])
(new button% (new button%
@ -123,10 +126,8 @@
(thread (λ () (thread (λ ()
(parameterize ([current-project-root dir]) (parameterize ([current-project-root dir])
(define stop (define stop
(start-server (format "/~a" (setup:main-pagetree dir)) #:serve-only #true)) (start-server (setup:main-pagetree dir) #:serve-only #true))
(thread-send cthd stop) (thread-send cthd stop)))))
(with-handlers ([exn:break? (λ (e) (stop))])
(sync/enable-break never-evt))))))
(current-server-stopper (thread-receive))]))])) (current-server-stopper (thread-receive))]))]))
(define button-stop (define button-stop

Loading…
Cancel
Save