Skip to content

optozorax/anyconfig

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

anyconfig

Parse this text:

# This file provided
# as is

          # Ok?
	 
      
# ok.
[grammar]
S -> P;
# inside comment
P -> "a" { okay = "result"; };
  
[tests]
"a" == { "okay": "result" }
b == {}

to this structure:

vec![
	Config { 
		header: "grammar".to_string(),
		content: "S -> P;\nP -> \"a\" { okay = \"result\"; };\n  \n".to_string(),
	},
	Config { 
		header: "tests".to_string(),
		content: "\"a\" == { \"okay\": \"result\" }\nb == {}\n".to_string(),
	},
];

it just put arbitrary syntax after [header] in string.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages