Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve override examples #5440

Merged
merged 2 commits into from
Jul 11, 2021
Merged

Improve override examples #5440

merged 2 commits into from
Jul 11, 2021

Conversation

flack
Copy link
Contributor

@flack flack commented Jul 3, 2021

See discussion in #5439

I'm pretty sure that the typical use case for folder-level overrides is to exclude an entire subtree, not just the files directly in this folder (I mean, who would have a documentation or vendor folder and then inside of it a subfolder with regular code?). So I've changed the examples to cover this typical use case by default

Description

Checklist:

  • I am associating a language with a new file extension.

  • I am adding a new language.

  • I am fixing a misclassified language

    • I have included a new sample for the misclassified language:
      • Sample source(s):
        • [URL to each sample source, if applicable]
      • Sample license(s):
    • I have included a change to the heuristics to distinguish my language from others using the same extension.
  • I am changing the source of a syntax highlighting grammar

  • I am updating a grammar submodule

  • I am adding new or changing current functionality

    • I have added or updated the tests for the new or changed functionality.
  • I am changing the color associated with a language

    • I have obtained agreement from the wider language community on this color change.
      • [URL to public discussion]
      • [Optional: URL to official branding guidelines for the language]

@flack flack requested a review from a team as a code owner July 3, 2021 09:07
@lildude
Copy link
Member

lildude commented Jul 4, 2021

Copying from #5316 (comment)

As with previous attempts to make this change in #4992 and #4889, you're making assumptions about the developer's intentions and resorting to using the sledgehammer approach. The developer may have intended to only apply to the files in that directory and not recursing. See #4889 (comment) for another discussion on this.

Ultimately, this is really about understanding the git documentation and the developer's end goals, and not making any assumptions, which are outside the scope of using Linguist.

docs/overrides.md Outdated Show resolved Hide resolved
docs/overrides.md Outdated Show resolved Hide resolved
@flack
Copy link
Contributor Author

flack commented Jul 5, 2021

@lildude sure, more examples can never hurt. do you want me to update this PR or are you going to commit this separately? If I should make the change: Should I add a second commit or just force-push?

@lildude
Copy link
Member

lildude commented Jul 5, 2021

You should be able to merge my suggestions from the UI. Don’t worry about the history as we squash all commits when merging.

Co-authored-by: Colin Seymour <colin@github.com>
@flack
Copy link
Contributor Author

flack commented Jul 5, 2021

@lildude done

Copy link
Member

@lildude lildude left a comment

Choose a reason for hiding this comment

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

Thanks for taking on my suggestions. I think this will help reduce this kind of confusion without making assumptions and encouraging peeps to blindly swing the old sledgehammer 😄.

@lildude
Copy link
Member

lildude commented Jul 11, 2021

Test failures aren't related and this is only a doc change so I'm gonna merge.

@lildude lildude merged commit 0c7f82f into github-linguist:master Jul 11, 2021
@github-linguist github-linguist locked as resolved and limited conversation to collaborators Jun 17, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants