# Why add commands to \`raco\`?

**URL:** <https://racket.discourse.group/t/why-add-commands-to-raco/3033>\
**Category:** Questions & Answers\
**Tags:** raco\
**Created:** [July 16, 2024, 6:12pm UTC](https://racket.discourse.group/t/why-add-commands-to-raco/3033 "2024-07-16T18:12:18Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![stevebyan](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@stevebyan](https://racket.discourse.group/u/stevebyan)\
**Post date:** [July 16, 2024, 6:12pm UTC](https://racket.discourse.group/t/why-add-commands-to-raco/3033/1 "2024-07-16T18:12:18Z")

</div>

I can see why one would put all the tooling needed to build and maintain Racket into `raco` as commands, but when does it make sense to add other commands to `raco`, as opposed to just running the executable?

For example, I can run `scribble` or `raco scribble`, but I'm not sure why I'd choose one over the other. It seems the only way to run `pollen` is via `raco pollen`. Why was that design choice made?

---

<div class="post-metadata">

**Author:** ![robby](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/robby/32/7_2.png) [@robby](https://racket.discourse.group/u/robby)\
**Post date:** [July 16, 2024, 6:35pm UTC](https://racket.discourse.group/t/why-add-commands-to-raco/3033/2 "2024-07-16T18:35:44Z")

</div>

My $0.02 is that we probably shouldn't have made "scribble" but just "raco scribble" but we didn't realize that initially. The thought is that it is good to avoid cluttering folks's paths with lots of stuff, but it isn't so bad to add lots of stuff to raco. Scribble is pretty important in the racket ecosystem, tho, so it is a close call, I suppose.

---

<div class="post-metadata">

**Author:** ![stevebyan](https://avatars.discourse-cdn.com/v4/letter/s/e56c9b/32.png) [@stevebyan](https://racket.discourse.group/u/stevebyan)\
**Post date:** [July 16, 2024, 7:15pm UTC](https://racket.discourse.group/t/why-add-commands-to-raco/3033/3 "2024-07-16T19:15:43Z")

</div>

Thanks. So basically it's a namespace pollution issue. I don't have too many Racket packages installed that provide executables, so I don't mind setting up my path to include `/Users/smb/Library/Racket/{latest}/bin`, where I see `rash-repl` and `rmacs`. I kinda wish `pollen` was there, too. But yeah, there shouldn't be much in `/Applications/Racket/bin`.

---

<div class="post-metadata">

**Author:** ![benknoble](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/benknoble/32/16_2.png) [@benknoble](https://racket.discourse.group/u/benknoble)\
**Post date:** [July 16, 2024, 7:52pm UTC](https://racket.discourse.group/t/why-add-commands-to-raco/3033/4 "2024-07-16T19:52:36Z")

</div>

FWIW, the relevant paths are spit out by `find-user-console-bin-dir` from `setup/dirs`, which I process with my pathadd function in my shell for PATH and MANPATH ([https://github.com/benknoble/Dotfiles/blob/a79114f053cc28cb6968fbd908b68610ef191fcc/links/zsh/mac/paths.zsh#L18-L27](https://github.com/benknoble/Dotfiles/blob/a79114f053cc28cb6968fbd908b68610ef191fcc/links/zsh/mac/paths.zsh#L18-L27)) like so

```scheme
command -v racket &>/dev/null && {
  racket_paths=($(IFS=$'\n' racket -I racket/base -e '
    (require setup/dirs)
    (for-each displayln
              (list (find-user-console-bin-dir)
                    (find-user-man-dir)))
  '))
  pathadd $racket_paths[1]
  pathadd man $racket_paths[2]
}

```
