diff --git a/_plugins/bidirectional_links_generator.rb b/_plugins/bidirectional_links_generator.rb index 68ab780..e0fee75 100644 --- a/_plugins/bidirectional_links_generator.rb +++ b/_plugins/bidirectional_links_generator.rb @@ -52,8 +52,8 @@ class BidirectionalLinksGenerator < Jekyll::Generator # links by greying them out and changing the cursor current_note.content = current_note.content.gsub( /\[\[(.*)\]\]/i, # match on the remaining double-bracket links - <<~HTML.chomp # replace with this HTML (\\1 is what was inside the brackets) - + <<~HTML.chomp # replace with this HTML (\\1 is what was inside the brackets) + [[ \\1 ]] @@ -63,7 +63,7 @@ class BidirectionalLinksGenerator < Jekyll::Generator # Identify note backlinks and add them to each note all_notes.each do |current_note| - # Nodes: Jekyll + # Nodes: Jekyll notes_linking_to_current_note = all_notes.filter do |e| e.content.include?(current_note.url) end @@ -75,7 +75,7 @@ class BidirectionalLinksGenerator < Jekyll::Generator label: current_note.data['title'], } unless current_note.path.include?('_notes/index.html') - # Edges: Jekyll + # Edges: Jekyll current_note.data['backlinks'] = notes_linking_to_current_note # Edges: Graph