sm-discuss AT lists.ibiblio.org
Subject: Public SourceMage Discussion List
List archive
- From: David Kowis <dkowis AT shlrm.org>
- To: sm-discuss AT lists.ibiblio.org
- Subject: Re: [SM-Discuss] Spell branches
- Date: Mon, 12 Sep 2011 09:12:37 -0500
On 09/11/2011 08:47 PM, Ismael Luceno wrote:
> Some spells support multiple branches. I would like to remove the
> duplication to certain extent, by adding a new function that would
> take a list of branches, query which one the user wants and if it
> should be updated automatically (if applicable).
I don't think that would be a bad idea. I say go for it.
>
> Something like:
>
> function select_branch() {
> local spell="$1" tmp &&
> shift &&
>
> if [[ $# > 1 ]]; then
> config_query_list "$spell"_BRANCH \
> "Select one of the available branches:" "$@" &&
> eval tmp=\$"$spell"_BRANCH
> else
> eval "$spell"_BRANCH=\""$1"\" &&
> tmp="$1"
> fi &&
>
> if [[ "${tmp/-*}" = scm ]]; then
> config_query "$spell"_SCM_AUTOUPDATE \
> 'Update on every system update?' n
> fi
> }
>
>
> Opinions?
>
>
>
> _______________________________________________
> SM-Discuss mailing list
> SM-Discuss AT lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/sm-discuss
>
>
> !DSPAM:2,4e6d6dd071061877274419!
Attachment:
signature.asc
Description: OpenPGP digital signature
-
[SM-Discuss] Spell branches,
Ismael Luceno, 09/11/2011
- Re: [SM-Discuss] Spell branches, David Kowis, 09/12/2011
-
Re: [SM-Discuss] Spell branches,
Bor Kraljič, 09/12/2011
-
Re: [SM-Discuss] Spell branches,
flux, 09/12/2011
- Re: [SM-Discuss] Spell branches, Bor Kraljič, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
Ismael Luceno, 09/13/2011
- Re: [SM-Discuss] Spell branches, Bor Kraljič, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
flux, 09/12/2011
-
Re: [SM-Discuss] Spell branches,
flux, 09/12/2011
-
Re: [SM-Discuss] Spell branches,
Ismael Luceno, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
flux, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
Ismael Luceno, 09/13/2011
- Re: [SM-Discuss] Spell branches, flux, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
Ismael Luceno, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
flux, 09/13/2011
-
Re: [SM-Discuss] Spell branches,
Ismael Luceno, 09/13/2011
Archive powered by MHonArc 2.6.24.