https://docs.vmgd.whatworks.com.au/
  • ICT Team
    • Setting up your development environment
      • Install programs
      • Create a development wordpress site in Local
      • Git clone the repo
      • Configure the database connection
      • Pull database from live server
      • Run dev server
      • Push changes to live server
    • Making changes to the website
      • File Structure Overview
      • Creating a New Page Template
      • Content Entry Workflow
      • Deployment
    • VMGD Backend Requirements
      • Functional Requirements
        • Ability to edit website and mobile app content
        • API endpoints + documentation for mobile app
        • GraphQL server that allows the website front-end + mobile app to query all website content
        • Mobile Notification
        • Triggers
      • Non-Functional Requirements
        • Availability
          • Vercel CDN
          • Fastly CDN
          • Fastly Firewall
          • Caching + Firewall Diagram
Powered by GitBook
On this page
  1. ICT Team
  2. Setting up your development environment

Git clone the repo

PreviousCreate a development wordpress site in LocalNextConfigure the database connection

Last updated 6 months ago

Now we want to remove all wordpress files generated by Local and replace them with the files from the github repo.

When you it the site shell it will take you to the public directory in the terminal.

Macintosh HD/Users/User_Name/Local Sites/vmgd/app/public

We're going to delete the public folder and replace with the github repo

Public folder is currently where local expects Wordpress website to be. We will replace the public folder with git hub repo files.

Run the following commands in one command. The reason to run them in one command is if the git clone command fails you still have the public folder:

cd .. rm -rf public git clone git@github.com:what-works-global/vmgd.git public

Edit site.conf.hbs

Open the file with the Visual Studio Code.

Change:

root "{{root}}";

To:

root "{{root}}/wordpress";

Now Local knows the directory containing all the wordpress files is in a sub-directory of the public folder.

Possible Cases and Errors:

When it says permission denied:

stop the site in local (so that it doesn't recreate after you already deleted it)

and after that use the following commands in the terminal

sudo rm -rf public

which will remove the public directory.

When it says public folder not found:

Go to this directory

Macintosh HD/Users/User_Name/Local Sites/vmgd

cmd + Right click and open the app folder directory in the new terminal

and paste the following command in the terminal.

git clone git@github.com:what-works-global/vmgd.git public