sy / project
Project template
Installs: 37
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 1
Language:HTML
Type:project
Requires
- sy/bootstrap: *
Requires (Dev)
- sy/coding-standard: *
- sy/flyway: *
- sy/genini: *
- dev-main
- 6.4.4
- 6.4.3
- 6.4.2
- 6.4.1
- 6.4.0
- 6.3.1
- 6.3.0
- 6.2.1
- 6.2.0
- 6.1.4
- 6.1.3
- 6.1.2
- 6.1.1
- 6.1.0
- 6.0.0
- 5.5.6
- 5.5.5
- 5.5.4
- 5.5.3
- 5.5.2
- 5.5.1
- 5.5.0
- 5.4.1
- 5.4.0
- 5.3.0
- 5.2.6
- 5.2.5
- 5.2.4
- 5.2.3
- 5.2.2
- 5.2.1
- 5.2.0
- 5.1.0
- 5.0.0
- 4.8.0
- 4.7.3
- 4.7.2
- 4.7.1
- 4.7.0
- 4.6.6
- 4.6.5
- 4.6.4
- 4.6.3
- 4.6.2
- 4.6.1
- 4.6.0
- 4.5.0
- 4.4.1
- 4.4.0
- 4.3.0
- 4.2.2
- 4.2.1
- 4.2.0
- 4.1.3
- 4.1.2
- 4.1.1
- 4.1.0
- 4.0.0
- 3.5.1
- 3.5.0
- 3.4.0
- 3.3.0
- 3.2.1
- 3.2.0
- 3.1.1
- 3.1.0
- 3.0.1
- 3.0.0
- 2.3.0
- 2.2.0
- 2.1.1
- 2.1.0
- 2.0.5
- 2.0.4
- 2.0.3
- 2.0.2
- 2.0.1
- 2.0.0
- 1.1.1
- 1.1.0
- 1.0.7
- 1.0.6
- 1.0.5
- 1.0.4
- 1.0.3
- 1.0.2
- 1.0.1
- 1.0.0
- 0.0.1
- dev-develop
This package is auto-updated.
Last update: 2024-12-14 22:24:15 UTC
README
A skeleton to start a new website. Build with sy/bootstrap
Requirements
- Docker
Installation
Start a new project with
composer create-project sy/project [DIRECTORY]
Create configuration files
A command line interface will guide you for generating these configuration files when you create a new project.
Create the file [DOCUMENT ROOT]/protected/conf/database.ini
Example:
host = localhost
port = 3306
dbname = mydatabase
username = myuser
password = mypassword
charset = utf8mb4
Create the file [DOCUMENT ROOT]/protected/conf/smtp.ini
Example:
host = smtp.gmail.com
username = user@example.com
password = mypassword
port = 587
encryption = tls
Create database
When a new project is created, the database is created with this SQL script: protected/sql/V1__init.sql
We use Flyway to manage database changes. Here is the composer custom command:
composer db [FLYWAY COMMAND]
Flyway commands:
- migrate
- info
- repair
- clean
- validate
- baseline
Example:
composer db migrate
Build CSS & JS
We have a composer custom command for building CSS and JS assets:
composer build
But it's recommended to install NodeJS and Gulp if you have to rebuild frequently the CSS or JS.
Go to the project folder and install project dependencies
npm install
To build css (protected/scss/app.scss
-> assets/css/app.css
)
gulp css
To build js (protected/js/*.js
-> assets/js/app.js
)
gulp js
Check/format PHP coding style
Check the coding style
composer check [FILE or DIRECTORY]
Format the coding style
composer format [FILE or DIRECTORY]
Example:
composer format protected/src
Coding standard ruleset used: sy/coding-standard