Skip to content

Check if file system is case sensitive and set ignorecase for none case sensitive #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: 2.0.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions fs-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/usr/bin/env bash

# Create two files with a differing capitalization
touch testfile
touch TESTFILE

# Check if both files exist
if ls | grep -q 'TESTFILE' && ls | grep -q 'testfile'; then
echo "Case-sensitive file system, no action necessary"
else
git -C ../repos/drupal config core.ignorecase true
echo "None case-sensitive file system, ignorecase git configuration setting is set to true for the drupal repository"
fi

# Clean up
rm -f testfile TESTFILE
2 changes: 2 additions & 0 deletions install.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ name: ddev-drupal-core-dev
project_files:
- config.ddev-drupal-core-dev.yaml
- docker-compose.core-dev-selenium.yaml
- fs-check.sh
- core-dev/phpunit-firefox.xml
- core-dev/phpunit-chrome.xml
- commands/web/drupal
Expand All @@ -26,6 +27,7 @@ project_files:
- core-dev/src/Command/LintCommand.php

post_install_actions:
- sh fs-check.sh
- cp core-dev/phpunit-chrome.xml ../phpunit.xml
- perl -pi -e "s|DRUPAL_CORE_DDEV_URL|$DDEV_PRIMARY_URL|g" ../phpunit.xml
- perl -pi -e "'$DDEV_DOCROOT' and s|DDEV_DOCROOT|$DDEV_DOCROOT/|g" ../phpunit.xml
Expand Down