Skip to content

Cookiecutter template for new PHP projects.

License

Notifications You must be signed in to change notification settings

jeromegamez/cookiecutter-php

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

133 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cookiecutter PHP

Cookiecutter template to kickstart new PHP projects.

Features

Quickstart

Install Cookiecutter:

$ pip install -U cookiecutter
# Or, on a mac with Homebrew
$ brew install cookiecutter

Generate a new PHP project:

$ cookiecutter gh:jeromegamez/cookiecutter-php

Manual template checks

Use ant to generate test projects locally (non-interactive):

$ ant -f build.xml generate-test-project
$ ant -f build.xml generate-test-project-fixture

Generated output:

  • tests/generated/my-library (from generate-test-project, using defaults from cookiecutter.json)
  • tests/generated/example-tools-library (from generate-test-project-fixture, using explicit fixture values)

Each target cleans tests/generated before generating output.

Demo

asciicast

User config

If you use this (or other) Cookiecutters a lot, you can override the defaults by having a .cookiecutterrc file in your home directory:

default_context:
    full_name: "My full name"
    email: "me@example.com"
    github_username: "mygithubusername"
    github_repository_owner: "mygithubusername-or-org"
abbreviations:
    php: https://github.com/jeromegamez/cookiecutter-php

github_repository_owner defaults to github_username and can be used when the repository lives under an organization while sponsor/funding metadata should still use your personal username.

You can find more information at https://cookiecutter.readthedocs.io/en/latest/advanced/user_config.html

About

Cookiecutter template for new PHP projects.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

 

Packages

No packages published

Contributors 2

  •  
  •