From 7707a9b80b83a5f2771b5b5292af92c05115e7a9 Mon Sep 17 00:00:00 2001 From: arcan1s Date: Sat, 19 Jul 2014 13:53:25 +0400 Subject: [PATCH] fix typo --- _posts/2014-07-17-writting-own-completions-p1.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_posts/2014-07-17-writting-own-completions-p1.html b/_posts/2014-07-17-writting-own-completions-p1.html index bc2a6c4..443db1e 100644 --- a/_posts/2014-07-17-writting-own-completions-p1.html +++ b/_posts/2014-07-17-writting-own-completions-p1.html @@ -68,7 +68,7 @@ esac

Flags

-

As it was said above, there are some different ways to create these files. In particular they differ in the flag declaration and their further processing. In my case I will use _arguments command, which require a specific format of variables: FLAG[description]:MESSAGE:ACTION. The last two fields are not required and, as you will see below, are not needed in some cases. If you want to add two flags for an action (short and long format), then the format is a little bit complicated: {(FLAG_2)FLAG_1,(FLAG_1)FLAG_2}[description]:MESSAGE:ACTION. It should be noted that if you want to create completions for two flags but some flags have not a second format. you will should to add following line: {FLAG,FLAG}[description]:MESSAGE:ACTION. MESSAGE is a message which will be shown, ACTION is an action whichh will be performed after this flag. In this tutorial ACTION will be following: ->STATE.

+

As it was said above, there are some different ways to create these files. In particular they differ in the flag declaration and their further processing. In my case I will use _arguments command, which require a specific format of variables: FLAG[description]:MESSAGE:ACTION. The last two fields are not required and, as you will see below, are not needed in some cases. If you want to add two flags for an action (short and long format), then the format is a little bit complicated: {(FLAG_2)FLAG_1,(FLAG_1)FLAG_2}[description]:MESSAGE:ACTION. It should be noted that if you want to create completions for two flags but some flags have not a second format. you will should to add following line: {FLAG,FLAG}[description]:MESSAGE:ACTION. MESSAGE is a message which will be shown, ACTION is an action which will be performed after this flag. In this tutorial ACTION will be following: ->STATE.

So, according to our requirements, flags declaration will be following: