Patchwork [Maverick] UBUNTU: 'fdr editconfig' modification. Easily skip over unwanted menuconfigs.

login
register
mail settings
Submitter Lee Jones
Date June 2, 2010, 7:50 a.m.
Message ID <4C060D33.30008@canonical.com>
Download mbox | patch
Permalink /patch/54348/
State Accepted
Delegated to: Leann Ogasawara
Headers show

Comments

Lee Jones - June 2, 2010, 7:50 a.m.
All,

It is now easier to edit 'per-flavour' configuration files. The old
system forced the developer to enter a menuconfig system for each
flavour until eventually landing in the required one. After following
this process numerous times it can easily become tedious. Now the
developer is asked whether they want to enter each menuconfig in turn,
rapidly speeding up the process.

The following changes since commit a8e1af2ae65acbed1b4e1009a80d2371a484aec9:
  Leann Ogasawara (1):
        UBUNTU: Ubuntu-2.6.34-2.9

are available in the git repository at:

  git://kernel.ubuntu.com/lag/ubuntu-maverick.git editconfig

Lee Jones (1):
      UBUNTU: 'fdr editconfig' modification. Easily skip over unwanted
menuconfigs.


 debian/scripts/misc/kernelconfig |   21 +++++++++++++++------
 1 files changed, 15 insertions(+), 6 deletions(-)

+                               done
+                               ;;
                            *)  # Bad!
                                exit 1 ;;
                        esac

Kind regards,
Lee
Lee Jones - June 2, 2010, 7:53 a.m.
On 02/06/10 08:50, Lee Jones wrote:
> All,
>
> It is now easier to edit 'per-flavour' configuration files. The old
> system forced the developer to enter a menuconfig system for each
> flavour until eventually landing in the required one. After following
> this process numerous times it can easily become tedious. Now the
> developer is asked whether they want to enter each menuconfig in turn,
> rapidly speeding up the process.
>
> The following changes since commit a8e1af2ae65acbed1b4e1009a80d2371a484aec9:
>   Leann Ogasawara (1):
>         UBUNTU: Ubuntu-2.6.34-2.9
>
> are available in the git repository at:
>
>   git://kernel.ubuntu.com/lag/ubuntu-maverick.git editconfig
>
> Lee Jones (1):
>       UBUNTU: 'fdr editconfig' modification. Easily skip over unwanted
> menuconfigs.
>
>
>  debian/scripts/misc/kernelconfig |   21 +++++++++++++++------
>  1 files changed, 15 insertions(+), 6 deletions(-)
>
> diff --git a/debian/scripts/misc/kernelconfig
> b/debian/scripts/misc/kernelconfig
> index 71c0f5e..3181978 100755 (executable)
> --- a/debian/scripts/misc/kernelconfig
> +++ b/debian/scripts/misc/kernelconfig
> @@ -51,9 +51,6 @@ for arch in $archs; do
>                 *)      kernarch="$arch"        ;;
>         esac
>  
> -       echo ""
> -       echo "***************************************"
> -       echo "* Processing $arch ($kernarch) ... "
>         archconfdir=$confdir/$arch
>         flavourconfigs=$(cd $archconfdir && ls config.flavour.*)
>  
> @@ -96,9 +93,21 @@ for arch in $archs; do
>                                 make O=`pwd`/build ARCH=$kernarch
> oldconfig ;;
>                             editconfig)
>                                 # Interactively edit config parameters
> -                               echo " * Run menuconfig on
> $arch/$config... Press a key."
> -                               read
> -                               make O=`pwd`/build ARCH=$kernarch
> menuconfig ;;
> +                               while : ; do
> +                                       echo -n "Do you want to edit
> config: $arch/$config? [Y/n] "
> +                                       read choice
> +                                      
> +                                       case "$choice" in
> +                                       y* | Y* | "" )
> +                                               make O=`pwd`/build
> ARCH=$kernarch menuconfig
> +                                               break ;;
> +                                       n* | N* )
> +                                               break ;;
> +                                       *)
> +                                               echo "Entry not valid"
> +                                       esac
> +                               done
> +                               ;;
>                             *)  # Bad!
>                                 exit 1 ;;
>                         esac
>
> Kind regards,
> Lee
>
>   

I don't know why it insists on line wrapping!

Is this still suitable?
Eric Miao - June 2, 2010, 8:10 a.m.
On Wed, Jun 2, 2010 at 3:53 PM, Lee Jones <lee.jones@canonical.com> wrote:
> On 02/06/10 08:50, Lee Jones wrote:
>> All,
>>
>> It is now easier to edit 'per-flavour' configuration files. The old
>> system forced the developer to enter a menuconfig system for each
>> flavour until eventually landing in the required one. After following
>> this process numerous times it can easily become tedious. Now the
>> developer is asked whether they want to enter each menuconfig in turn,
>> rapidly speeding up the process.
>>
>> The following changes since commit a8e1af2ae65acbed1b4e1009a80d2371a484aec9:
>>   Leann Ogasawara (1):
>>         UBUNTU: Ubuntu-2.6.34-2.9
>>
>> are available in the git repository at:
>>
>>   git://kernel.ubuntu.com/lag/ubuntu-maverick.git editconfig
>>
>> Lee Jones (1):
>>       UBUNTU: 'fdr editconfig' modification. Easily skip over unwanted
>> menuconfigs.
>>
>>
>>  debian/scripts/misc/kernelconfig |   21 +++++++++++++++------
>>  1 files changed, 15 insertions(+), 6 deletions(-)
>>
>> diff --git a/debian/scripts/misc/kernelconfig
>> b/debian/scripts/misc/kernelconfig
>> index 71c0f5e..3181978 100755 (executable)
>> --- a/debian/scripts/misc/kernelconfig
>> +++ b/debian/scripts/misc/kernelconfig
>> @@ -51,9 +51,6 @@ for arch in $archs; do
>>                 *)      kernarch="$arch"        ;;
>>         esac
>>
>> -       echo ""
>> -       echo "***************************************"
>> -       echo "* Processing $arch ($kernarch) ... "
>>         archconfdir=$confdir/$arch
>>         flavourconfigs=$(cd $archconfdir && ls config.flavour.*)
>>
>> @@ -96,9 +93,21 @@ for arch in $archs; do
>>                                 make O=`pwd`/build ARCH=$kernarch
>> oldconfig ;;
>>                             editconfig)
>>                                 # Interactively edit config parameters
>> -                               echo " * Run menuconfig on
>> $arch/$config... Press a key."
>> -                               read
>> -                               make O=`pwd`/build ARCH=$kernarch
>> menuconfig ;;
>> +                               while : ; do
>> +                                       echo -n "Do you want to edit
>> config: $arch/$config? [Y/n] "
>> +                                       read choice
>> +
>> +                                       case "$choice" in
>> +                                       y* | Y* | "" )
>> +                                               make O=`pwd`/build
>> ARCH=$kernarch menuconfig
>> +                                               break ;;
>> +                                       n* | N* )
>> +                                               break ;;
>> +                                       *)
>> +                                               echo "Entry not valid"
>> +                                       esac
>> +                               done
>> +                               ;;
>>                             *)  # Bad!
>>                                 exit 1 ;;
>>                         esac
>>
>> Kind regards,
>> Lee
>>
>>
>
> I don't know why it insists on line wrapping!
>
> Is this still suitable?
>

I guess Thunderbird needs training, see Documentation/email-clients.txt

The idea is good. Yet not sure if it's better for fdr editconfig to
accept a list
of flavors to edit? i.e. fdr editconfig ti-omap
Lee Jones - June 2, 2010, 8:21 a.m.
> I guess Thunderbird needs training, see Documentation/email-clients.txt
>   

Excellent, thanks.

> The idea is good. Yet not sure if it's better for fdr editconfig to
> accept a list
> of flavors to edit? i.e. fdr editconfig ti-omap
>   

I made this patch out of need, as I was becoming fast fed-up with the
process whist working on a bug.

If you, or anyone else for that matter have any more suggestions, I'd be
glad to carry them out.

Naturally I'd have to have a chat with my supervisor first, as I believe
my workload is going to increase fairly rapidly over the upcoming
days/weeks.
Amit Kucheria - June 2, 2010, 9:23 a.m.
On 10 Jun 02, Lee Jones wrote:
> 
> > I guess Thunderbird needs training, see Documentation/email-clients.txt
> >   
> 
> Excellent, thanks.
> 
> > The idea is good. Yet not sure if it's better for fdr editconfig to
> > accept a list
> > of flavors to edit? i.e. fdr editconfig ti-omap
> >   
> 
> I made this patch out of need, as I was becoming fast fed-up with the
> process whist working on a bug.
> 
> If you, or anyone else for that matter have any more suggestions, I'd be
> glad to carry them out.
> 
> Naturally I'd have to have a chat with my supervisor first, as I believe
> my workload is going to increase fairly rapidly over the upcoming
> days/weeks.

IMO, y/n is a good enough improvement now.

Listing flavours means maintaining that list somewhere. Too much overhead
since our flavours are changing constantly.

A further improvement could be to add a higher level loop to ask if a certain
arch configs should be entered. So,

x86 configs. Edit? [y/n] N
x86_64 configs. Edit? [y/n] N
arm configs. Edit? [y/n] Y
Lee Jones - June 2, 2010, 9:29 a.m.
> A further improvement could be to add a higher level loop to ask if a certain
> arch configs should be entered. So,
>
> x86 configs. Edit? [y/n] N
> x86_64 configs. Edit? [y/n] N
> arm configs. Edit? [y/n] Y
>   

This would complicate things a little.

The 'pre-loop' idea would consist of the same logic required for a full
menu system (my original edit).

The editconfig system has been sped-up ten-fold by this patch and I can
traverse to the menuconfig I need in seconds. Any more time-saving would
be non-trivial and non-significant in my opinion.

Kind regards,
Lee
Amit Kucheria - June 2, 2010, 9:47 a.m.
On 10 Jun 02, Lee Jones wrote:
> 
> > A further improvement could be to add a higher level loop to ask if a certain
> > arch configs should be entered. So,
> >
> > x86 configs. Edit? [y/n] N
> > x86_64 configs. Edit? [y/n] N
> > arm configs. Edit? [y/n] Y
> >   
> 
> This would complicate things a little.
> 
> The 'pre-loop' idea would consist of the same logic required for a full
> menu system (my original edit).
> 
> The editconfig system has been sped-up ten-fold by this patch and I can
> traverse to the menuconfig I need in seconds. Any more time-saving would
> be non-trivial and non-significant in my opinion.
> 
> Kind regards,
> Lee

I should have stated that better than 'IMO, y/n is a good enough improvement
now.'

For the current patch,

Acked-by: Amit Kucheria <amit.kucheria@canonical.com>

The per-arch idea was just a followup to this. :)
Chase Douglas - June 2, 2010, 11:29 a.m.
On Wed, 2010-06-02 at 08:50 +0100, Lee Jones wrote:
> All,
> 
> It is now easier to edit 'per-flavour' configuration files. The old
> system forced the developer to enter a menuconfig system for each
> flavour until eventually landing in the required one. After following
> this process numerous times it can easily become tedious. Now the
> developer is asked whether they want to enter each menuconfig in turn,
> rapidly speeding up the process.
> 
> The following changes since commit a8e1af2ae65acbed1b4e1009a80d2371a484aec9:
>   Leann Ogasawara (1):
>         UBUNTU: Ubuntu-2.6.34-2.9
> 
> are available in the git repository at:
> 
>   git://kernel.ubuntu.com/lag/ubuntu-maverick.git editconfig
> 
> Lee Jones (1):
>       UBUNTU: 'fdr editconfig' modification. Easily skip over unwanted
> menuconfigs.
> 
> 
>  debian/scripts/misc/kernelconfig |   21 +++++++++++++++------
>  1 files changed, 15 insertions(+), 6 deletions(-)
> 
> diff --git a/debian/scripts/misc/kernelconfig
> b/debian/scripts/misc/kernelconfig
> index 71c0f5e..3181978 100755 (executable)
> --- a/debian/scripts/misc/kernelconfig
> +++ b/debian/scripts/misc/kernelconfig
> @@ -51,9 +51,6 @@ for arch in $archs; do
>                 *)      kernarch="$arch"        ;;
>         esac
>  
> -       echo ""
> -       echo "***************************************"
> -       echo "* Processing $arch ($kernarch) ... "
>         archconfdir=$confdir/$arch
>         flavourconfigs=$(cd $archconfdir && ls config.flavour.*)
>  
> @@ -96,9 +93,21 @@ for arch in $archs; do
>                                 make O=`pwd`/build ARCH=$kernarch
> oldconfig ;;
>                             editconfig)
>                                 # Interactively edit config parameters
> -                               echo " * Run menuconfig on
> $arch/$config... Press a key."
> -                               read
> -                               make O=`pwd`/build ARCH=$kernarch
> menuconfig ;;
> +                               while : ; do
> +                                       echo -n "Do you want to edit
> config: $arch/$config? [Y/n] "
> +                                       read choice
> +                                      
> +                                       case "$choice" in
> +                                       y* | Y* | "" )
> +                                               make O=`pwd`/build
> ARCH=$kernarch menuconfig
> +                                               break ;;
> +                                       n* | N* )
> +                                               break ;;
> +                                       *)
> +                                               echo "Entry not valid"
> +                                       esac
> +                               done
> +                               ;;
>                             *)  # Bad!
>                                 exit 1 ;;
>                         esac

Keeps the current functionality, and speeds things up when the user
doesn't need to change anything to a specific config.

Acked-by: Chase Douglas <chase.douglas@canonical.com>
Lee Jones - June 2, 2010, 12:12 p.m.
> Acked-by: Amit Kucheria <amit.kucheria@canonical.com>
> Acked-by: Chase Douglas <chase.douglas@canonical.com>
>   

Thanks gents.
Leann Ogasawara - June 7, 2010, 8:53 p.m.
Applied to Maverick master.

Thanks,
Leann

Patch

diff --git a/debian/scripts/misc/kernelconfig
b/debian/scripts/misc/kernelconfig
index 71c0f5e..3181978 100755 (executable)
--- a/debian/scripts/misc/kernelconfig
+++ b/debian/scripts/misc/kernelconfig
@@ -51,9 +51,6 @@  for arch in $archs; do
                *)      kernarch="$arch"        ;;
        esac
 
-       echo ""
-       echo "***************************************"
-       echo "* Processing $arch ($kernarch) ... "
        archconfdir=$confdir/$arch
        flavourconfigs=$(cd $archconfdir && ls config.flavour.*)
 
@@ -96,9 +93,21 @@  for arch in $archs; do
                                make O=`pwd`/build ARCH=$kernarch
oldconfig ;;
                            editconfig)
                                # Interactively edit config parameters
-                               echo " * Run menuconfig on
$arch/$config... Press a key."
-                               read
-                               make O=`pwd`/build ARCH=$kernarch
menuconfig ;;
+                               while : ; do
+                                       echo -n "Do you want to edit
config: $arch/$config? [Y/n] "
+                                       read choice
+                                      
+                                       case "$choice" in
+                                       y* | Y* | "" )
+                                               make O=`pwd`/build
ARCH=$kernarch menuconfig
+                                               break ;;
+                                       n* | N* )
+                                               break ;;
+                                       *)
+                                               echo "Entry not valid"
+                                       esac