.gitignore pour Prestashop

135 règles d’exclusion pour Prestashop, prêtes à copier dans votre dépôt.

Gitignore patterns for Prestashop

Le .gitignore complet pour Prestashop

# Generated by LFGitignore - https://lfgitignore.com
# Created: 2026-03-26 09:35:53 UTC
# Technologies: Prestashop

### Prestashop ###
/.htaccess
# Log file
*.log
/cache/*
!/cache/.htaccess
!/cache/cachefs/index.php
!/cache/deprecated.txt
!/cache/index.php
!/cache/purifier/index.php
!/cache/push/activity
!/cache/push/index.php
!/cache/push/trends
!/cache/sandbox/index.php
!/cache/smarty/cache/index.php
!/cache/smarty/compile/index.php
!/cache/smarty/index.php
!/cache/tcpdf/index.php
/download/*
!/download/.htaccess
!/download/index.php
/img/*
!/img/.htaccess
!/img/index.php
!/img/404.gif
!/img/bg_500.png
!/img/bg_loader.png
!/img/favicon.ico
!/img/loader.gif
!/img/loadingAnimation.gif
!/img/logo.jpg
!/img/logo.png
!/img/logo_invoice.jpg
!/img/logo_stores.png
!/img/macFFBgHack.png
!/img/prestashop-avatar.png
!/img/prestashop@2x.png
!/img/preston-login-wink@2x.png
!/img/preston-login@2x.png
!/img/questionmark.png
!/img/genders/index.php
!/img/admin/index.php
!/img/c/index.php
!/img/cms/index.php
!/img/co/index.php
!/img/jquery-ui
!/img/l/index.php
!/img/m/index.php
!/img/os/index.php
!/img/p/index.php
!/img/s/index.php
!/img/scenes
!/img/st/index.php
!/img/su/index.php
!/img/t/index.php
!/img/tmp/index.php
/upload/*
!/upload/.htaccess
/vendor/*
/docs/phpdoc-sf/
/composer.lock
*.hot-update.js
*.hot-update.json
/admin-dev/autoupgrade/*
!/admin-dev/autoupgrade/index.php
!/admin-dev/autoupgrade/backup/index.php
/admin-dev/backups/*
!/admin-dev/backups/.htaccess
/admin-dev/import/*
!/admin-dev/import/.htaccess
!/admin-dev/import/index.php
/admin-dev/export/*
!/admin-dev/export/.htaccess
!/admin-dev/export/index.php
/admin-dev/themes/default/css/bundle/default_rtl.css
/admin-dev/themes/default/css/bundle/shared_rtl.css
/admin-dev/themes/default/css/font_rtl.css
/admin-dev/themes/default/css/overrides_rtl.css
/admin-dev/themes/default/css/vendor/font-awesome/font-awesome_rtl.css
/admin-dev/themes/default/css/vendor/nv.d3_rtl.css
/admin-dev/themes/default/css/vendor/titatoggle-min_rtl.css
/admin-dev/themes/default/public/theme_rtl.css
/admin-dev/themes/new-theme/css/module/drop_rtl.css
/admin-dev/themes/new-theme/css/right-sidebar_rtl.css
themes/*/cache/*
config/settings.inc.php
config/settings.old.php
config/xml/*
config/themes/*
!config/xml/themes/default.xml
themes/*/config/settings_*.json
app/config/parameters.old.yml
app/config/config.php
modules/*
override/*
themes/*/
!themes/classic
!themes/_core
!themes/_libraries
bower_components/
# Node.js dependencies
node_modules/
composer.phar
php-cs-fixer
.grunt/*
translations/*
mails/*
!mails/themes/
!mails/_partials/
themes/default-bootstrap/lang/*
themes/default-bootstrap/modules/*/translations/*.php
themes/default-bootstrap/mails/*
!themes/default-bootstrap/mails/en/
themes/default-bootstrap/modules/*/mails/*
!themes/default-bootstrap/modules/*/mails/en
*sitemap.xml
/robots.txt
/bin/
/app/Resources/geoip/GeoLite2-City.mmdb
/app/Resources/translations/*
!/app/Resources/translations/default
/app/config/parameters.yml
/app/config/parameters.php
/build/
/phpunit.xml
/var/*
!/var/cache
/var/cache/*
!var/cache/.gitkeep
!/var/logs
/var/logs/*
!var/logs/.gitkeep
!/var/sessions
/var/sessions/*
!var/sessions/.gitkeep
!var/SymfonyRequirements.php
/vendor/
/web/bundles/

Ce que ces règles Prestashop ignorent vraiment

Chaque motif ci-dessous, et pourquoi il a sa place dans votre .gitignore.

Cache, temp and personal files

Motif Ce qu’il ignore
/.htaccess Cache, temp and personal files
*.log Log file

Cache

Motif Ce qu’il ignore
/cache/* Cache
!/cache/.htaccess Cache
!/cache/cachefs/index.php Cache
!/cache/deprecated.txt Cache
!/cache/index.php Cache
!/cache/purifier/index.php Cache
!/cache/push/activity Cache
!/cache/push/index.php Cache
!/cache/push/trends Cache
!/cache/sandbox/index.php Cache
!/cache/smarty/cache/index.php Cache
!/cache/smarty/compile/index.php Cache
!/cache/smarty/index.php Cache
!/cache/tcpdf/index.php Cache

Download

Motif Ce qu’il ignore
/download/* Download
!/download/.htaccess Download
!/download/index.php Download

Images

Motif Ce qu’il ignore
/img/* Images
!/img/.htaccess Images
!/img/index.php Images
!/img/404.gif Images
!/img/bg_500.png Images
!/img/bg_loader.png Images
!/img/favicon.ico Images
!/img/loader.gif Images
!/img/loadingAnimation.gif Images
!/img/logo.jpg Images
!/img/logo.png Images
!/img/logo_invoice.jpg Images
!/img/logo_stores.png Images
!/img/macFFBgHack.png Images
!/img/prestashop-avatar.png Images
!/img/prestashop@2x.png Images
!/img/preston-login-wink@2x.png Images
!/img/preston-login@2x.png Images
!/img/questionmark.png Images
!/img/genders/index.php Images
!/img/admin/index.php Images
!/img/c/index.php Images
!/img/cms/index.php Images
!/img/co/index.php Images
!/img/jquery-ui Images
!/img/l/index.php Images
!/img/m/index.php Images
!/img/os/index.php Images
!/img/p/index.php Images
!/img/s/index.php Images
!/img/scenes Images
!/img/st/index.php Images
!/img/su/index.php Images
!/img/t/index.php Images
!/img/tmp/index.php Images

Upload

Motif Ce qu’il ignore
/upload/* Upload
!/upload/.htaccess Upload
/vendor/* Upload
/docs/phpdoc-sf/ Upload
/composer.lock Upload
*.hot-update.js Upload
*.hot-update.json Upload
/admin-dev/autoupgrade/* Upload
!/admin-dev/autoupgrade/index.php Upload
!/admin-dev/autoupgrade/backup/index.php Upload
/admin-dev/backups/* Upload
!/admin-dev/backups/.htaccess Upload
/admin-dev/import/* Upload
!/admin-dev/import/.htaccess Upload
!/admin-dev/import/index.php Upload
/admin-dev/export/* Upload
!/admin-dev/export/.htaccess Upload
!/admin-dev/export/index.php Upload

Downloaded RTL files

Motif Ce qu’il ignore
/admin-dev/themes/default/css/bundle/default_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/bundle/shared_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/font_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/overrides_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/vendor/font-awesome/font-awesome_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/vendor/nv.d3_rtl.css Downloaded RTL files
/admin-dev/themes/default/css/vendor/titatoggle-min_rtl.css Downloaded RTL files
/admin-dev/themes/default/public/theme_rtl.css Downloaded RTL files
/admin-dev/themes/new-theme/css/module/drop_rtl.css Downloaded RTL files
/admin-dev/themes/new-theme/css/right-sidebar_rtl.css Downloaded RTL files
themes/*/cache/* Downloaded RTL files

Config

Motif Ce qu’il ignore
config/settings.inc.php Config
config/settings.old.php Config
config/xml/* Config
config/themes/* Config
!config/xml/themes/default.xml Config
themes/*/config/settings_*.json Config
app/config/parameters.old.yml Config
app/config/config.php Config

