-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
support nested variables on non-primitive JsonNodes (#161)
Variables can now contain other variables in objects and arrays **Sample:** appsettings.json ```json { "foo": "$test:variable" } ``` variables.json ```json { "variable": ["foo", "bar", "$test:someVariable"], "someVariable": "baz" } ``` will result in ```json { "foo": ["foo", "bar", "baz"] } ``` this would also work for nested objects
- Loading branch information
Showing
9 changed files
with
334 additions
and
128 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
...Confix.Tool/src/Confix.Library/Variables/Exceptions/CircularVariableReferenceException.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
namespace Confix.Variables; | ||
|
||
public sealed class CircularVariableReferenceException : Exception | ||
{ | ||
public CircularVariableReferenceException(VariablePath path) | ||
: base($"Variable {path} could not be resolved, due to circular references") | ||
{ | ||
Path = path; | ||
} | ||
|
||
public VariablePath Path { get; } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.