Merge branch 'main' into cours
Some checks are pending
ci/woodpecker/push/publish Pipeline is pending
Some checks are pending
ci/woodpecker/push/publish Pipeline is pending
This commit is contained in:
commit
5009626ef3
2 changed files with 2 additions and 1 deletions
|
@ -212,7 +212,7 @@ pub fn read_file(filename: &str, expected_file: TypeFileMetadata) -> Option<File
|
|||
|
||||
/// Deserialize metadata based on a type
|
||||
fn deserialize_metadata<T: Default + serde::de::DeserializeOwned>(text: &str) -> T {
|
||||
serde_yaml::from_str(text.trim_matches(&['-', '\n'] as &[_])).unwrap_or_default()
|
||||
serde_yaml::from_str(text.trim().trim_matches(&['-'] as &[_])).unwrap_or_default()
|
||||
}
|
||||
|
||||
/// Fetch metadata from AST
|
||||
|
|
|
@ -9,6 +9,7 @@ window.addEventListener("load", () => {
|
|||
/* Aliases of langs */
|
||||
const aliases = {
|
||||
bash: ["fish"],
|
||||
pascal: ["pseudocode"],
|
||||
};
|
||||
for (const lang in aliases) {
|
||||
hljs.registerAliases(aliases[lang], { languageName: lang });
|
||||
|
|
Loading…
Reference in a new issue