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

Documentation should explain why this is needed #30

Closed
tjayrush opened this issue Nov 7, 2016 · 4 comments
Closed

Documentation should explain why this is needed #30

tjayrush opened this issue Nov 7, 2016 · 4 comments

Comments

@tjayrush
Copy link

tjayrush commented Nov 7, 2016

Cargo allows one to specify a build rust file as explained here: http://doc.crates.io/build-script.html.

I really like the idea behind this because I'm coming from C++ / makefile land, so I totally understand 'just,' what I'm wondering what just can do that cargo's build scripting cannot do. If nothing, then I'm not sure of its utility. If something, then it should be noted in the documentation.

I didn't read the entire documentation, so maybe it already is, but it wasn't obvious. Great idea though.

@casey
Copy link
Owner

casey commented Nov 7, 2016

Good question!

Cargo's build scripts have a pretty specific and limited use, they are used to control how cargo will build your project. Examples of this would be building a C library, finding the location of a system library you need to link in, running a codegen step, or adding flags to rustc invocations.

just, on the other hand, is for all those other miscellaneous commands you might run as part of development. You might have commands for running tests in different configurations, linting your code, pushing build artifacts to a server, removing temporary files, and the like.

Since you're used make, you've probably snuck in a few of these kinds of commands your makefile.

@casey
Copy link
Owner

casey commented Nov 7, 2016

Also, although just is written in rust, it can be used regardless of which language(s) your project is written in.

I think I'll add a FAQ and make this the first entry.

@tjayrush
Copy link
Author

tjayrush commented Nov 7, 2016

It's a simplified make--for use in any environment, not just rust. That's the reason I was looking for. I actually was using 'make' to run cargo and then a bunch of other stuff (like linking to a c++ program and then running some tests). I simply renamed the makefile to justfile and it worked perfectly. Thanks. I think an FAQ entry might help--also just look over the documentation with an eye towards the very first impression a user might get. I think my first impression was a make file system >>for rust<<< I'm not sure where that came from, but perhaps there's words in the first part of the readme that say that or something. Nice project. I like the idea of a simplified make.

@casey
Copy link
Owner

casey commented Nov 7, 2016

I simply renamed the makefile to justfile and it worked perfectly.

That's awesome to hear!

I like your explanation of it, although I would worry that people might assume that it's a build system if I call it simplified make. I might add something to the documentation that simple makefiles will probably work with just.

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

2 participants