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

lexer: Accept hyphen and numbers #7

Merged
merged 1 commit into from
Aug 7, 2019
Merged

Conversation

sktornado
Copy link

Some config names include hyphens and numbers. The wireless config
is one such example.
https://openwrt.org/docs/guide-user/network/wifi/basic

Some config names include hyphens and numbers. The wireless config
is one such example.
https://openwrt.org/docs/guide-user/network/wifi/basic
@dmke dmke self-assigned this Aug 6, 2019
@dmke dmke added the feature New feature or request label Aug 6, 2019
@dmke
Copy link
Member

dmke commented Aug 6, 2019

Cool 👍 I'll merge this tomorrow when I'm at my workstation again (and when I've found out why CircleCI doesn't build pull requests...)

@codecov-io
Copy link

codecov-io commented Aug 7, 2019

Codecov Report

Merging #7 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master       #7   +/-   ##
=======================================
  Coverage   68.05%   68.05%           
=======================================
  Files           7        7           
  Lines         695      695           
=======================================
  Hits          473      473           
  Misses        202      202           
  Partials       20       20
Impacted Files Coverage Δ
lexer.go 89.5% <100%> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 114c1e9...baf62a6. Read the comment docs.

@dmke dmke merged commit baf62a6 into digineo:master Aug 7, 2019
@dmke
Copy link
Member

dmke commented Aug 7, 2019

I've merged your changes, thank you.

The wiki states on https://openwrt.org/docs/guide-user/base-system/uci#file_syntax (at the end of the "File Syntax" section):

It is important to know that UCI identifiers and config file names may contain only the characters a-z, 0-9 and _. E.g. no hyphens (-) are allowed. Option values may contain any character (as long they are properly quoted).

So, this leaves me a bit puzzled... Are hypens allowed or are they not? I've glanced a bit over the C sources I did not see an obvious parser function which could tell me the actual syntax allowed.

Do you have time to dig a bit deeper? I don't know when I'm able to to this myself.

@dmke dmke mentioned this pull request Aug 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants