Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. Gitignore.php

function Gitignore::toRegex

Returns a regexp which is the equivalent of the gitignore pattern.

Format specification: https://git-scm.com/docs/gitignore#_pattern_format

1 call to Gitignore::toRegex()
VcsIgnoredFilterIterator::readGitignoreFile in vendor/symfony/finder/Iterator/VcsIgnoredFilterIterator.php

File

vendor/symfony/finder/Gitignore.php, line 27

Class

Gitignore
Gitignore matches against text.

Namespace

Symfony\Component\Finder

Code

public static function toRegex(string $gitignoreFileContent) : string {
    return self::buildRegex($gitignoreFileContent, false);
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal