A set of custom DDEV commands I use regularly.
I want to use stow to manage these, so I can store just my custom commands in the git repo and they get symlinked to DDEV.
stow --target=$HOME/.ddev/commands .
Warning
Unfortunately that isn't currently supported, so for now I have to use hard links. I've written a script to handle that for me.
The script first deletes all old hard links in $HOME/.ddev/commands
, then creates new hard links from any files not in the .links-ignore
list.
Finally it creates a symlink for the .php-utils/
directory since that doesn't get copied anywhere.
./make-links.sh
-
clone the repo somewhere
-
run the above command to make the links
-
run composer install in
.php-utils/
cd .php-utils composer install
-
create a
/.php-utils/config.yml
file:# Path that projects created with `ddev create` will live in projects_path: "~/projects" # Path that `ddev clone` will clone into clone_dir: "~/dump/temp" # Token used for github API when fetching PR info github_token: "YOUR_TOKEN_HERE" # Token shared with Composer (e.g. when installing forks) composer_token: "YOUR_TOKEN_HERE"
-
enjoy.
Note
You may need to run ddev start
or ddev debug fix-commands
on any projects that were already running.