Open
Bug 998104
Opened 11 years ago
Updated 2 years ago
Add mach command to make it easier to extract configure/environment information in scripts
Categories
(Firefox Build System :: General, defect)
Firefox Build System
General
Tracking
(Not tracked)
NEW
People
(Reporter: nalexander, Unassigned)
References
Details
Attachments
(1 file)
3.32 KB,
patch
|
Details | Diff | Splinter Review |
|mach environment| is great for humans, but not very good for machines. I propose a |mach dump-environment KEY KEY KEY| command that just dumps configure defines/substs/whatever to the terminal for scripting, etc.
I considered rolling this into |mach environment|, but that has a decent amount of conditional logic that I don't want to route around.
Reporter | ||
Comment 1•11 years ago
|
||
The idea is to make it easier to extract configure/environment
information in local developer scripts. Most importantly, this makes
easy to find the current topobjdir: |mach dump-environment topobjdir|.
I really don't care if we roll this into |mach environment|. We just
need something like |mach environment| that is easy to parse from the
shell.
Attachment #8408647 -
Flags: review?(gps)
Attachment #8408647 -
Flags: feedback?
Reporter | ||
Updated•11 years ago
|
Attachment #8408647 -
Flags: feedback? → feedback?(ted)
Reporter | ||
Comment 2•11 years ago
|
||
Argh, I see I called it dump-configure, not dump-environment. Somebody paint this shed!
Comment 3•11 years ago
|
||
how about adding an option to mach environment to output a machine-readable format, instead?
Reporter | ||
Comment 4•11 years ago
|
||
(In reply to Mike Hommey [:glandium] from comment #3)
> how about adding an option to mach environment to output a machine-readable
> format, instead?
I wondered about that, dumping JSON or similar. Comments about how special the environment command are still apply. My case is really about shell, though -- almost any key/value dump is a pain to parse.
Comment 5•11 years ago
|
||
Comment on attachment 8408647 [details] [diff] [review]
Add |mach dump-environment KEY| command. r=gps
Review of attachment 8408647 [details] [diff] [review]:
-----------------------------------------------------------------
I'd add a flag to mach environment.
Attachment #8408647 -
Flags: review?(gps)
Comment 6•11 years ago
|
||
With bug 762358, mach environment has a new --format option that allows different kinds of output, one of which is json. If that's enough for you, then we can call that bug fixed. Note that this json output is also stored in $objdir/.mozconfig.json.
Comment 7•11 years ago
|
||
Oh, and mach environment --format=json --verbose outputs a json with even more info.
Comment 8•11 years ago
|
||
Comment on attachment 8408647 [details] [diff] [review]
Add |mach dump-environment KEY| command. r=gps
Oops, I left this sitting. I defer to gps. It sounds like glandium has you sorted, though.
Attachment #8408647 -
Flags: feedback?(ted)
Updated•7 years ago
|
Product: Core → Firefox Build System
Updated•2 years ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•