Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Feature: Add support for .gitignore parsing and system file whitelisting

Open
#88 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Quiet
Tech stack
git, php
Domain
tooling

Research direction

Start by tracing the push scan and checkout/seed flow described in the issue, then inspect how repository files are currently selected and exported. Verify behavior against the listed acceptance criteria: nested .gitignore patterns and negations exclude matching files, while .gitignore, AGENTS.md, and CLAUDE.md remain preserved; confirm the rules also survive checkout/seed.

Written by the indexing model from the issue text.

Description

Summary

I was trying to use Obsidian to edit Markdown files, and faced a problem to sync the Obsidian vault .obsidian.. Because it does not exist on the server. While one could use the Gutenberg Guidelines structure for brand voice and other items, it would be useful to allow people to keep other files in their checked out repos and only push what Push MD supports.

Since Push MD does not have a .gitignore, this can cause ignored build artifacts or temporary files to be scanned and pushed into WordPress - and the whole push to fail.

The proposal:

Push MD checkout repositories can contain .gitignore file. And the rules here will specifically check for file paths Push MD needs, and ignore everything else.

This can also address potential issues when people have multi remote setup - one from local to their own "staging" or "pre-approval" Git server, and from there to live WordPress site.

Features & How This Should Work
  1. .gitignore Pattern Parser:

    • Interpret root and sub-folder .gitignore files during push scan.
    • Support standard pattern syntax: wildcards (*), directory prefixes (/), comments (#), trailing slashes, and negations (!).
  2. System File Whitelist Policy:

    • System configuration files (.gitignore, AGENTS.md, CLAUDE.md) should be explicitly whitelisted so they are preserved and never ignored, even if broad rules (like .* or *.md) exist in .gitignore.
    • Support for posts, pages and other artifacts in a way that support for custom post types etc in future works too
  3. Seeder Integration:

    • Export .gitignore during checkout/seed so workspace rules remain intact.
Acceptance Criteria
  • .gitignore patterns correctly exclude matching files during push scan.
  • Negation rules (!pattern) work as expected.
  • System files (.gitignore, AGENTS.md, CLAUDE.md - and others) are explicitly whitelisted and never ignored.
Dominant language
PHP
Stars
22
Forks
5
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Automattic/php-toolkit

All issues in Automattic/php-toolkit

Similar issues

More PHP issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.