@@ -5,12 +5,15 @@ namespace GitHub.Unity
55{
66 class GitConfigGetAllTask : ProcessTaskWithListOutput < string >
77 {
8+ private const string TaskName = "git config get" ;
89 private readonly string arguments ;
910
1011 public GitConfigGetAllTask ( string key , GitConfigSource configSource ,
1112 CancellationToken token , BaseOutputListProcessor < string > processor = null )
1213 : base ( token , processor ?? new SimpleListOutputProcessor ( ) )
1314 {
15+ Guard . ArgumentNotNullOrWhiteSpace ( key , nameof ( key ) ) ;
16+ Name = TaskName ;
1417 var source = "" ;
1518 source +=
1619 configSource == GitConfigSource . NonSpecified ? "--get-all" :
@@ -20,19 +23,20 @@ public GitConfigGetAllTask(string key, GitConfigSource configSource,
2023 arguments = String . Format ( "config {0} {1}" , source , key ) ;
2124 }
2225
23- public override string Name { get { return "git config get" ; } }
2426 public override string ProcessArguments { get { return arguments ; } }
2527 public override TaskAffinity Affinity { get { return TaskAffinity . Concurrent ; } }
2628 }
2729
2830 class GitConfigGetTask : ProcessTask < string >
2931 {
32+ private const string TaskName = "git config get" ;
3033 private readonly string arguments ;
3134
3235 public GitConfigGetTask ( string key , GitConfigSource configSource ,
3336 CancellationToken token , IOutputProcessor < string > processor = null )
3437 : base ( token , processor ?? new FirstNonNullLineOutputProcessor ( ) )
3538 {
39+ Name = TaskName ;
3640 var source = "" ;
3741 source +=
3842 configSource == GitConfigSource . NonSpecified ? "--get-all" :
@@ -42,7 +46,6 @@ public GitConfigGetTask(string key, GitConfigSource configSource,
4246 arguments = String . Format ( "config {0} {1}" , source , key ) ;
4347 }
4448
45- public override string Name { get { return "git config get" ; } }
4649 public override string ProcessArguments { get { return arguments ; } }
4750 public override TaskAffinity Affinity { get { return TaskAffinity . Concurrent ; } }
4851 }
0 commit comments