Template talk:App

From ArchWiki
Revision as of 14:37, 2 June 2013 by Kynikos (talk | contribs) (close ancient comment)
Jump to: navigation, search


I like it.
Trying to make the url small, so far with no results. I apparently broke the template because it shows small here, but not in articles. manolo 13:35, 13 November 2009 (EST)

Introducing default argument

This was proposed by User:Kynikos and myself (see Template_talk:AUR?); difference is in default contents. Again my proposal:

{{{1}}} — {{{2}}}
: {{{3}}} || {{{4|{{AUR?{{1}}}}}

Kynikos proposed:

{{{1}}} — {{{2}}}
: {{{3}}} || {{{4|not packaged? [https://aur.archlinux.org/ search in AUR]}}}

More opinions?

--AlexanderR 18:42, 30 January 2012 (EST)

I'm afraid your solution wouldn't work when the first argument receives a link because an article exists but there's no package available. A working compromise solution could be:
[[{{{1}}}]] — {{{2}}}
: {{{3}}} || {{{4|not packaged? [https://aur.archlinux.org/packages.php?K={{urlencode:{{{1}}}}} search in AUR]}}}
Argument 1 takes a simple string which should be the name of an (existing or not) internal article. This will create many red links but it may be acceptable if we consider Special:WantedPages.
Note that the source of Template:AUR? is directly included here, since it's pointless to have a separate short template that is used only here.
However my initial proposal is still my first choice: my considerations are all explained in detail in Template talk:AUR?#Opinions.
-- Kynikos 07:53, 1 February 2012 (EST)
>> first argument receives a link
Oups :)!
>> compromise solution
This was discussed a lot in the past and reached consensus seems to be the best possible for me. I guess, I should fall back to my previous suggestion (e.g. usage of separate Template:AUR? with appropriate keywords). Taking into account that 1st argument of Template:App by design can contain everything, there seems to be no way to easily extract title without hand work :(. And... wait, maybe this:
{{{1}}} — {{{2}}}
: {{{3}}} || {{{4|{{AUR?|}}}}}
? --AlexanderR 10:56, 1 February 2012 (EST)
Sorry, I don't get it, your last example just points to a search for the empty string as the default value for 4. And I've not understood why you would keep it in a separate template (AUR?). -- Kynikos 08:55, 4 February 2012 (EST)
My thoughts:
  1. I think Template:AUR? is unnecessary, and would prefer simply linking to the AUR home page as Kynikos suggests.
  2. The first argument should remain unformatted so that it can contain internal/interwiki links ... or anything else.
-- pointone 12:41, 4 February 2012 (EST)
>> your last example just points to a search for the empty string
>> would prefer simply linking to the AUR home page
Suggest better way to find all instances of Template:App with blank package field. Idea behind Template:AUR? is the same as behind Template:Error + give users unified way to fill package field when there is no package available. --AlexanderR 06:46, 5 February 2012 (EST)
Ah, so you meant to use Template:AUR? in the vein of Template:Error, this wasn't clear at all, now I get it. Then, since AUR? should never be used explicitly, I'd rename it as Template:Missing Package and change its code to just <includeonly>not packaged? [https://aur.archlinux.org/ search in AUR]</includeonly>.
The code for Template:App would become:
<includeonly>{{{1}}} &mdash; {{{2}}}
: {{{3}}} || {{{4|{{Missing Package}}}}}</includeonly>
-- Kynikos 07:51, 8 February 2012 (EST)
Also the text in the template page should be changed to be similar to that of Template:Error, and we should explicitly link to Special:WhatLinksHere/Template:Missing Package from some article, probably directly from Template:Missing Package. -- Kynikos 07:54, 8 February 2012 (EST)