Difference between revisions of "Template talk:App"

From ArchWiki
Jump to: navigation, search
(How to use linkrot template?: I think I've got it, closing)
(How to use linkrot template?: rm closed discussion)
Line 50: Line 50:
 
::::::-- [[User:Kynikos|Kynikos]] 07:51, 8 February 2012 (EST)
 
::::::-- [[User:Kynikos|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]]. -- [[User:Kynikos|Kynikos]] 07:54, 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]]. -- [[User:Kynikos|Kynikos]] 07:54, 8 February 2012 (EST)
 
== <s>How to use linkrot template?</s> ==
 
I can't figure out how to mark the app's url as dead. -- [[User:Karol|Karol]] ([[User talk:Karol|talk]]) 21:16, 24 October 2012 (UTC)
 
:The problem is that the parameter for the URL formats it as one, so adding <nowiki>{{linkrot|2012|10|24}}</nowiki> will just get treated as part of the URL. Maybe an optional parameter would be appropriate? There are probably a lot of these app templates with broken links. [[User:Thestinger|thestinger]] ([[User talk:Thestinger|talk]]) 21:22, 24 October 2012 (UTC)
 
::The url is fine and it works if you do it like this:
 
* {{App|QTorrent|A BitTorrent client written in PyQt.|http://thegraveyard.org/qtorrent.php|{{Pkg|qtorrent}}}}{{linkrot|2012|09|26}}
 
or
 
* {{App|QTorrent|A BitTorrent client written in PyQt.|http://thegraveyard.org/qtorrent.php {{linkrot|2012|09|26}}|{{Pkg|qtorrent}}}}
 
:::Does it break anything or can I use it like this? I prefer the second version. -- [[User:Karol|Karol]] ([[User talk:Karol|talk]]) 21:31, 24 October 2012 (UTC)
 
:::I'm not the first one to use it, it seems: [https://wiki.archlinux.org/index.php?title=List_of_Applications/Internet&diff=prev&oldid=225320]. Not sure why was it removed, [https://wiki.archlinux.org/index.php/User_talk:Sudokode see if I can find out]. -- [[User:Karol|Karol]] ([[User talk:Karol|talk]]) 15:47, 25 October 2012 (UTC)
 
::::[https://wiki.archlinux.org/index.php?title=List_of_Applications/Internet&diff=233604&oldid=232163 I've re-added the linkrot info], seems to work. Closing. -- [[User:Karol|Karol]] ([[User talk:Karol|talk]]) 14:42, 4 November 2012 (UTC)
 

Revision as of 15:15, 8 November 2012

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}}} &mdash; {{{2}}}
: {{{3}}} || {{{4|{{AUR?{{1}}}}}

Kynikos proposed:

{{{1}}} &mdash; {{{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}}}]] &mdash; {{{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)