Themes, modules and overrides

Motif Ce qu’il ignore
modules/* Themes, modules and overrides
override/* Themes, modules and overrides
themes/*/ Themes, modules and overrides
!themes/classic Themes, modules and overrides
!themes/_core Themes, modules and overrides
!themes/_libraries Themes, modules and overrides

Vendors and dependencies

Motif Ce qu’il ignore
bower_components/ Vendors and dependencies
node_modules/ Node.js dependencies
composer.phar Vendors and dependencies
php-cs-fixer Vendors and dependencies
.grunt/* Vendors and dependencies

Translations and emails templates

Motif Ce qu’il ignore
translations/* Translations and emails templates
mails/* Translations and emails templates
!mails/themes/ Translations and emails templates
!mails/_partials/ Translations and emails templates
themes/default-bootstrap/lang/* Translations and emails templates
themes/default-bootstrap/modules/*/translations/*.php Translations and emails templates
themes/default-bootstrap/mails/* Translations and emails templates
!themes/default-bootstrap/mails/en/ Translations and emails templates
themes/default-bootstrap/modules/*/mails/* Translations and emails templates
!themes/default-bootstrap/modules/*/mails/en Translations and emails templates

MISC

Motif Ce qu’il ignore
*sitemap.xml MISC
/robots.txt MISC

Symfony

Motif Ce qu’il ignore
/bin/ Symfony
/app/Resources/geoip/GeoLite2-City.mmdb Symfony
/app/Resources/translations/* Symfony
!/app/Resources/translations/default Symfony
/app/config/parameters.yml Symfony
/app/config/parameters.php Symfony
/build/ Symfony
/phpunit.xml Symfony
/var/* Symfony
!/var/cache Symfony
/var/cache/* Symfony
!var/cache/.gitkeep Symfony
!/var/logs Symfony
/var/logs/* Symfony
!var/logs/.gitkeep Symfony
!/var/sessions Symfony
/var/sessions/* Symfony
!var/sessions/.gitkeep Symfony
!var/SymfonyRequirements.php Symfony
/vendor/ Symfony
/web/bundles/ Symfony

Comment utiliser ce .gitignore pour Prestashop

  1. Copiez les règles Prestashop ci-dessus, ou téléchargez directement le fichier.
  2. Créez un fichier nommé .gitignore à la racine de votre dépôt Git et collez-y les règles.
  3. Si certains de ces fichiers sont déjà suivis, lancez git rm -r --cached . puis recommitez — Git n’applique les règles d’exclusion qu’aux fichiers non suivis.
  4. Commitez le .gitignore pour que toute l’équipe partage les mêmes règles.

Autres modèles .gitignore Other

Voir tous les modèles Other