Skip to content
/ firstly Public

Convert Between Numeric, Spelt, and Short & Long Ordinal Forms of Numbers

Notifications You must be signed in to change notification settings

dahu/firstly

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Firstly

Convert between the twelve forms of numeric, written and ordinal numbers:

From   To     Use
--------------------------------
1      one    NumToNumber()
1      1st    NumToOrd()
1      first  NumToOrdinal()
one    1      NumberToNum()
one    1st    NumberToOrd()
one    first  NumberToOrdinal()
1st    1      OrdToNum()
1st    one    OrdToNumber()
1st    first  OrdToOrdinal()
first  1      OrdinalToNum()
first  one    OrdinalToNumber()
first  1st    OrdinalToOrd()

Each function accepts an optional second parameter to control the
capitalisation of the return value (where appropriate):

Value  Means
-----------------------------
0      all lower case
1      Leading capital letter
2      Title Case
3      ALL CAPS

Requires Salman Halim's NumberToEnglish plugin:
http://www.vim.org/scripts/script.php?script_id=2561

NOTE: The NumberToEnglish plugin (at least version 1.4 does) might have CRLF
      line terminators which cause an error message on unix systems. Use
      dos2unix to fix this problem.

About

Convert Between Numeric, Spelt, and Short & Long Ordinal Forms of Numbers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published