Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion lib/linguist/generated.rb
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ def generated?
generated_pascal_tlb? ||
generated_sorbet_rbi? ||
generated_mysql_view_definition_format? ||
generated_sqlx_query?
generated_sqlx_query? ||
mise_lock?
end

# Internal: Is the blob an Xcode file?
Expand Down Expand Up @@ -922,6 +923,13 @@ def htmlcov?
!!name.match(/(?:^|\/)htmlcov\//)
end

# Internal: Is the blob a generated mise.lock?
#
# Returns true or false.
def mise_lock?
!!name.match(/mise\.lock/)
end

# Internal: Extract a Hash of name/content pairs from an HTML <meta> tag
def extract_html_meta(match)
(match.last.sub(/\/\Z/, "").strip.scan(/
Expand Down
3 changes: 3 additions & 0 deletions test/test_generated.rb
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,9 @@ def test_check_generated
# Bun lockfile
generated_sample_without_loading_data("JSON/filenames/bun.lock")

# mise lockfile
generated_sample_without_loading_data("TOML/filenames/mise.lock")

# Yarn Plug'n'Play file
generated_sample_without_loading_data(".pnp.js")
generated_sample_without_loading_data(".pnp.cjs")
Expand Down
Loading