public async Task StartAsync(CancellationToken cancellationToken)
        {
            var repositories    = _configuration.GetSection("Repositories").Get <string[]>() ?? new string[0];
            var initialiseTasks = repositories.Select(x => _sourceControl.Add(x));
            await Task.WhenAll(initialiseTasks);

            await HandleMessages(cancellationToken);

            await StopAsync(cancellationToken);
        }
Example #2
0
 public async Task Execute(dynamic command)
 {
     await _sourceControl.Add((string)command.Path);
 }