Re: [racket-users] Flower Garden: a Patience Solitaire Game

2015-05-12 Thread Michael Tiedtke
the final revision of Flower Garden: PLUS undo and better performance ;; This is the message passing approach to the patience solitaire game ;; Flower Garden. ;; ;; This is the variant Flower Venus Garden with a relaxed ruleset. You ;; can move only one card at time but from anywhere to anywhere.

Re: [racket-users] Getting a sandboxed evaluator to work with a custom #lang's reader

2015-05-12 Thread Alexander D. Knauth
I managed to put this together: https://github.com/AlexKnauth/scribble-code-examples On May 12, 2015, at 7:10 AM, Alexis King wrote: > Continuing my attempts to make a working meta-language, I'm now working on > improving the documentation. I'd like to be able to use “interaction” from > scrib

Re: [racket-users] keystroke logger for DrRacket editor?

2015-05-12 Thread Tomi Pieviläinen
On Tue, May 12, 2015 at 11:31:01AM -0700, 'John Clements' via users-redirect wrote: > I’m interested in analyzing my own programming patterns in DrRacket. Has > anyone already written a keystroke logger / editor-change-logger for > DrRacket? I’m imagining that it would capture a session record

[racket-users] keystroke logger for DrRacket editor?

2015-05-12 Thread 'John Clements' via users-redirect
I’m interested in analyzing my own programming patterns in DrRacket. Has anyone already written a keystroke logger / editor-change-logger for DrRacket? I’m imagining that it would capture a session record starting with a known snapshot, then a sequence of keystrokes/edit actions, in such a way

Re: [racket-users] incantation for library module to access a data file in the same directory?

2015-05-12 Thread Sam Tobin-Hochstadt
You probably want to use `define-runtime-path`, like this: ``` (require racket/runtime-path) (define-runtime-path rtd "realtime-test-data.rkt") (define (fun-timed-test-2) (define ip (open-input-file rtd)) ... rest of function ...) ``` Sam On Tue, May 12, 2015 at 11:42 AM thomas.lynch < thoma

Re: [racket-users] accessing a directory local file to a module

2015-05-12 Thread Marc Burns
Check out define-runtime-path in the docs > On May 11, 2015, at 10:19 PM, thomas.lynch > wrote: > > I apologize if this posted before, but given a day I don't see it here.. > > I have a function with a companion data file (data file is part of the > collection). When I invoke it with a relat

[racket-users] accessing a directory local file to a module

2015-05-12 Thread thomas.lynch
I apologize if this posted before, but given a day I don't see it here.. I have a function with a companion data file (data file is part of the collection). When I invoke it with a relative path name (just the file name), racket looks for it in the directory the function is invoked from, not th

[racket-users] Re: Use Parsack to parse a #language?

2015-05-12 Thread Daniel Prager
Hi Stephen Thanks for the encouragement, and the tips: I was wondering especially about item 3. Once I get my head around what's needed to connect up a custom reader, I should be in a position to have a shot ... and ask further questions. Dan -- You received this message because you are subscri

[racket-users] Use Parsack to parse a #language?

2015-05-12 Thread Daniel Prager
I've been having a great time playing with Stephen Chang's Parsack (parsec-style parsing for Racket) and enjoying the straightforward learning curve and usability. Thanks Stephen! Has anyone used Parsack to do the parsing for a little language and th

[racket-users] incantation for library module to access a data file in the same directory?

2015-05-12 Thread thomas.lynch
I created a collection, then used raco to install it. Ran into a problem where a test function within module X in the collection accesses a file in the same directory as the source code: (define (fun-timed-test-2) (define ip (open-input-file "realtime-test-data.rkt")) (match-define (li

Re: [racket-users] Re: Use Parsack to parse a #language?

2015-05-12 Thread Asumu Takikawa
On 2015-05-12 00:15:45 -0400, Stephen Chang wrote: > I seem to recall that Racket used to come with a combinator parser > library. It's been removed but I don't remember why but maybe that > could be an indication that it's not a good idea? It was removed due to bitrot and to reduce the size of th

[racket-users] Re: Use Parsack to parse a #language?

2015-05-12 Thread Stephen Chang
> Once I get my head around what's needed to connect up a custom > reader Matthew's example from his talk at the first RacketCon (and other conferences) might be a good place to start: https://github.com/mflatt/scratchy/blob/master/scratchy/reader.rkt https://github.com/mflatt/scratchy/blob/master

Re: [racket-users] Re: Use Parsack to parse a #language?

2015-05-12 Thread Greg Hendershott
> On Mon, May 11, 2015 at 9:40 PM, Daniel Prager > wrote: I don't see Daniel's post yet. Is it just me, or is Google Groups delaying quite a few messages lately? > Greg Hendershott can probably fill you in on more unpleasantries, as > his markdown parser is the biggest client (that I currently

Re: [racket-users] Getting a sandboxed evaluator to work with a custom #lang's reader

2015-05-12 Thread Alexander D. Knauth
Is there a way to show examples in scribble docs that uses code? If there’s not, would something like this be good: @code-examples[#:lang “at-exp racket”]|{ (+ 1 2) @+[1 2] }| Renders as: Examples: > (+ 1 2) 3 > @+[1 2] 3 ? On May 12, 2015, at 7:10 AM, Alexis King wrote: > Continuing my

[racket-users] Getting a sandboxed evaluator to work with a custom #lang's reader

2015-05-12 Thread Alexis King
Continuing my attempts to make a working meta-language, I'm now working on improving the documentation. I'd like to be able to use “interaction” from scribble/eval with a custom evaluator, but I'm having trouble getting a custom evaluator to work with my language. I've tried using (make-module-