Ejemplo n.º 1
0
        /// <inheritdoc cref="BaseCopyrightParser.CanParseAsync(
        ///     FileInfo,
        ///     CancellationToken)" />
        public async override Task <bool> CanParseAsync(
            FileInfo file,
            CancellationToken cancellationToken)
        {
            var relativePath = await VersionControlService.GetRelativePathAsync(file);

            if (relativePath != null)
            {
                var parts = relativePath.DecomposePath();
                return(parts[0].Equals("README.md", StringComparison.OrdinalIgnoreCase));
            }

            return(false);
        }