Vim Tips Wiki
m (Slight reword of technical restrictions.)
(Add colon + percent to "avoid in title".)
Line 1: Line 1:
 
{{NavPolicy}}
 
{{NavPolicy}}
   
== In short ==
+
==In short==
 
The URL referring to a tip should be short, simple and meaningful. That will help if you need to post a link to a tip in a web page or mailing list.
 
The URL referring to a tip should be short, simple and meaningful. That will help if you need to post a link to a tip in a web page or mailing list.
   
Line 19: Line 19:
 
These characters are possible, but should be avoided in almost all cases:
 
These characters are possible, but should be avoided in almost all cases:
   
? + _
+
? + _ : %
   
== Examples and explanations ==
+
==Examples and explanations==
   
 
All punctuation and extraneous words should be avoided. For example, [[VimTip305]] had the title:
 
All punctuation and extraneous words should be avoided. For example, [[VimTip305]] had the title:

Revision as of 03:17, 2 August 2007

Vim Tip Guidelines
Quick reference
General guidelines
Titles and renaming a tip
Comments
Categories
Discussion page
Merging similar tips
Deleting a tip
Templates
Formatting code blocks
Entities and other magic
Script comments

In short

The URL referring to a tip should be short, simple and meaningful. That will help if you need to post a link to a tip in a web page or mailing list.

To achieve a short, simple and meaningful URL, the title for a tip:

  • Should be short.
  • Should avoid punctuation.
  • Should use words referring to the problem solved by the tip.

There is no need for a title to use extreme precision. If someone is interested in tips on searching, they will look at any tip with "search" in the title. The title does not need to precisely describe the search method.

Apart from making an ugly URL, there are lots of characters that cause trouble in a title.

These characters are not possible due to technical restrictions:

# < > [ ] | { }

These characters are possible, but should be avoided in almost all cases:

? + _ : %

Examples and explanations

All punctuation and extraneous words should be avoided. For example, VimTip305 had the title:

Best of VIM Tips (VIM's best Features)

The resulting URL is:

http://vim.wikia.com/wiki/Best_of_VIM_Tips_%28VIM%27s_best_Features%29

A better title would be:

Best Vim Tips

which has URL:

http://vim.wikia.com/wiki/Best_Vim_Tips

Remember that a good tip with a bad title is still good, so perhaps your efforts should be spent on improving the tip contents rather than its title.

You should change the title of pages that originally contained an invalid character, such as '['. When the original tips were imported, any '[' characters in a title were replaced with OPENBRACKET.

To change the title of a page, you move the page to one with a new title. If you move a page from Old Title to New Title, the contents, discussion and history of the old page will appear at New Title. In addition, the Old Title page will automatically be changed to a redirect to the new page.

To move a page from Old Title to New Title

  • Open the Old Title page (the page with the title that you want to change).
  • Check what links point to the Old Title page – see "what links here" in the Review box at the top of the page.
  • All imported tips will have at least one link (from the VimTipNumber redirect page).
  • You should change each link to Old Title to be a link to New Title. You will probably only need to change the VimTipNumber redirect page. You will not need to change any pages that link to the VimTipNumber redirect page.
  • On the Old Title page, click the Move tab.
  • On the Move page form, enter the new title and a reason for the move (such as "Simplify title" or "Fix illegal punctuation"). Read the information including the warning, before clicking the Move page button.

Assuming you are working with a tip that was imported from the vim.org tips site, as well as moving the tip page from Old Title to New Title, you will need to fix the link on the VimTipNumber page (and on any other page that used to link to Old Title). If you can't find a way to edit the VimTipNumber page, edit the URL below by replacing "123" with the Number of the tip that you moved.

http://vim.wikia.com/index.php?title=VimTip123&redirect=no

Paste the above URL (edited for the correct tip Number) into the address bar of your browser. On the VimTipNumber page, click Edit. You will see something like:

#REDIRECT [[Old Title]]

You need to change Old Title to New Title.