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

Bacon 2 #66

Closed
Canop opened this issue Feb 13, 2022 · 9 comments
Closed

Bacon 2 #66

Canop opened this issue Feb 13, 2022 · 9 comments

Comments

@Canop
Copy link
Owner

Canop commented Feb 13, 2022

Bacon 2 is developed in the "bacon2" branch.

It makes possible to

  • run jobs like cargo run (and see the output)
  • run jobs like cargo doc --open (but not have it opening again and again)
  • bind a job to a key combination of your choice
  • change the key combinations for all internal functions (wrapping, quitting, etc.)

It comes with a help page listing all the configured key combinations, and I'll set up a site because while the simple use didn't change, some more complex uses are less obvious.

This will solve #47 and #52

Apart the web site, bacon 2 is mostly done. Now would be a good time to test it, comment.

@jyn514
Copy link
Contributor

jyn514 commented Feb 13, 2022

I still think something like google/argh#78 would be useful. The handling for doc-open is clever and I like that I can call it from the main job with a shortcut :)

@Canop
Copy link
Owner Author

Canop commented Feb 14, 2022

@jyn514 Replacing argh isn't out of question. Parsing arguments isn't a hard problem, especially when you don't try to make a public library. I'm pondering whether passing arguments this way is worth the task or not. Would that be used a lot ?

@Canop
Copy link
Owner Author

Canop commented Feb 14, 2022

Site almost ready: https://dystroy.org/bacon/

@jyn514
Copy link
Contributor

jyn514 commented Feb 14, 2022

@Canop I don't think there's any need to write your own parsing library, you could use gumdrop or clap or something which both support -- as a delimiter.

@Canop
Copy link
Owner Author

Canop commented Feb 14, 2022

Is there an issue declared here for passing arguments after -- ? I don't find one.

@jyn514
Copy link
Contributor

jyn514 commented Feb 14, 2022

#52 is somewhat related. My idea is that you could use bacon -- check -p my_crate_in_workspace without having to configure it in bacon.toml (it gets tedious when there are many crates). I don't think it makes sense to add support for every cargo flag in bacon directly.

@Canop
Copy link
Owner Author

Canop commented Feb 14, 2022

Hum, I was more imagining adding the arguments to a base job, for example

bacon ex -- bla -v some-arg

(assuming a "ex" job)

or

bacon -- -p my_crate_in_workspace

to take your example but assuming a base check job.

I'll create an issue anyway if you don't do it. I created #67 (it can be changed of course)

@cehteh
Copy link

cehteh commented Feb 14, 2022

on bacon 1.2 I have sometimes the issue that a borked test runs very long. Does bacon 2 offer some way (ctrl-c?) to kill the current subprocess (ideally some hook for nice level / ulimits would be nice too). If not I can make separate tickets for these.

@Canop
Copy link
Owner Author

Canop commented Feb 15, 2022

@cehteh Doesn't ctrl-c work well in bacon ? It was designed for that.
(note that I still have to do the same for the case of reverting to a previous process)

@Canop Canop closed this as completed in 77cee44 Feb 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants