CraftQuest Casual 08

Ryan is back for the next installment of CraftQuest Casual. He builds on a recent video on extending DDEV using a custom command.

Streamed on July 31, 2025

Craft 5

DDEV

This com­mand will be called lp (for launch project”) and launch mul­ti­ple URLS at once. For our usage, this will mean launch­ing both the CP and front-end of the site. That’ll be nice!

A lot of it is sim­i­lar to what I built in the video on DDEV cus­tom com­mands but with one twist: we need to have an array of URLs to iter­ate over and then launch each URL in the array.

When we loop over the URLS, we see this syn­tax: "${URLS[@]}"

This is an array expan­sion syn­tax in Shell Script where: 

  1. URLS is the name of an array vari­able we set ear­li­er in the script,
  2. [@] is an array sub­script that means expand to all ele­ments of the array”,
  3. the ${...} syn­tax is used for para­me­ter expansion,
  4. and the dou­ble quotes "..." around the expan­sion pre­vent word split­ting and pre­serve spaces in array elements.

Some stuff to help you along during the lesson: