CoreBOSBB
Using git pull - Printable Version

+- CoreBOSBB (https://discussions.corebos.org)
+-- Forum: Support (https://discussions.corebos.org/forumdisplay.php?fid=17)
+--- Forum: Administrator Support (https://discussions.corebos.org/forumdisplay.php?fid=8)
+--- Thread: Using git pull (/showthread.php?tid=145)

Pages: 1 2


RE: Using git pull - joebordes - 05-11-2015

This could be a lack of write permission on the vtigerversion.php file. The last step of the process modifies the version number in that file.
Make sure the value contained inside that file is the same as the one you have in the database vtiger_version table


RE: Using git pull - polanskiman - 05-12-2015

I have the same issue that Mweaver. I tried the git config core.fileMode false in order for git to discard all those files where the permissions where different from default. When I run git status again, git is showing fewer files, which is expected. I still have got a few though but those are probably the files where the code have been updated. After that section I have the following:

Untracked files:
 (use "git add <file>..." to include in what will be committed)

18145484715374875319e474.87062199install.php.txt
18145484715374875319e474.87062199install/
SendReminder_OBSOLETE.php
build/wsChanges/CPAuthenticateContact.php
build/wsChanges/CPChangePortalPassword.php
ETC ETC ETC

I've done a git add <filename> and that got rid of the problem.

I still have got a problem though. When I finally try git pull I get the following:


Code:
serv> git pull

remote: Counting objects: 10316, done.
remote: Compressing objects: 100% (2404/2404), done.
remote: Total 10316 (delta 4076), reused 2526 (delta 2525), pack-reused 5386
Receiving objects: 100% (10316/10316), 9.09 MiB | 269.00 KiB/s, done.
Resolving deltas: 100% (6813/6813), done.
From https://github.com/tsolucio/corebos
   c25a0bd..8f66f21  master     -> origin/master
 * [new branch]      getrelatedfield -> origin/getrelatedfield
 * [new branch]      omnipay    -> origin/omnipay
 * [new branch]      validateGlobalVar -> origin/validateGlobalVar
 * [new tag]         coreBOS5.5 -> coreBOS5.5
Updating c25a0bd..8f66f21
error: Your local changes to the following files would be overwritten by merge:
include/Webservices/CustomerPortalWS.php
include/Webservices/VtigerDocumentOperation.php
Please, commit your changes or stash them before you can merge.
error: Your local changes to the following files would be overwritten by merge:
.gitignore
README.md
Smarty/templates/Header.tpl
Smarty/templates/Home/HomeBlock.tpl
Smarty/templates/Login.tpl
Smarty/templates/Settings/EmailConfig.tpl
Smarty/templates/com_vtiger_workflow/ListWorkflows.tpl
cron/SendReminder.service
cron/send_mail.php
ETC ETC ETC

What should I do?


RE: Using git pull - polanskiman - 05-12-2015

I have a recommendation. Why not post the default file permissions of all files (or type of files/directories) so that a user can simply re-apply those permissions to the CoreBOS directory and files if need be. At present I am applying the permissions that you (Joe) recommended but still GIT sees a lot of files as not having the proper permission. I am currently using the following:


Code:
chmod 775 corebos
chown -R http:http corebos
cd corebos
find . -type d -exec chmod 775 {} \; ; find . -type f -exec chmod 664 {} \;



RE: Using git pull - joebordes - 05-12-2015

You can't add the files because they are already in the project, that is why you get a conflict when you try to pull, you have to delete untracked files that are already in the base project. You can use "git reset" if you haven't committed the changes.

As to the recommended permissions the thing is that git versions the state, whether I want to or not, git is going to register and control that information, so the recommended status is the one in the repository (in most of the files). If you need something different for your specific install then you simply execute the "ignore" command on your system. I really have no choice.


RE: Using git pull - polanskiman - 05-13-2015

(05-12-2015, 10:37 PM)joebordes Wrote: You can't add the files because they are already in the project, that is why you get a conflict when you try to pull, you have to delete untracked files that are already in the base project. You can use "git reset" if you haven't committed the changes.

As to the recommended permissions the thing is that git versions the state, whether I want to or not, git is going to register and control that information, so the recommended status is the one in the repository (in most of the files). If you need something different for your specific install then you simply execute the "ignore" command on your system. I really have no choice.

Well those untracked files that I added are not the ones that are showing when I do a git pull. Anyways I did a git reset as recommended, did a git status then deleted all untracked files from CoreBOS directory then did a git pull. Same problem. This is what I get:


Code:
Serv> git pull
Updating c25a0bd..8f66f21
error: Your local changes to the following files would be overwritten by merge:
    .gitignore
    README.md
    Smarty/templates/Header.tpl
    Smarty/templates/Home/HomeBlock.tpl
    Smarty/templates/Login.tpl
    Smarty/templates/Settings/EmailConfig.tpl
    Smarty/templates/com_vtiger_workflow/ListWorkflows.tpl
    cron/SendReminder.service
    cron/send_mail.php
    data/CRMEntity.php
    include/Webservices/ExtendSession.php
    include/Webservices/ModuleTypes.php
    include/Webservices/VtigerCRMObjectMeta.php
    include/install/language/de_de.lang.php
    include/install/language/en_gb.lang.php
    include/install/language/en_us.lang.php
    include/install/language/es_es.lang.php
    include/install/language/es_mx.lang.php
    include/install/language/nl_nl.lang.php
    include/install/language/pt_br.lang.php
    include/install/resources/utils.php
    include/js/general.js
    include/language/de_de.lang.php
    include/language/en_gb.lang.php
    include/language/en_us.lang.php
    include/language/es_es.lang.php
    include/language/es_mx.lang.php
    include/language/hu_hu.lang.php
    include/language/nl_nl.lang.php
    include/language/pt_br.lang.php
    include/php_writeexcel/class.writeexcel_formula.inc.php
    include/style.css
    include/utils/CommonUtils.php
    include/utils/InventoryUtils.php
    include/utils/utils.php
    modules/Accounts/Accounts.js
    modules/CustomView/SendMailAction.php
    modules/Documents/DetailView.php
    modules/Documents/Documents.php
    modules/Emails/class.phpmailer.php
    modules/Emails/class.smtp.php
    modules/Emails/mail.php
    modules/Import/controllers/Import_Data_Controller.php
    modules/Import/controllers/Import_Index_Controller.php
    modules/MailManager/src/models/Draft.php
    modules/ModTracker/ModTracker.php
    modules/PurchaseOrder/PurchaseOrder.php
    modules/Quotes/Quotes.php
    modules/Reports/ReportRun.php
    modules/SalesOrder/SalesOrder.php
    modules/SalesOrder/SalesOrderPDFController.php
    modules/Settings/EmailConfig.php
    modules/Settings/Save.php
    modules/Settings/language/en_gb.lang.php
    modules/Settings/language/en_us.lang.php
    modules/Settings/language/es_es.lang.php
    modules/Settings/language/es_mx.lang.php
    modules/Settings/language/fr_fr.lang.php
    modules/Settings/language/hu_hu.lang.php
    modules/Settings/language/pt_br.lang.php
    modules/com_vtiger_workflow/VTWorkflowApplication.inc
    modules/com_vtiger_workflow/editworkflow.php
    modules/com_vtiger_workflow/expression_engine/VTParser.inc
    modules/com_vtiger_workflow/expression_engine/VTTokenizer.inc
    modules/com_vtiger_workflow/tasklist.php
    modules/com_vtiger_workflow/tasks/VTUpdateFieldsTask.inc
    modules/com_vtiger_workflow/workflowlist.php
    schema/DatabaseSchema.xml
    upgrade2coreBOS.php
    vtlib/Vtiger/Block.php
    vtlib/Vtiger/Mailer.php
    vtlib/Vtiger/PackageImport.php
    vtlib/Vtiger/Unzip.php
    webservice.php
Please, commit your changes or stash them before you can merge.
Aborting



RE: Using git pull - polanskiman - 05-14-2015

Hi Joe,

All this was giving me too many headaches so I did a fresh install with a migration as described here http://corebos.org/documentation/doku.php?id=en:upgradevt2cb

All seems to be working fine up until now. The question remains on what will happen next time if I chose to customise the code. Will I need to go through all this process again?


RE: Using git pull - joebordes - 05-14-2015

I don't really know because I don't know the source of the problem. All I can say as that all my installs are done with git control and updated constantly with very little effort, just having to solve some conflict in personal customizations from time to time. I mean: I am not having problems at all with this approach.

Keep me informed.