Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • CiviCRM Core CiviCRM Core
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Graph
    • Compare revisions
  • Issues 1,176
    • Issues 1,176
    • List
    • Boards
    • Service Desk
    • Milestones
  • Deployments
    • Deployments
    • Releases
  • Wiki
    • Wiki
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • DevelopmentDevelopment
  • CiviCRM CoreCiviCRM Core
  • Issues
  • #1643
Closed
Open
Issue created Mar 11, 2020 by DaveD@DaveDMaintainer

civicrm-setup and backward slashes in file paths on windows don't play nice together

Is the end plan for a typical production install to run civicrm-setup live on the target server as opposed to the current installer? If so then the backwards slashes will cause some problems on windows. This is similar to #1572 (closed)

If I make the naive change below I can at least get past the part where it loads tables, but then elsewhere it still has backwards slashes. And my civicrm.settings.php ends up with a mix of forward and backward in the same variable sometimes, although you can always fix civicrm.settings.php easily enough manually after.

--- a/CRM/Core/CodeGen/Util/Xml.php
+++ b/CRM/Core/CodeGen/Util/Xml.php
@@ -13,6 +13,7 @@ class CRM_Core_CodeGen_Util_Xml {
    */
   public static function parse($file) {
     $dom = new DomDocument();
+    $file = str_replace(DIRECTORY_SEPARATOR, '/', $file);
     $xmlString = file_get_contents($file);
     $dom->loadXML($xmlString);
     $dom->documentURI = $file;

@totten

Otherwise it seems quite nice and potentially very versatile.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking