mirror of
https://github.com/nsnail/Ocelot.git
synced 2025-04-23 00:32:50 +08:00
merged develop
This commit is contained in:
commit
2791cef0e0
@ -30,12 +30,12 @@ namespace Ocelot.DependencyInjection
|
||||
|
||||
public static IConfigurationBuilder AddOcelot(this IConfigurationBuilder builder)
|
||||
{
|
||||
const string pattern = "(?i)ocelot(.*).json$";
|
||||
const string pattern = "(?i)ocelot.([a-zA-Z0-9]*).json";
|
||||
|
||||
var reg = new Regex(pattern);
|
||||
|
||||
var files = Directory.GetFiles(".")
|
||||
.Where(path => reg.IsMatch(path)).Where(x => x.Count(s => s == '.') == 3)
|
||||
.Where(path => reg.IsMatch(path))
|
||||
.ToList();
|
||||
|
||||
var fileConfiguration = new FileConfiguration();
|
||||
|
Loading…
x
Reference in New Issue
Block a user