Skip to content

Classify .gs, .css and dotfile configs instead of skipping them #2698

Open

Description

@Domuspi

Feature request: classify .gs, .css and dotfile configs instead of skipping them

Repo: https://github.com/Graphify-Labs/graphify
Version: graphifyy 0.9.41

Summary

graphify extract silently drops several file types as "not classified (no supported
extension or shebang)"
. Two of them hold real, graph-worthy content, and one of them is
often the single most security-relevant file in a web project.

Full (non---code-only) extraction on a small PHP/JS web project printed:

[graphify extract] 7 file(s) not classified (no supported extension or shebang), skipped:
  .gitattributes, .gitignore, .htaccess, formatar-planilha.gs,
  planilha-conferencia.gs, planilha-custos-backup-2026-08-10.tsv (+1 more)

Switching between --code-only and full semantic extraction makes no difference — these
are dropped before classification in both modes.

Why each one matters

1. .gs — Google Apps Script (highest impact)

.gs is JavaScript. Google Apps Script is the automation layer behind Google Sheets,
Docs and Forms, so .gs files routinely contain the business logic that drives a
spreadsheet-backed workflow.

Measured in one project:

File Size Lines function declarations
docs/formatar-planilha.gs 9,177 B 239 13
docs/planilha-conferencia.gs 11,432 B 272 8

That is 21 functions across 511 lines of JavaScript that produce zero nodes. Symbols
like formatarPlanilha, garantirRotulos_, estilizarCabecalhos_ never enter the graph,
so the spreadsheet automation is invisible to query, path and affected.

The existing JavaScript tree-sitter grammar should parse .gs as-is. This looks like a
one-line extension-map addition rather than new parser work.

2. .htaccess — Apache config

In shared-hosting deployments .htaccess is the access-control boundary. In the project
above it is a 118-line allowlist that decides which paths are reachable from the
public internet — including the rule that keeps graphify-out/ itself unreachable.

An architecture graph that omits it cannot answer "what is actually exposed?". Even
treating it as a document (no AST, just semantic extraction) would be a large
improvement over dropping it.

Note it is also a dotfile with no extension, so extension-based classification misses it
by construction.

3. .css — stylesheets

css/styles.css, 26,679 bytes over 1,109 lines, produces zero nodes. Less critical than
the two above (no call graph to extract), but for a frontend project the stylesheet is a
first-class artifact, and .scss/.less presumably have the same gap.

Suggested behaviour

  1. Map .gs to the existing JavaScript parser (smallest change, biggest win).
  2. Allow well-known extensionless config files (.htaccess, Dockerfile, Procfile,
    Makefile) to be classified by filename, not just extension — as documents if no
    grammar exists.
  3. Treat .css/.scss/.less as documents at minimum, so they appear as file-level
    nodes and can carry edges.

Smaller point: make the skip louder

The current message lists the first five names and then (+1 more), at info level, in the
middle of a long run. It is easy to miss that a whole category of source was excluded.
Consider printing the count per extension, e.g.:

skipped 7 unclassified file(s): .gs (2), dotfiles (3), .tsv (1), .css (1)

so the omission is legible at a glance.

Related

The ThinkingBlock crash is filed separately — see issue-upstream-thinkingblock.md.
These are independent; this one is a feature request, that one is a hard crash.

Activity

  1. nothariharan commented on Oct 9, 2026

    @nothariharan
    Contributor

    Fixed by #4263, which supersedes the .gs PRs #2747 and #3505.

    See #4263.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions