Skip to content

Commit

Permalink
Add asciinema and autocast in our DDEV (#5817)
Browse files Browse the repository at this point in the history
For future use in making screencasts for commands
  • Loading branch information
weitzman authored Nov 23, 2023
1 parent 8245ace commit e0e50b7
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 1 deletion.
1 change: 1 addition & 0 deletions .ddev/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,4 @@ web_environment:
# - "UNISH_DB_URL=sqlite://:memory:"
# - UNISH_DB_URL=pgsql://db:db@db:5432
- DRUSH_OPTIONS_URI=$DDEV_PRIMARY_URL
- EDITOR=nano
14 changes: 14 additions & 0 deletions .ddev/web-build/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
ARG BASE_IMAGE
FROM $BASE_IMAGE

# https://asciinema.org/docs/installation
RUN pip3 install asciinema

# Install Autocast https://github.com/k9withabone/autocast/tree/main#installation
# https://stackoverflow.com/questions/67092242/how-can-i-add-to-the-path-in-the-ddev-web-container-for-drush-for-example
RUN echo 'export PATH="$PATH:$HOME/.cargo/bin"' >/etc/bashrc/commandline-addons.bashrc
# https://ddev.readthedocs.io/en/latest/users/extend/customizing-images/#adding-extra-dockerfiles-for-webimage-and-dbimage
USER $uid
RUN curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
RUN cargo-binstall --no-confirm autocast
USER root
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@
"mk:docs": "./drush --uri=dev -v mk:docs",
"rector": "rector process",
"sut": "./drush --uri=dev",
"sut:si": "./drush --uri=dev site:install testing --sites-subdir=dev --db-url=${UNISH_DB_URL:-mysql://root:password@mariadb}/unish_dev -v",
"sut:si": "./drush --uri=dev site:install ${INSTALL_PROFILE:-testing} --sites-subdir=dev --db-url=${UNISH_DB_URL:-mysql://root:password@mariadb}/unish_dev -v",
"phpunit": "php -d sendmail_path='true' vendor/bin/phpunit --colors=always --testdox --configuration tests",
"unit": "composer phpunit -- --testsuite unit",
"integration": "composer phpunit -- --testsuite integration",
Expand Down

0 comments on commit e0e50b7

Please sign in to comment.