Skip to content

./configure --set changelog-seen=2 doesn't work #107049

Closed
@jyn514

Description

@jyn514
; ./configure --set changelog-seen=2
configure: processing command line
configure: 
configure: changelog-seen       := 2
configure: build.configure-args := ['--set', 'changelog-seen=2']
Traceback (most recent call last):
  File "/Users/jyn/src/rust/./src/bootstrap/configure.py", line 465, in <module>
    raise RuntimeError("config key {} not in sections".format(section_key))
RuntimeError: config key changelog-seen not in sections

The problem is that the configure script assumes that all keys are in a section and there are no top-level keys. This forces people to use printf instead:

rust/README.md

Lines 89 to 96 in 37c1d6d

The Rust build system uses a file named `config.toml` in the root of the
source tree to determine various configuration settings for the build.
Set up the defaults intended for distros to get started. You can see a full list of options
in `config.toml.example`.
```sh
printf 'profile = "user" \nchangelog-seen = 2 \n' > config.toml
```

We should make it possible to set top-level keys through configure, both changelog-seen and profile. We should also update the line in the readme linked above to suggest ./configure instead of printf.

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.E-help-wantedCall for participation: Help is requested to fix this issue.E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions