All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] semodule: Fix the --list-modules=full example in the manpage
@ 2016-05-17 15:27 Laurent Bigonville
  2016-05-18  7:57 ` Petr Lautrbach
  0 siblings, 1 reply; 7+ messages in thread
From: Laurent Bigonville @ 2016-05-17 15:27 UTC (permalink / raw)
  To: selinux

From: Laurent Bigonville <bigon@bigon.be>

---
 policycoreutils/semodule/semodule.8 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
index 68e95ab..7b07c45 100644
--- a/policycoreutils/semodule/semodule.8
+++ b/policycoreutils/semodule/semodule.8
@@ -116,7 +116,7 @@ $ semodule \-d alsa
 # Install a module at a specific priority.
 $ semodule \-X 100 \-i alsa.pp
 # List all modules.
-$ semodule \-l full
+$ semodule \-\-list-modules=full
 # Set an alternate path for the policy root
 $ semodule \-B \-p "/tmp"
 # Set an alternate path for the policy store root
-- 
2.8.1

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] semodule: Fix the --list-modules=full example in the manpage
  2016-05-17 15:27 [PATCH] semodule: Fix the --list-modules=full example in the manpage Laurent Bigonville
@ 2016-05-18  7:57 ` Petr Lautrbach
  2016-05-18 10:00   ` Dalibor Pospíšil
  2016-05-20 19:48   ` Stephen Smalley
  0 siblings, 2 replies; 7+ messages in thread
From: Petr Lautrbach @ 2016-05-18  7:57 UTC (permalink / raw)
  To: Laurent Bigonville, selinux

[-- Attachment #1: Type: text/plain, Size: 1403 bytes --]

On 05/17/2016 05:27 PM, Laurent Bigonville wrote:
> From: Laurent Bigonville <bigon@bigon.be>
> 
> ---
>  policycoreutils/semodule/semodule.8 | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
> index 68e95ab..7b07c45 100644
> --- a/policycoreutils/semodule/semodule.8
> +++ b/policycoreutils/semodule/semodule.8
> @@ -116,7 +116,7 @@ $ semodule \-d alsa
>  # Install a module at a specific priority.
>  $ semodule \-X 100 \-i alsa.pp
>  # List all modules.
> -$ semodule \-l full
> +$ semodule \-\-list-modules=full


It works without " " before full:

$ semodule -lfull

What about:

policycoreutils/semodule/semodule.8:

 .TP
-.B  \-l,\-\-list-modules=[KIND]
+.B  \-l[KIND],\-\-list-modules[=KIND]
 display list of installed modules (other than base)

 # List all modules.
-$ semodule \-l full
+$ semodule \-lfull
 # Set an alternate path for the policy root


policycoreutils/semodule/semodule.c:

        printf("  -r,--remove=MODULE_NAME   remove existing module\n");
-       printf("  -l,--list-modules=[KIND]  display list of installed
modules\n");
+       printf("  -l[KIND],--list-modules[=KIND]  display list of
installed modules\n");
        printf("     KIND:  standard  list highest priority, enabled
modules\n");



-- 
Petr Lautrbach



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] semodule: Fix the --list-modules=full example in the manpage
  2016-05-18  7:57 ` Petr Lautrbach
@ 2016-05-18 10:00   ` Dalibor Pospíšil
  2016-05-18 14:11     ` Dalibor Pospíšil
  2016-05-20 19:48   ` Stephen Smalley
  1 sibling, 1 reply; 7+ messages in thread
From: Dalibor Pospíšil @ 2016-05-18 10:00 UTC (permalink / raw)
  To: Petr Lautrbach, Laurent Bigonville, selinux

[-- Attachment #1: Type: text/plain, Size: 1884 bytes --]

*Date: *Wed May 18 2016 09:57:47 GMT+0200 (CEST)
> On 05/17/2016 05:27 PM, Laurent Bigonville wrote:
>> From: Laurent Bigonville <bigon@bigon.be>
>>
>> ---
>>   policycoreutils/semodule/semodule.8 | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
>> index 68e95ab..7b07c45 100644
>> --- a/policycoreutils/semodule/semodule.8
>> +++ b/policycoreutils/semodule/semodule.8
>> @@ -116,7 +116,7 @@ $ semodule \-d alsa
>>   # Install a module at a specific priority.
>>   $ semodule \-X 100 \-i alsa.pp
>>   # List all modules.
>> -$ semodule \-l full
>> +$ semodule \-\-list-modules=full
> It works without " " before full:
>
> $ semodule -lfull
>
> What about:
>
> policycoreutils/semodule/semodule.8:
>
>   .TP
> -.B  \-l,\-\-list-modules=[KIND]
> +.B  \-l[KIND],\-\-list-modules[=KIND]
>   display list of installed modules (other than base)
>
>   # List all modules.
> -$ semodule \-l full
> +$ semodule \-lfull
Wouldn't it be more natural to use 'all' instead of 'full' to express listing of all modules? I would expect 'full' as an option to some kind of formatting, like displaying full details.
>   # Set an alternate path for the policy root
>
>
> policycoreutils/semodule/semodule.c:
>
>          printf("  -r,--remove=MODULE_NAME   remove existing module\n");
> -       printf("  -l,--list-modules=[KIND]  display list of installed
> modules\n");
> +       printf("  -l[KIND],--list-modules[=KIND]  display list of
> installed modules\n");
>          printf("     KIND:  standard  list highest priority, enabled
> modules\n");
>
>
>
>
>
> _______________________________________________
> Selinux mailing list
> Selinux@tycho.nsa.gov
> To unsubscribe, send email to Selinux-leave@tycho.nsa.gov.
> To get help, send an email containing "help" to Selinux-request@tycho.nsa.gov.


[-- Attachment #2: Type: text/html, Size: 2767 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] semodule: Fix the --list-modules=full example in the manpage
  2016-05-18 10:00   ` Dalibor Pospíšil
@ 2016-05-18 14:11     ` Dalibor Pospíšil
  0 siblings, 0 replies; 7+ messages in thread
From: Dalibor Pospíšil @ 2016-05-18 14:11 UTC (permalink / raw)
  To: selinux

[-- Attachment #1: Type: text/plain, Size: 2347 bytes --]

*Date: *Wed May 18 2016 12:00:11 GMT+0200 (CEST)
> *Date: *Wed May 18 2016 09:57:47 GMT+0200 (CEST)
>> On 05/17/2016 05:27 PM, Laurent Bigonville wrote:
>>> From: Laurent Bigonville<bigon@bigon.be>
>>>
>>> ---
>>>   policycoreutils/semodule/semodule.8 | 2 +-
>>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
>>> index 68e95ab..7b07c45 100644
>>> --- a/policycoreutils/semodule/semodule.8
>>> +++ b/policycoreutils/semodule/semodule.8
>>> @@ -116,7 +116,7 @@ $ semodule \-d alsa
>>>   # Install a module at a specific priority.
>>>   $ semodule \-X 100 \-i alsa.pp
>>>   # List all modules.
>>> -$ semodule \-l full
>>> +$ semodule \-\-list-modules=full
>> It works without " " before full:
>>
>> $ semodule -lfull
>>
>> What about:
>>
>> policycoreutils/semodule/semodule.8:
>>
>>   .TP
>> -.B  \-l,\-\-list-modules=[KIND]
>> +.B  \-l[KIND],\-\-list-modules[=KIND]
>>   display list of installed modules (other than base)
>>
>>   # List all modules.
>> -$ semodule \-l full
>> +$ semodule \-lfull
> Wouldn't it be more natural to use 'all' instead of 'full' to express listing of all modules? I would expect 'full' as an option to some kind of formatting, like displaying full details.
After discussion with Petr the 'full' kind makes sens. Actually I haven't tried it I just read the documentation which does not say much about this. Maybe it would be good to extend documentation to better describe 'full' kind, not just say it lists all modules. I would suggest something like 'long/detailed listing of (all) modules', similarly to ls -l.
>>   # Set an alternate path for the policy root
>>
>>
>> policycoreutils/semodule/semodule.c:
>>
>>          printf("  -r,--remove=MODULE_NAME   remove existing module\n");
>> -       printf("  -l,--list-modules=[KIND]  display list of installed
>> modules\n");
>> +       printf("  -l[KIND],--list-modules[=KIND]  display list of
>> installed modules\n");
>>          printf("     KIND:  standard  list highest priority, enabled
>> modules\n");
>>
>>
>>
>>
>>
>> _______________________________________________
>> Selinux mailing list
>> Selinux@tycho.nsa.gov
>> To unsubscribe, send email toSelinux-leave@tycho.nsa.gov.
>> To get help, send an email containing "help" toSelinux-request@tycho.nsa.gov.
>


[-- Attachment #2: Type: text/html, Size: 3668 bytes --]

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] semodule: Fix the --list-modules=full example in the manpage
  2016-05-18  7:57 ` Petr Lautrbach
  2016-05-18 10:00   ` Dalibor Pospíšil
@ 2016-05-20 19:48   ` Stephen Smalley
  2016-05-24  8:02     ` [PATCH] policycoreutils/semodule: Fix the documentation of -l,--list Petr Lautrbach
  1 sibling, 1 reply; 7+ messages in thread
From: Stephen Smalley @ 2016-05-20 19:48 UTC (permalink / raw)
  To: Petr Lautrbach, Laurent Bigonville, selinux

On 05/18/2016 03:57 AM, Petr Lautrbach wrote:
> On 05/17/2016 05:27 PM, Laurent Bigonville wrote:
>> From: Laurent Bigonville <bigon@bigon.be>
>> 
>> --- policycoreutils/semodule/semodule.8 | 2 +- 1 file changed, 1
>> insertion(+), 1 deletion(-)
>> 
>> diff --git a/policycoreutils/semodule/semodule.8
>> b/policycoreutils/semodule/semodule.8 index 68e95ab..7b07c45
>> 100644 --- a/policycoreutils/semodule/semodule.8 +++
>> b/policycoreutils/semodule/semodule.8 @@ -116,7 +116,7 @@ $
>> semodule \-d alsa # Install a module at a specific priority. $
>> semodule \-X 100 \-i alsa.pp # List all modules. -$ semodule \-l
>> full +$ semodule \-\-list-modules=full
> 
> 
> It works without " " before full:
> 
> $ semodule -lfull
> 
> What about:
> 
> policycoreutils/semodule/semodule.8:
> 
> .TP -.B  \-l,\-\-list-modules=[KIND] +.B
> \-l[KIND],\-\-list-modules[=KIND] display list of installed modules
> (other than base)
> 
> # List all modules. -$ semodule \-l full +$ semodule \-lfull # Set
> an alternate path for the policy root
> 
> 
> policycoreutils/semodule/semodule.c:
> 
> printf("  -r,--remove=MODULE_NAME   remove existing module\n"); -
> printf("  -l,--list-modules=[KIND]  display list of installed 
> modules\n"); +       printf("  -l[KIND],--list-modules[=KIND]
> display list of installed modules\n"); printf("     KIND:  standard
> list highest priority, enabled modules\n");

That works for me.  Someone want to spin an actual patch?  Although
the -l argument handling is somewhat odd and non-standard; if it
wasn't already in place, I think I'd have advocated for a separate
option flag if you want the full/long listing.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] policycoreutils/semodule: Fix the documentation of -l,--list
  2016-05-20 19:48   ` Stephen Smalley
@ 2016-05-24  8:02     ` Petr Lautrbach
  2016-06-06 17:12       ` James Carter
  0 siblings, 1 reply; 7+ messages in thread
From: Petr Lautrbach @ 2016-05-24  8:02 UTC (permalink / raw)
  To: selinux

It wasn't clear how to use -l option with full/standard KIND and the
example in semodule.8 man page was wrong.

Based on a patch by Laurent Bigonville <bigon@bigon.be>
Signed-off-by: Petr Lautrbach <plautrba@redhat.com>
---
 policycoreutils/semodule/semodule.8 | 4 ++--
 policycoreutils/semodule/semodule.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
index 68e95ab..0c5fdf7 100644
--- a/policycoreutils/semodule/semodule.8
+++ b/policycoreutils/semodule/semodule.8
@@ -38,7 +38,7 @@ deprecated, alias for --install
 .B  \-r,\-\-remove=MODULE_NAME
 remove existing module
 .TP
-.B  \-l,\-\-list-modules=[KIND]
+.B  \-l[KIND],\-\-list-modules[=KIND]
 display list of installed modules (other than base)
 .TP
 .B  \-E,\-\-extract=MODULE_PKG
@@ -116,7 +116,7 @@ $ semodule \-d alsa
 # Install a module at a specific priority.
 $ semodule \-X 100 \-i alsa.pp
 # List all modules.
-$ semodule \-l full
+$ semodule \-\-list=full
 # Set an alternate path for the policy root
 $ semodule \-B \-p "/tmp"
 # Set an alternate path for the policy store root
diff --git a/policycoreutils/semodule/semodule.c b/policycoreutils/semodule/semodule.c
index bcfaa2b..63900f4 100644
--- a/policycoreutils/semodule/semodule.c
+++ b/policycoreutils/semodule/semodule.c
@@ -127,7 +127,7 @@ static void usage(char *progname)
 	printf("  -B, --build		    build and reload policy\n");
 	printf("  -i,--install=MODULE_PKG   install a new module\n");
 	printf("  -r,--remove=MODULE_NAME   remove existing module\n");
-	printf("  -l,--list-modules=[KIND]  display list of installed modules\n");
+	printf("  -l[KIND],--list-modules[=KIND]  display list of installed modules\n");
 	printf("     KIND:  standard  list highest priority, enabled modules\n");
 	printf("            full      list all modules\n");
 	printf("  -X,--priority=PRIORITY    set priority for following operations (1-999)\n");
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] policycoreutils/semodule: Fix the documentation of -l,--list
  2016-05-24  8:02     ` [PATCH] policycoreutils/semodule: Fix the documentation of -l,--list Petr Lautrbach
@ 2016-06-06 17:12       ` James Carter
  0 siblings, 0 replies; 7+ messages in thread
From: James Carter @ 2016-06-06 17:12 UTC (permalink / raw)
  To: Petr Lautrbach, selinux

On 05/24/2016 04:02 AM, Petr Lautrbach wrote:
> It wasn't clear how to use -l option with full/standard KIND and the
> example in semodule.8 man page was wrong.
>
> Based on a patch by Laurent Bigonville <bigon@bigon.be>
> Signed-off-by: Petr Lautrbach <plautrba@redhat.com>

Applied.

Thanks,

> ---
>  policycoreutils/semodule/semodule.8 | 4 ++--
>  policycoreutils/semodule/semodule.c | 2 +-
>  2 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/policycoreutils/semodule/semodule.8 b/policycoreutils/semodule/semodule.8
> index 68e95ab..0c5fdf7 100644
> --- a/policycoreutils/semodule/semodule.8
> +++ b/policycoreutils/semodule/semodule.8
> @@ -38,7 +38,7 @@ deprecated, alias for --install
>  .B  \-r,\-\-remove=MODULE_NAME
>  remove existing module
>  .TP
> -.B  \-l,\-\-list-modules=[KIND]
> +.B  \-l[KIND],\-\-list-modules[=KIND]
>  display list of installed modules (other than base)
>  .TP
>  .B  \-E,\-\-extract=MODULE_PKG
> @@ -116,7 +116,7 @@ $ semodule \-d alsa
>  # Install a module at a specific priority.
>  $ semodule \-X 100 \-i alsa.pp
>  # List all modules.
> -$ semodule \-l full
> +$ semodule \-\-list=full
>  # Set an alternate path for the policy root
>  $ semodule \-B \-p "/tmp"
>  # Set an alternate path for the policy store root
> diff --git a/policycoreutils/semodule/semodule.c b/policycoreutils/semodule/semodule.c
> index bcfaa2b..63900f4 100644
> --- a/policycoreutils/semodule/semodule.c
> +++ b/policycoreutils/semodule/semodule.c
> @@ -127,7 +127,7 @@ static void usage(char *progname)
>  	printf("  -B, --build		    build and reload policy\n");
>  	printf("  -i,--install=MODULE_PKG   install a new module\n");
>  	printf("  -r,--remove=MODULE_NAME   remove existing module\n");
> -	printf("  -l,--list-modules=[KIND]  display list of installed modules\n");
> +	printf("  -l[KIND],--list-modules[=KIND]  display list of installed modules\n");
>  	printf("     KIND:  standard  list highest priority, enabled modules\n");
>  	printf("            full      list all modules\n");
>  	printf("  -X,--priority=PRIORITY    set priority for following operations (1-999)\n");
>


-- 
James Carter <jwcart2@tycho.nsa.gov>
National Security Agency

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2016-06-06 17:12 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-05-17 15:27 [PATCH] semodule: Fix the --list-modules=full example in the manpage Laurent Bigonville
2016-05-18  7:57 ` Petr Lautrbach
2016-05-18 10:00   ` Dalibor Pospíšil
2016-05-18 14:11     ` Dalibor Pospíšil
2016-05-20 19:48   ` Stephen Smalley
2016-05-24  8:02     ` [PATCH] policycoreutils/semodule: Fix the documentation of -l,--list Petr Lautrbach
2016-06-06 17:12       ` James Carter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.