From 1f9552b48e60946f9d276e3a725ed0f83544e080 Mon Sep 17 00:00:00 2001 From: BodgeMaster <> Date: Sun, 23 Feb 2020 20:27:29 +0100 Subject: [PATCH] removed my stupid way of handling variable replacement --- deployment-script.sh | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/deployment-script.sh b/deployment-script.sh index 9086644..20bbdf2 100755 --- a/deployment-script.sh +++ b/deployment-script.sh @@ -1,17 +1,9 @@ -function rewrite_code { - echo "Replacing $1 with $2 in all HTML and PHP files." - echo -e "`find ./ -name '*.html' -or -name '*.php' | sed "s/^/workingfile=\'/;s/\$/\'\; cat \\\$workingfile > .\/tmpdeploymentfile\; cat tmpdeploymentfile | sed \'s#$1#$2#\' > \\\$workingfile/"`\nrm tmpdeploymentfile" | bash - -} - - #!/bin/bash echo "Deployment script for repository \"web-deployment\" `date` ==============================================================================" -rewrite_code %CONTENT_DIR% "\/common\/threadr" -#rewrite_code %ENFORCE_IP% `cat enforce_ip.template` - +python variable_grabbler.py echo "============================================================================== Done."