Skip to content

Instantly share code, notes, and snippets.

@andrewnicols
Last active February 14, 2021 04:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save andrewnicols/c7cfba419b7bc486ea60ae80caad1f7c to your computer and use it in GitHub Desktop.
Save andrewnicols/c7cfba419b7bc486ea60ae80caad1f7c to your computer and use it in GitHub Desktop.
#!/bin/bash
grep 'moodle-browser-config' config.php > /dev/null
if [ $? -ne 0 ]
then
echo Adding browsers
gsed -i '/^\$CFG->wwwroot.*=.*$/ a require_once(dirname(dirname(__DIR__)) . "\/moodle-browser-config/init.php");' config.php
else
echo Behat browser defitions already there
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment