Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prefix output for --no-pretty with the package name #90

Closed
folke opened this issue May 19, 2020 · 6 comments
Closed

Prefix output for --no-pretty with the package name #90

folke opened this issue May 19, 2020 · 6 comments
Assignees
Labels
enhancement New feature or request question Further information is requested

Comments

@folke
Copy link
Owner

folke commented May 19, 2020

Right now, --no-pretty while mix output from all running commands and prefix them with the command.

It would be better to also add the package name to the prefix to make it easier to debug what output is coming from what command.

(see also #89)

@folke folke added the enhancement New feature or request label May 19, 2020
@folke folke self-assigned this May 19, 2020
folke added a commit that referenced this issue May 25, 2020
@folke
Copy link
Owner Author

folke commented May 25, 2020

Fixed in v3.4.1 🚀

@folke folke closed this as completed May 25, 2020
@tshelburne
Copy link

tshelburne commented Jun 3, 2020

Hi @folke, thanks for your quick attention on this - I am seeing where output is prefixed, but it looks like it is prefixed with the root command rather than the package name.

For example, my start script in @apps/client might be cross-env ENVVAR=whatever parcel index.html, in @apps/compute be run-p start:*, and in @apps/api run-p start:*. The output generally looks like this:

[run-p]
[run-p] 1:11:01 PM - Found 0 errors. Watching for file changes.
[run-p] [nodemon] restarting due to changes...
[run-p] [nodemon] restarting due to changes...
[run-p] [nodemon] restarting due to changes...
[run-p] [nodemon] starting `node build/server.js`
[run-p] Server running at http://localhost:3001
[cross-env] ✨  Built in 24.91s.
[run-p]
[run-p] 1:11:04 PM - Found 0 errors. Watching for file changes.
[run-p] [nodemon] restarting due to changes...
[run-p] [nodemon] starting `node build/server.js`
[run-p] Server running at http://localhost:3000

I would instead expect the relevant prefixes to be [@apps/api], [@apps/compute] and [@apps/client]. On top of having to know what commands runs each app, when the commands are the same, it's impossible to distinguish.

@folke folke reopened this Jun 7, 2020
@folke
Copy link
Owner Author

folke commented Jun 7, 2020

That's really odd.

Are you sure you're running the latest version of ultra? Should be 3.4.1 or higher.

Example output in one of my repos:

$ ultra -r --no-pretty --filter "apps/*" "echo test"
❯ @splora/api at apps/api (@splora/api)
❯ @splora/app at apps/app (@splora/app)
$ echo test (@splora/api)
$ echo test (@splora/app)
[@splora/api::echo] test
[@splora/app::echo] test

The first two lines are titles, then twice a command that will be executed, followed by the ouput.

Packages in this example are @splora/api and @splora/app

@folke folke added the question Further information is requested label Jun 7, 2020
@folke
Copy link
Owner Author

folke commented Jun 7, 2020

Package names are only added when running with -r, so when running in a single package. Maybe that's the issue?

@tshelburne
Copy link

You are correct, version problem. I updated the package.json in a different branch.

Thanks!

@folke
Copy link
Owner Author

folke commented Jun 7, 2020

Great, glad you figured it out!

@folke folke closed this as completed Jun 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants