diff mbox

[U-Boot] patman: Look for checkpatch in the scripts directory

Message ID 1353979403-14295-1-git-send-email-dianders@chromium.org
State Accepted
Commit d96ef37df78eac5c636866d8f226991a5d96e6bb
Delegated to: Simon Glass
Headers show

Commit Message

Doug Anderson Nov. 27, 2012, 1:23 a.m. UTC
The Linux kernel stores checkpatch.pl in the scripts directory.  Add
that to the search path to make things more automatic for kernel
development.

Signed-off-by: Doug Anderson <dianders@chromium.org>

---
 tools/patman/checkpatch.py |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

Comments

Simon Glass Nov. 28, 2012, 11:46 p.m. UTC | #1
On Mon, Nov 26, 2012 at 5:23 PM, Doug Anderson <dianders@chromium.org> wrote:
> The Linux kernel stores checkpatch.pl in the scripts directory.  Add
> that to the search path to make things more automatic for kernel
> development.
>
> Signed-off-by: Doug Anderson <dianders@chromium.org>

Acked-by: Simon Glass <sjg@chromium.org>

>
> ---
>  tools/patman/checkpatch.py |    4 +++-
>  1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/tools/patman/checkpatch.py b/tools/patman/checkpatch.py
> index d831087..f72f8ee 100644
> --- a/tools/patman/checkpatch.py
> +++ b/tools/patman/checkpatch.py
> @@ -26,10 +26,12 @@ import re
>  import terminal
>
>  def FindCheckPatch():
> +    top_level = gitutil.GetTopLevel()
>      try_list = [
>          os.getcwd(),
>          os.path.join(os.getcwd(), '..', '..'),
> -        os.path.join(gitutil.GetTopLevel(), 'tools'),
> +        os.path.join(top_level, 'tools'),
> +        os.path.join(top_level, 'scripts'),
>          '%s/bin' % os.getenv('HOME'),
>          ]
>      # Look in current dir
> --
> 1.7.7.3
>
Simon Glass Jan. 31, 2013, 11:49 p.m. UTC | #2
On Thu, Nov 29, 2012 at 12:46 PM, Simon Glass <sjg@chromium.org> wrote:
> On Mon, Nov 26, 2012 at 5:23 PM, Doug Anderson <dianders@chromium.org> wrote:
>> The Linux kernel stores checkpatch.pl in the scripts directory.  Add
>> that to the search path to make things more automatic for kernel
>> development.
>>
>> Signed-off-by: Doug Anderson <dianders@chromium.org>
>
> Acked-by: Simon Glass <sjg@chromium.org>

Applied to u-boot-x86, thanks.

>
>>
>> ---
>>  tools/patman/checkpatch.py |    4 +++-
>>  1 files changed, 3 insertions(+), 1 deletions(-)
>>
>> diff --git a/tools/patman/checkpatch.py b/tools/patman/checkpatch.py
>> index d831087..f72f8ee 100644
>> --- a/tools/patman/checkpatch.py
>> +++ b/tools/patman/checkpatch.py
>> @@ -26,10 +26,12 @@ import re
>>  import terminal
>>
>>  def FindCheckPatch():
>> +    top_level = gitutil.GetTopLevel()
>>      try_list = [
>>          os.getcwd(),
>>          os.path.join(os.getcwd(), '..', '..'),
>> -        os.path.join(gitutil.GetTopLevel(), 'tools'),
>> +        os.path.join(top_level, 'tools'),
>> +        os.path.join(top_level, 'scripts'),
>>          '%s/bin' % os.getenv('HOME'),
>>          ]
>>      # Look in current dir
>> --
>> 1.7.7.3
>>
diff mbox

Patch

diff --git a/tools/patman/checkpatch.py b/tools/patman/checkpatch.py
index d831087..f72f8ee 100644
--- a/tools/patman/checkpatch.py
+++ b/tools/patman/checkpatch.py
@@ -26,10 +26,12 @@  import re
 import terminal
 
 def FindCheckPatch():
+    top_level = gitutil.GetTopLevel()
     try_list = [
         os.getcwd(),
         os.path.join(os.getcwd(), '..', '..'),
-        os.path.join(gitutil.GetTopLevel(), 'tools'),
+        os.path.join(top_level, 'tools'),
+        os.path.join(top_level, 'scripts'),
         '%s/bin' % os.getenv('HOME'),
         ]
     # Look in current dir