Skip to content
framework18 active rulesVerified 2026-09-30

Cake PHP .gitignore Template

Standard Cake PHP gitignore template from upstream github/gitignore collection. Generated and merged deterministically with upstream GitHub repository patterns to keep your repository clean of package directories, temporary build artifacts, and local environment files.

Interactive Stack Generator

Open in Full Generator
Search for templates
Quick add:
Selected1
Cake PHP
Selected Templates (1)
.gitignore
### Cake PHP ###
# CakePHP 3
/vendor/*
/config/app.php
/tmp/cache/models/*
!/tmp/cache/models/empty
/tmp/cache/persistent/*
!/tmp/cache/persistent/empty
/tmp/cache/views/*
!/tmp/cache/views/empty
/tmp/sessions/*
!/tmp/sessions/empty
/tmp/tests/*
!/tmp/tests/empty
/logs/*
!/logs/empty
# CakePHP 2
/app/tmp/*
/app/Config/core.php
/app/Config/database.php
/vendors/*
18 rules1 template27 lines
Deterministic

Raw Cake PHP .gitignore

Crawlable upstream source template
cakephp.gitignore26 lines
# CakePHP 3
/vendor/*
/config/app.php
/tmp/cache/models/*
!/tmp/cache/models/empty
/tmp/cache/persistent/*
!/tmp/cache/persistent/empty
/tmp/cache/views/*
!/tmp/cache/views/empty
/tmp/sessions/*
!/tmp/sessions/empty
/tmp/tests/*
!/tmp/tests/empty
/logs/*
!/logs/empty
# CakePHP 2
/app/tmp/*
/app/Config/core.php
/app/Config/database.php
/vendors/*

Key Pattern Breakdown

Dependencies & Packages

Excludes installed package directories and third-party vendor files that should be restored via package managers.

/vendor/*/vendors/*

Cache & Temporary Files

Ignores compiler caches, test runner coverage data, and transient temporary scratch files.

/tmp/cache/models/*!/tmp/cache/models/empty/tmp/cache/persistent/*!/tmp/cache/persistent/empty/tmp/cache/views/*!/tmp/cache/views/empty+2 more

Source & Verification

License:: CC0-1.0

Place this file in the root directory of your project as .gitignore. Changes take effect on newly added or untracked files.