Skip to content

component detection support regex to match files. #74

@wangzelin007

Description

@wangzelin007

Hi component detection team,
Our public repo: azure-cli is using component detection in Azure DevOps pipelines.
in our repo, we have multiple reuqirment.$PYVERSION.$PLATFORM.txt file.
For example:
https://github.com/Azure/azure-cli/blob/dev/src/azure-cli/requirements.py3.Darwin.txt
https://github.com/Azure/azure-cli/blob/dev/src/azure-cli/requirements.py3.Linux.txt
https://github.com/Azure/azure-cli/blob/dev/src/azure-cli/requirements.py3.windows.txt

But component detection task only match requirements.txt file
component-detection.log

Can you support regex while checking files.
Currently:
https://github.com/microsoft/component-detection/blob/main/src/Microsoft.ComponentDetection.Detectors/pip/PipComponentDetector.cs#L18
image
Suggetsion:
public override IList SearchPatterns => new List { "setup*.py", "requirements*.txt" };

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    detector:pipThe pip detectorstatus:waiting-on-responseWaiting on a response/more information from the usertype:bugBug fix of existing functionality

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions