mozconfig 0.1 → 0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/images/screenshot.png +0 -0
- data/README.md +22 -2
- data/VERSION +1 -1
- data/lib/mozconfig.rb +9 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 59a74179a6998999ae75456d60d917d38401bb03cb80f8635deb18bc28908d71
|
4
|
+
data.tar.gz: 52672b455cd18f67d63ebd3f1d4caa398a5584b784af1ccecf5df508875f1132
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 69777bced03234b0fb81c5246924e8ba520fc425e7dbd0510c11cda7319cbd5c58249e01809a55db1df49d331a33da1f729d6a0b7ac150462dfba129cfcde55d
|
7
|
+
data.tar.gz: 1be68db39f3fc5729ae110d5cf5aef2abdee402dc3a27a9710feba0052ee4d345e78505f9d4c4d96b167d359f1f93aaa834f03ec722dad86113bdf72db23e493
|
Binary file
|
data/README.md
CHANGED
@@ -25,16 +25,30 @@ ac_add_options --with-ccache=sccache
|
|
25
25
|
# ac_add_options --with-branding=browser/branding/nightly
|
26
26
|
# ac_add_options --enable-artifact-builds
|
27
27
|
|
28
|
+
# SpiderMonkey (debug)
|
29
|
+
# mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-js-debug-@CONFIG_GUESS@
|
30
|
+
# ac_add_options --enable-project=js
|
31
|
+
# ac_add_options --with-ccache=sccache
|
32
|
+
# ac_add_options --enable-debug
|
33
|
+
# ac_add_options --disable-optimize
|
34
|
+
|
35
|
+
# SpiderMonkey (optimized)
|
36
|
+
# mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-js-opt-@CONFIG_GUESS@
|
37
|
+
# ac_add_options --enable-project=js
|
38
|
+
# ac_add_options --with-ccache=sccache
|
39
|
+
# ac_add_options --enable-optimize
|
40
|
+
# ac_add_options --disable-debug
|
41
|
+
|
28
42
|
# Thunderbird
|
29
43
|
# mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-mail-@CONFIG_GUESS@
|
30
|
-
# ac_add_options --enable-project=comm/mail
|
31
44
|
# ac_add_options --with-branding=comm/mail/branding/nightly
|
45
|
+
# ac_add_options --enable-project=comm/mail
|
32
46
|
# ac_add_options --with-ccache=sccache
|
33
47
|
|
34
48
|
# Thunderbird (artifact build)
|
35
49
|
# mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/obj-mail-@CONFIG_GUESS@
|
36
|
-
# ac_add_options --enable-project=comm/mail
|
37
50
|
# ac_add_options --with-branding=comm/mail/branding/nightly
|
51
|
+
# ac_add_options --enable-project=comm/mail
|
38
52
|
# ac_add_options --enable-artifact-builds
|
39
53
|
```
|
40
54
|
|
@@ -42,3 +56,9 @@ The options are separated into "paragraphs", each one a separate configuration.
|
|
42
56
|
This tool will comment out all of the inactive configurations. The comment
|
43
57
|
above each paragraph will be the name displayed in the TUI. Any paragraph
|
44
58
|
without a comment above it will remain active in all configurations.
|
59
|
+
|
60
|
+
Run `mozconfig` at the root of the source tree and you will be presented with a
|
61
|
+
picker where you can select your configuration, e.g.:
|
62
|
+
|
63
|
+
![Screenshot of
|
64
|
+
TUI](https://github.com/vinnydiehl/mozconfig/blob/main/.github/images/screenshot.png)
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.
|
1
|
+
0.2
|
data/lib/mozconfig.rb
CHANGED
@@ -31,10 +31,18 @@ module MozConfig
|
|
31
31
|
@configs = configs.to_h { |cfg| [cfg.first.uncomment.strip, cfg[1..]] }
|
32
32
|
# Globals won't be manipulated further so we can rejoin them
|
33
33
|
@globals.map!(&:join)
|
34
|
+
|
35
|
+
# Find the active config
|
36
|
+
@active = @configs.find { |_, options| !options.first.commented? }.first
|
34
37
|
end
|
35
38
|
|
36
39
|
def run
|
37
|
-
selection =
|
40
|
+
selection = begin
|
41
|
+
TTY::Prompt.new.select("Pick a configuration", @configs, default: @active)
|
42
|
+
rescue TTY::Reader::InputInterrupt
|
43
|
+
$stderr.puts "\nProcess interrupted. Closing"
|
44
|
+
exit 130
|
45
|
+
end
|
38
46
|
|
39
47
|
output = "#{@globals.join("\n\n")}\n\n"
|
40
48
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mozconfig
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.2'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Vinny Diehl
|
@@ -59,6 +59,7 @@ executables:
|
|
59
59
|
extensions: []
|
60
60
|
extra_rdoc_files: []
|
61
61
|
files:
|
62
|
+
- ".github/images/screenshot.png"
|
62
63
|
- ".gitignore"
|
63
64
|
- ".rubocop.yml"
|
64
65
|
- Gemfile
|
@@ -90,7 +91,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
90
91
|
- !ruby/object:Gem::Version
|
91
92
|
version: '0'
|
92
93
|
requirements: []
|
93
|
-
rubygems_version: 3.4.
|
94
|
+
rubygems_version: 3.4.19
|
94
95
|
signing_key:
|
95
96
|
specification_version: 4
|
96
97
|
summary: TUI mozconfig switcher
|