-
-
Notifications
You must be signed in to change notification settings - Fork 145
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
Tupfile.ini support #133
Tupfile.ini support #133
Conversation
I just gave this a whirl and it works pretty well. Not having to type four extra characters each time is actually pretty useful. |
This currently doesn't work if tup has the setuid bit set. It will create the I know how to fix this, but hold of on pulling / examining until I do. |
The Tupfile.ini commit is fixed to temporarily drop privileges while running |
I ran all the tests on this branch. Two things:
|
I've updated the commit to reset As for point 2, I think that's best addressed by you Mike. |
Hi Pat, Thanks for taking the time to work on this! See comments below... On Wed, Aug 21, 2013 at 2:47 AM, Pat Pannuto notifications@github.comwrote:
Some questions/feedback on Tupfile.ini:
As for making 'tup' do a 'tup upd' - the rationale behind having to https://groups.google.com/d/msg/tup-users/s5rR10Nb7X0/WB66mI8R7tUJ The bug mentioned in my last post was fixed in t7045. -Mike |
On Thu, Aug 22, 2013 at 8:13 AM, gittup notifications@github.com wrote:
The rationale behind this warning was to incentivize current tup users to Users of current build systems don't have to know anything about automake Under the current system, an explicit I'm willing to remove it, but I'd like to push back at least once before I do.
Then where do project preferences go? ./tup/options is not the right place My thought was that Tupfile.ini is the place to set project defaults, while As a strawman for other project-specific options that make sense, some of
As a motivating example for this, consider the init.default_variants that
The root Tupfile.ini, would specify building both the coreA and coreB variants I'm not certain it's the most necessary / useful feature, but it's there and
Yes, I thought of that a logically different feature, but I can add it to
Ugh.. another example of a discussion lost to the mailing list... I would push back against this as well. Commands like gcc don't print out
If you want the usage info from a program, you run Tup is fundamentally a build system tool, when I run tup, odds are I want I see this as one more point of friction in bringing over make / other build In discussions between @bradjc and I, getting rid of upd was actually the
Pat Pannuto |
Pull request updated to include default variants support. Also fixes a small bug in the original ini commit. |
Hi Pat, On Thu, Aug 22, 2013 at 4:05 PM, Pat Pannuto notifications@github.comwrote:
I like trying to make tup more user-friendly, but I don't think forcing
I think we can fix that by making a 'tup init' inside an existing hierarchy
Can you clarify which options you think are project preferences? For these updater.num_jobs That leaves only: updater.warnings And arguably both of those could go away. I'm trying to move toward making So exactly what options are you hoping to commit to the project as project
Tup already supports this in Linux and OSX since the temporary files are
I don't think I understand your terminology here. So coreA and coreB are
Ok :).
if inside tup hierarchy: How does that sound? -Mike |
On Tue, Aug 27, 2013 at 6:01 PM, gittup notifications@github.com wrote:
That should be what it does now :)
Pat Pannuto |
This latest series of commits should cover everything we've talked about. It's also rebased on top of the latest tup-master. |
Hey Mike, I know you were on vacation for a little while, are you back now / have you had a chance to look at this? I just rebased onto tup-master again to make sure everything will work / merge cleanly, looks good for me. -Pat |
Would it maybe be useful to split the tupfile.ini processing and the move to just a |
Sorry for the delay - after vacation I've also had a busy work trip, which On Sun, Oct 6, 2013 at 11:16 PM, Brad Campbell notifications@github.comwrote:
As I understand it, the options parsing of Tupfile.ini is just used for the Thanks, |
This commit seeks to obviate the explicit calling of `tup init`. When tup is run, it will now search for both a `.tup` directory or `Tupfile.ini` files on the path down to the root directory. If no `.tup` directory is found, tup will consider the directory closest to the root that had a `Tupfile.ini` file as the root of the project and automatically call `tup init` in that directory. To appease the idiom of `tup init && tup upd`, repeated calls to init will print a warning indicating that tup has already been init'd, but will still return success.
This commit deprecates the command `tup upd` in favor of the simpler, shorter command `tup`. Now that `tup init` is not required, there was only one "basic" tup command remaining: upd. This allows for much easier migration to tup for refugees from other "build systems", using tup is now as simple as just typing 'tup'. The command `tup upd` is preserved for legacy / backwards-compatability reasons. It is silently accepted.
None of the tests failed (on OS X at least), but these changes eliminate the large numbers of warnings that printed. Test t0001 is updated to create a Tupfile.ini in the custom init directory that it creates. Test t7052 is updated to expect the monitor to run twice, as it detects the call to `touch Tupfile.ini` from the test framework.
This pull request has been split. These commits cover: 1.) Adding Tupfile.ini |
On Sun, Oct 20, 2013 at 8:46 PM, Pat Pannuto notifications@github.comwrote:
Thanks for splitting this out! This is now in master. I've slightly -Mike |
These commits cover the features requested in #132.
The first commit handles the discovery and parsing of
Tupfile.ini
files as well as the automatic running oftup init
as necessary.The second commit obsoletes the command
tup upd
in favor of simplytup
.The individual commit messages go into greater detail on each point.