sschwarzer
2021-5-29 10:35:48

I tried adding a new package (see screenshot), but when I submitted the form, I only got an empty form back. I did not get the “Save failed” error message.


mflatt
2021-5-29 11:42:12

Which platform? Is the time you have in mind between the clear and return of (get-log-choices) in that example?


rostislav.svoboda
2021-5-29 12:11:21

Hi I have a beginner’s question. When running scribble foo.scrbl I get Warning: some cross references may be broken due to undefined tags and then a plenty of lines like (dep ((lib "racket/base.rkt") define)) what am I doing wrong?


soegaard2
2021-5-29 12:12:57

My guess is that you can fix the problem by following Asumu’s answer here: https://stackoverflow.com/questions/20685638/unresolved-links-in-scribble-lp-document


rostislav.svoboda
2021-5-29 12:15:24

To be precise cloned myself the https://github.com/willghatch/racket-rash and the exact command is scribble rash/scribblings/rash.scrb


rostislav.svoboda
2021-5-29 12:16:24

@soegaard2 Thanks. The scribble +m rash/scribblings/rash.scrblhelps but I still get: (dep ((lib "rash/private/lang-funcs.rkt") rash)) (dep ((lib "rash/private/lang-funcs.rkt") run-pipeline)) (dep ((lib "rash/private/top-level-print.rkt") current-rash-top-level-print-formatter)) (dep ((lib "rash/private/lang-funcs.rkt") splicing-with-rash-config)) (dep ((lib "shell/private/pipeline-macro-parse.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/private/cd.rkt") cd)) (dep ((lib "rash/private/lang-funcs.rkt") current-rash-top-level-print-formatter)) (dep ((lib "rash/private/lang-funcs.rkt") make-rash-transformer)) (dep ((lib "rash/private/lang-funcs.rkt") with-rash-config)) (dep ((lib "rash/private/lang-funcs.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/main.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/private/lang-funcs.rkt") cd))


soegaard2
2021-5-29 12:17:29

The identifiers rash, run-pipeline all come from rash, so try with (require (for-label rash)).



soegaard2
2021-5-29 12:22:09

What did you change scribble rash/scribblings/rash.scrb to?


rostislav.svoboda
2021-5-29 12:23:34

??? What do you mean? I just added the +m


soegaard2
2021-5-29 12:24:12

Try adding the redirect-main too. scribble --html +m --redirect-main <http://docs.racket-lang.org/> document.scrbl


rostislav.svoboda
2021-5-29 12:25:03

&gt; scribble --html +m --redirect-main <http://docs.racket-lang.org/> rash/scribblings/rash.scrbl [Output to rash.html] Warning: some cross references may be broken due to undefined tags: (dep ((lib "rash/private/lang-funcs.rkt") rash)) (dep ((lib "rash/private/lang-funcs.rkt") run-pipeline)) (dep ((lib "rash/private/top-level-print.rkt") current-rash-top-level-print-formatter)) (dep ((lib "rash/private/lang-funcs.rkt") splicing-with-rash-config)) (dep ((lib "shell/private/pipeline-macro-parse.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/private/cd.rkt") cd)) (dep ((lib "rash/private/lang-funcs.rkt") current-rash-top-level-print-formatter)) (dep ((lib "rash/private/lang-funcs.rkt") make-rash-transformer)) (dep ((lib "rash/private/lang-funcs.rkt") with-rash-config)) (dep ((lib "rash/private/lang-funcs.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/main.rkt") splicing-with-pipeline-config)) (dep ((lib "rash/private/lang-funcs.rkt") cd))


rostislav.svoboda
2021-5-29 12:25:17

That doesn’t help


soegaard2
2021-5-29 12:30:19

I am not sure what to do here, hopefully someone else will know. Your command line looks what I usually do: https://github.com/soegaard/sci/blob/master/flomat-doc/manual-flomat.scrbl


rostislav.svoboda
2021-5-29 12:32:56

I can try to ask the rash-repl author directly or create a github issue in his repo


sorawee
2021-5-29 12:57:57

$ git clone <https://github.com/willghatch/racket-rash.git> $ cd racket-rash/rash $ raco pkg install


sorawee
2021-5-29 12:57:57

