#!/usr/bin/env bash

set -e

. ${0%/*}/_functions.sh

if [ "$MODE" = "free" ]; then
    ok "* removing files to free version"

    rm -Rf "/opt/admin/config/services_pro.yaml"
    sed -zi 's/# <PRO>.*# <\/PRO>//g' "/opt/admin/config/services.yaml"
    sed -zi 's/# <PRO>.*# <\/PRO>//g' "/opt/admin/config/packages/doctrine.yaml"
    sed -zi 's/# <PRO>.*# <\/PRO>//g' "/opt/admin/config/routes/annotations.yaml"
fi
