static IList <string> ParseTextScript(string resource) { using var stream = EmbeddedStream.For(resource); using var reader = new StreamReader(stream); return(reader.ReadToEnd().Replace("\r", "").Split("---\n") .Select(text => text.TrimEnd('\n')) .Where(text => text != string.Empty) .ToList()); }
static YamlElement ParseYamlScripts(string resource) { using var stream = EmbeddedStream.For(resource); using var reader = new StreamReader(stream); return(YamlStream.Load(reader).First().Contents); }