Skip to content
This repository has been archived by the owner on Oct 7, 2022. It is now read-only.

Add pattern filter to yml and check for valid links w/o opening files #72

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

kaankabalak
Copy link
Collaborator

  • This commit adds a Rules field to the .yml file, and a Filter field
    under it to exclude unwanted patterns from the markdown content
    fetched from Github.
  • This commit also checks if the links are valid or not without opening
    the file. This change was done to improve performance by preventing the
    'reveal' method from running for each document while the sidebar is
    being generated.
  • When the first link in the list of Documents is broken, to avoid the
    wrong link to be highlighted on index.html, Gluegun now returns an error
    while generating the index page and asks the user to correct it.

- This commit adds a Rules field to the .yml file, and a Filter field
under it to exclude unwanted patterns from the markdown content
fetched from Github.
- This commit also checks if the links are valid or not without opening
the file. This change was done to improve performance by preventing the
'reveal' method from running for each document while the sidebar is
being generated.
- When the first link in the list of Documents is broken, to avoid the
wrong link to be highlighted on index.html, Gluegun now returns an error
while generating the index page and asks the user to correct it.
@deekoder deekoder self-requested a review April 24, 2018 17:08
@@ -171,6 +182,40 @@ def self.get_github_link(link)
return link
end

def self.is_link_valid(link)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can also use a gem to do this. Or do it ourselves.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants