diff mbox series

[net-next,1/2] tools: tc-testing: whitespace and .gitignore

Message ID 20180223155133.17125-2-bjb@mojatatu.com
State Superseded, archived
Delegated to: David Miller
Headers show
Series tools: tc-testing: better error reporting | expand

Commit Message

Brenda J. Butler Feb. 23, 2018, 3:51 p.m. UTC
Fix indentation and add editor backup files to .gitignore

Signed-off-by: Brenda J. Butler <bjb@mojatatu.com>
---
 tools/testing/selftests/tc-testing/.gitignore | 1 +
 tools/testing/selftests/tc-testing/tdc.py     | 4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)

Comments

Andrew Lunn Feb. 23, 2018, 4:13 p.m. UTC | #1
On Fri, Feb 23, 2018 at 10:51:32AM -0500, Brenda J. Butler wrote:
> Fix indentation and add editor backup files to .gitignore
> 
> Signed-off-by: Brenda J. Butler <bjb@mojatatu.com>
> ---
>  tools/testing/selftests/tc-testing/.gitignore | 1 +
>  tools/testing/selftests/tc-testing/tdc.py     | 4 ++--
>  2 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/tools/testing/selftests/tc-testing/.gitignore b/tools/testing/selftests/tc-testing/.gitignore
> index 7a60b85e148f..d668a0fdea39 100644
> --- a/tools/testing/selftests/tc-testing/.gitignore
> +++ b/tools/testing/selftests/tc-testing/.gitignore
> @@ -1,2 +1,3 @@
>  __pycache__/
>  *.pyc
> +*.py~

Hi Brenda

Isn't this something which can be done once at the top level?

      Andrew
Brenda J. Butler Feb. 23, 2018, 4:59 p.m. UTC | #2
On Fri, Feb 23, 2018 at 11:13 AM, Andrew Lunn <andrew@lunn.ch> wrote:
> On Fri, Feb 23, 2018 at 10:51:32AM -0500, Brenda J. Butler wrote:
>> Fix indentation and add editor backup files to .gitignore
>>
>> Signed-off-by: Brenda J. Butler <bjb@mojatatu.com>
>> ---
>>  tools/testing/selftests/tc-testing/.gitignore | 1 +
>>  tools/testing/selftests/tc-testing/tdc.py     | 4 ++--
>>  2 files changed, 3 insertions(+), 2 deletions(-)
>>
>> diff --git a/tools/testing/selftests/tc-testing/.gitignore b/tools/testing/selftests/tc-testing/.gitignore
>> index 7a60b85e148f..d668a0fdea39 100644
>> --- a/tools/testing/selftests/tc-testing/.gitignore
>> +++ b/tools/testing/selftests/tc-testing/.gitignore
>> @@ -1,2 +1,3 @@
>>  __pycache__/
>>  *.pyc
>> +*.py~
>
> Hi Brenda
>
> Isn't this something which can be done once at the top level?

You mean, the very top level?  Yes it can.

If we did that, the .pyc and __pycache__
could be removed from other directories like

Documentation
scripts/gdb/linux
tools/perf

Oops, there is already *~ in the top-level .gitignore.  Sorry about that.

I will make a v2 to remove *.py~.

Thanks.

bjb
diff mbox series

Patch

diff --git a/tools/testing/selftests/tc-testing/.gitignore b/tools/testing/selftests/tc-testing/.gitignore
index 7a60b85e148f..d668a0fdea39 100644
--- a/tools/testing/selftests/tc-testing/.gitignore
+++ b/tools/testing/selftests/tc-testing/.gitignore
@@ -1,2 +1,3 @@ 
 __pycache__/
 *.pyc
+*.py~
diff --git a/tools/testing/selftests/tc-testing/tdc.py b/tools/testing/selftests/tc-testing/tdc.py
index b3754b9aa302..ab28373dccd7 100755
--- a/tools/testing/selftests/tc-testing/tdc.py
+++ b/tools/testing/selftests/tc-testing/tdc.py
@@ -347,9 +347,9 @@  def check_default_settings(args, remaining, pm):
     global NAMES
 
     if args.path != None:
-         NAMES['TC'] = args.path
+        NAMES['TC'] = args.path
     if args.device != None:
-         NAMES['DEV2'] = args.device
+        NAMES['DEV2'] = args.device
     if not os.path.isfile(NAMES['TC']):
         print("The specified tc path " + NAMES['TC'] + " does not exist.")
         exit(1)