Gitify and existing Git project

Having expanded our team I have been looking for a better way of automating the process from local to dev to production. I have got all my local set up, got projects into Git, cloned the repository in the cPanel on the dev server (into a folder called repositories) and created the .yml deployment file which pushes up to my public_html folder. All works as I need it too, changed files get pushed to the repository, pulled down to dev then deployed; once happy I can pull down on to the production and deploy.

Having done some more research I have found Gitify which can sync my database files such as TVs etc. I have followed the instructions and installed it on the dev server (into a repositories’ folder alongside my git folder) but when I come to run a command I get bash command not found. I think it is to do with the structure but am not 100% sure so a little of guidance would really help.

I get up to this bit in the installation - Edit your ~/.bash_profile - to point to the gitify folder which I have done but after that I get the error bash command not found.

Structure is - /home/accountname directory - inside this I have my various other directories including my repositories directory and my public_html. In my repositories directory I have cloned the dev site and Gitify in to separate folders. In my dev site repository I have my .yml file for deployment; what do I need to get gitify to work so I can extract from my dev site? Should Gitify be in my dev site repository? Should I have cloned the repository into my public_html folder?

I can tell I am not far away but as I am not setting up a brand new MODX site and already have the repository on github I think I am going wrong somewhere. Any help appreciated.

If it can’t find the Gitify command after adding it to the PATH in your bash profile (and either source-ing the file again or existing/reopening the connection), then it’s not added properly. Or maybe you’re not using bash but zsh and need to add it into the .zshrc file instead.

You can also use full paths to the command (e.g. /path/to/gitify/Gitify extract), but it’s definitely easier if you have it available as just Gitify.

Hi Mark, thanks for responding. Should my site repository have the gitify file in it or should the gitify repository sit inside my dev site repository? I am just confused as to the structure things need to be having already got a repository set up and then trying to add gitify. I can’t see how after pointing to my Gitify folder it can read the website which is in public_html which is why I think maybe the commands are failing. I’ll try setting up a brand-new site and repository and see if I can get it working that way rather than trying to do it backwards.

First you install Gitify somewhere on your server. It doesn’t matter where, but it probably should not be inside your actual project. I often put it in /home/user/gitify/.

Then you navigate to your project folder (which could be public_html or in your repositories folder), and you run Gitify in that folder. That’s how Gitify knows where to look; it’s the directory you execute it in.