Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to work with SuiteCRM via GIT

My company took a terrible decision. They decided to use SuiteCRM, someone installed it for them, and now i should support and develop it. We should customize it a lot and of course it's needed to create many relationships, custom fields, e.t.c. But... how we can do it via git? After any changes in Admin/Studio system creates about 30-40 changes in files, and it's impossible to manage them. After every repair and rebuild there are hundreds changes. It's terrible.

Is there "the right way" to work with CRM and git? I tried to find documentation about changes in relationships and fields via code, not GUI, and found many different instructions and ways... It there a one right way?

Thanks.

like image 845
vlreshet Avatar asked Dec 02 '22 12:12

vlreshet


1 Answers

  • As others pointed out you want to use a .gitignore file to ignore certain files and folders, e.g. /*.log /custom/working, /cache and /upload. Also .ext.php-files in /custom/modules/ are generated and could probably remain untracked by git.
  • If you're using Studio to add or change fields you'll have to also write hooks that dump/load the contents of the database table fields_meta_data (hint: with mysqldump I recommend using --skip-extended-insert --skip-dump-date to avoid a git-unmaintainable dump format). As an alternative, you could convert them to vardefs
  • If you also want to ignore // created: <timestamp> lines, you'll have to have a look at git-attributes/filters and probably go through some headache. If you find a working solution for this - feel free to share :)
like image 149
Jay Avatar answered Dec 09 '22 09:12

Jay