Usually, to view a documentation for a package, you just install it. The setup will automatically render the docs for you.


rostislav.svoboda
2021-5-29 12:59:06

Yes but I’d like to recreate the documentation myself.


sorawee
2021-5-29 13:03:06

Well, you can edit it, and run

raco setup --pkg rash


sorawee
2021-5-29 13:03:12

that will re-render the documentation


rostislav.svoboda
2021-5-29 14:12:17

It took me a while to un-mess my machine, but the raco setup pkg rash works! Thanks.


rostislav.svoboda
2021-5-29 14:12:21

Without the --


rostislav.svoboda
2021-5-29 14:13:07

(proceeding to the next problem, after a break :slightly_smiling_face:


hazel
2021-5-29 18:33:37

how do I combine two picts while placing the first pict over the top? so like, (define pict-a (colorize (filled-rectangle 60 30) "tomato")) (define pict-b (colorize (disk 45) "cornflower blue")) (vc-append -30 pict-a pict-b) except instead of pict-b going on top of pict-a, it’s pict-a on pict-b


hazel
2021-5-29 18:34:09

I would use the superimpose functions but I don’t want a complete superimposition


soegaard2
2021-5-29 18:35:12

How about pin-over?


hazel
2021-5-29 18:35:25

I do want to extend the bounding box, though


soegaard2
2021-5-29 18:38:40

I think, I need to see an image of what you have in mind, at least if (vc-append -30 pict-b pict-a ) is not what you want.


hazel
2021-5-29 18:40:54

[1] vs [2]


hazel
2021-5-29 18:41:30

so pict-a takes precedence


soegaard2
2021-5-29 18:42:16

What is the result, you want?


hazel
2021-5-29 18:42:26

the latter


hazel
2021-5-29 18:43:16

I want to append the two images vertically, but I want pict-a to be over pict-b when they conflict


hazel
2021-5-29 18:45:51

basically I want [2], which I created by taking the first image and opening it in GIMP


soegaard2
2021-5-29 18:47:26

Maybe you can use inset, to adjust the bounding box first, then use superimpose.


hazel
2021-5-29 18:50:14

(lb-superimpose pict-b (inset pict-a 0 0 0 (- (pict-height pict-b) 30))) works, thanks


rostislav.svoboda
2021-5-29 18:56:24

Does anybody know how to encode the vertical bar in a @codeblock in scribble? Following code #lang scribble/manual @codeblock{ #!/usr/bin/env bash echo -e "hello \n world" \| wc -l } produces: #<syntax:cmds/scribblings/cmds.scrbl:4:4 "#!/usr/bin/env bash">:2:25: read-syntax: end-of-file following \| in symbol


soegaard2
2021-5-29 18:57:20

Things to try: \| @"|"


rostislav.svoboda
2021-5-29 19:00:25

\| returns the same \| and @"|" returns: #<syntax:cmds/scribblings/cmds.scrbl:4:4 "#!/usr/bin/env bash">:2:25: read-syntax: end-of-file following \| in symbol


rostislav.svoboda
2021-5-29 19:03:14

I also tried to get some inspiration from https://github.com/racket/scribble/blob/master/scribble-doc/scribblings/scribble/reader.scrbl but even the @litchar{|} leads to: string-append: contract violation expected: string? given: (element (style “RktInBG” (list ‘tt-chars (css-addition ’(collects #"scribble" #"racket.css")) (tex-addition ’(collects #"scribble" #"racket.tex")))) (list (element ‘hspace ’("")) (element (style “RktIn” (list ‘tt-chars (css-addition ’(collects #"scribb…


rostislav.svoboda
2021-5-29 19:48:24

This works: #lang scribble/manual @(require (for-syntax racket/base syntax/parse)) @(define-syntax (irash stx) (syntax-parse stx [(_ e1 e ...) #`(codeblock #:keep-lang-line? #f #,(datum-&gt;syntax #'e1 "#lang rash") "\n" e1 e ...)])) @irash{ #!/usr/bin/env bash echo -e "hello \n world" \| wc -l } however without syntax coloring.


sorawee
2021-5-29 22:07:26

Oh, my bad. That was a typo. I meant to write --pkgs.