target_editfile: Improve doc comment
PATCH 1/2 target_editfile: Improve doc comment
More clearly state which arguments are optional.
Signed-off-by Ian Jackson <[email protected]>
--- Osstest/TestSupport.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
Osstest/TestSupport.pm +2 -1
@@ -521,7 +521,8 @@ sub teditfileex { sub target_editfile_root ($$$;$$) { teditfileex('root',@_); } sub target_editfile ($$$;$$) { teditfileex('osstest',@_); } # my $code= pop @_; - # my ($ho,$rfile,$lleaf,$rdest) = @_; + # my ($ho,$rfile, $lleaf,$rdest) = @_; + # ^^^^^^^^^^^^^ optional sub target_cmd_build ($$$$) { my ($ho,$timeout,$builddir,$script) = @_;
Signature · 1 line
1.7.10.4
PATCH 2/2 cs-adjust-flight: runvar-perlop: Do not report non-changes
With -v, runvar-perlop would unconditionally print a message about the changed variable. Instead, only call runvar_set if the value is to change.
Signed-off-by Ian Jackson <[email protected]>
--- cs-adjust-flight | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
cs-adjust-flight +2 -1
@@ -268,7 +268,8 @@ sub change__runvar_perlop { my ($job, $name, $varrow) = @_; my $oldval = $varrow->{val}; my $newval = perlop_value($job, $name, $op, $oldval); - runvar_set($job, $name, $newval, " (modified from \`$oldval')"); + runvar_set($job, $name, $newval, " (modified from \`$oldval')") + if $newval ne $oldval; }, 'IGNORE'); }
Signature · 1 line
1.7.10.4
Re: [OSSTEST PATCH 2/2] cs-adjust-flight: runvar-perlop: Do not report non-changes
Quoted 5 lines · Ian Jackson
With -v, runvar-perlop would unconditionally print a message about the changed variable. Instead, only call
runvar_setif the value is to change.Signed-off-by Ian Jackson <[email protected]>
Acked-by Ian Campbell <[email protected]>
Quoted 18 lines
--- cs-adjust-flight | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)cs-adjust-flight +2
-1@@ -268,7 +268,8 @@ sub change__runvar_perlop { my ($job, $name, $varrow) = @_; my $oldval = $varrow->{val}; my $newval = perlop_value($job, $name, $op, $oldval); - runvar_set($job, $name, $newval, " (modified from \`$oldval')"); + runvar_set($job, $name, $newval, " (modified from \`$oldval')") + if $newval ne $oldval; }, 'IGNORE'); }
Quoted 3 lines · Ian Jackson
More clearly state which arguments are optional.
Signed-off-by Ian Jackson <[email protected]>
Acked-by Ian Campbell <[email protected]>
Quoted 18 lines
--- Osstest/TestSupport.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)Osstest/TestSupport.pm +2
-1@@ -521,7 +521,8 @@ sub teditfileex { sub target_editfile_root ($$$;$$) { teditfileex('root',@_); } sub target_editfile ($$$;$$) { teditfileex('osstest',@_); } # my $code= pop @_; - # my ($ho,$rfile,$lleaf,$rdest) = @_; + # my ($ho,$rfile, $lleaf,$rdest) = @_; + # ^^^^^^^^^^^^^ optional sub target_cmd_build ($$$$) { my ($ho,$timeout,$builddir,$script) = @_;