From b54e381e0419022d5a686c5729744b93b9d5692c Mon Sep 17 00:00:00 2001 From: lshprung Date: Mon, 11 Apr 2022 20:32:46 -0700 Subject: Created setup script --- .gitignore | 1 + setup.php | 41 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 setup.php diff --git a/.gitignore b/.gitignore index 98dfb6d..1a15d5d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ * !backend/backend.php !assignment_list* +!setup.php !.gitignore diff --git a/setup.php b/setup.php new file mode 100644 index 0000000..0e7a9cc --- /dev/null +++ b/setup.php @@ -0,0 +1,41 @@ +"); + + echo "\nSuccessfully wrote \"$config_path\"\n"; +} + +function fwrite_wrapper($file, $string){ + GLOBAL $config_path; + + if(fwrite($file, $string) === FALSE){ + die("Cannot write to file \"$config_path\""); + } +} + +?> -- cgit