Problem/Motivation
Core has three overall stages in gitlab pipelines: Build, Lint and Test.
The build stage consists of two jobs - composer and yarn, which exist only to build caches for later stages.
However, composer install and yarn install a very fast, maybe 10 seconds or so on gitlab, while downloading an image and running a job in total is at least 45s-1m.
If we flatten the build and yarn jobs, and have the lint jobs do their own yarn and composer installs, then we only add 5-10 seconds to each lint job, but we save a full minute by running the build and lint jobs in parallel.
This should save approximately one minute per gitlab pipeline in walltime, at the cost of maybe 50s CPU times.
However we could also go further by removing the composer and yarn jobs entirely, e.g. use the phpcs job to build the composer cache, and use the cspell job to build the yarn cache for later jobs.