User Tools

Site Tools


t3dd23
→ Slide 1

TYPO3 Project setup

→ Slide 2

What do we need❓

  • LAMP stack including configuration and services (e.g. solr)
  • Package-Manager
  • Site package
  • QA Tools / Analyzer
  • Versioning
  • Bundler
  • Tests (unit, functional, acceptance)
  • Continous integration

→ Slide 3

LAMP stack

To run the website we need a webserver, a database and PHP.

Either set this up all yourself or you can use DDEV:

  • Easy to set up
  • Share configuration with your team using VCS
  • Flexible configuration
  • Integrate services (e.g. solr)

→ Slide 4

Package-Manager / Dependency Manager

To get third party dependencies in place:

  • PHP - Composer, the one and only
  • Node - NPM, yarn will do the job as well

→ Slide 5

Site package

The place where your website will life in.

It contains all the code that makes up the website.

→ Slide 6

QA Tools / Analyzer

Tools to enfore coding standards and prevent bugs might come in handy improving the code.

  • PHPStan* - Find bugs before they reach production
  • PHP CS Fixer* - Apply coding standards
  • EditorConfig* - helps maintain consistent coding styles

* used by the TYPO3 Core

→ Slide 7

Versioning

Using a version control system it makes it easier to understand what,

when and why a change was done to the code.

  • Git
  • Subversion
  • Mercurial
  • ...

Most likely Git due to adoption in GitHub/GitLab.

It is rare to see the others out in the wild these days.

→ Slide 8

Bundler

Pack up and process SCSS, Javascript files and more to be ready for the browser.

There are many different bundlers around like gulp, grunt, webpack, vite.

Nowadays, i prefer to use vite because of its simple configuration and speed.

→ Slide 9

Tests (unit, functional, acceptance)

Tests are always good practice. It will ensure that the changed code is still working.

  • Unit/functional tests - PHPUnit*
  • Acceptance tests - Codeception*, Cypress

* used by the TYPO3 Core

→ Slide 10

Continous integration

On every change in the codebase a pipeline should run to execute the QA tool, bundle and testing.

Finally, ship your code.

  • CI Tools: GitHub Actions, GitLab (Runner)
  • Ship code: TYPO3 Surf, Deployer or a plain bash script if you prefer
→ Slide 11

Wait wait wait ....

… we have a gazillion of tools to install and configure ⁉️

→ Slide 12

There is a solution

… for GitLab users.

The GitLab Project Template for TYPO3

Let me show you …

https://gitlab.com/projects/new

→ Slide 13

Summary

Wanted Available and preconfigured in the Template
LAMP ✅ DDEV
Package-Manager ✅ Composer, NPM
Site package
QA Tools / Analyzer ✅ PHPStan, PHP-CS-Fixer
Versioning ✅ Git
Bundler ✅ ViteJS
Tests (unit, functional, acceptance)
Continous integration ⚠️ GitLab Runner + deployer (needs additional configuration)
→ Slide 14

Contribute

Project (maintained by GitLab):

https://gitlab.com/gitlab-org/project-templates/typo3-distribution/

Workflow:

  • Fork project
  • 🚀 do awesome stuff 🚀
  • Open a merge request and give a detailed description
  • Request a reviewer: @gitlab-bot ready
  • 🥁 Wait for it to get merged
  • Create an issue: https://gitlab.com/gitlab-org/gitlab/
    • ⚠️ Try to keep changes small

→ Slide 15

Merge Request example

Task: Update template zip archive

Stats: 25 participants, 3 approvers, 11 labels

https://gitlab.com/gitlab-org/gitlab/-/merge_requests/125094

→ Slide 16

Thanks for listening

Inspiring People To Share

Everyone can contribute

t3dd23.txt · Last modified: 2023/08/04 17:27 by admin