Skip to content

Commit

Permalink
README update
Browse files Browse the repository at this point in the history
  • Loading branch information
hanoii committed Mar 28, 2024
1 parent a30de1a commit bf6a0e4
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
<!-- toc -->

- [What is ddev-pimp-my-shell?](#what-is-ddev-pimp-my-shell)
- [ddev `post-import-db` hook](#ddev-post-import-db-hook)

<!-- tocstop -->

Expand All @@ -24,4 +25,25 @@ defaults.
- https://starship.rs/
- https://github.com/charmbracelet/gum

It also has:

- Some useful [scripts](pimp-my-shell/scripts)

## ddev `post-import-db` hook

I generally have import scripts that I ship either from other add-ons or
specific to projects and those scripts usually download the database from within
the container. Rather than downloading the database and then running
`ddev import-db --file=` I wanted to provide a way so that either way runs all
of my post-import-db commands both with the ddev import command as well as from
any helper script from within the project.

So the way this works is that you can run
`/var/www/html/.ddev/pimp-my-shell/hooks/post-import-db.sh` from any script that
will be run in the container and it will take care of running all scripts on
`.ddev/pimp-my-shell/post-import-db.d/`.

This also allows for other add-ons to add scripts to this directory so that they
will be run.

**Contributed and maintained by [@hanoii](https://github.com/hanoii)**

0 comments on commit bf6a0e4

Please sign in to comment.