Permalink
Browse files

first commit

  • Loading branch information...
0 parents commit beea5a23eb10e13889c8c81ecd46a42b32a74c1b chrisdew committed Feb 2, 2011
Showing with 16,507 additions and 0 deletions.
  1. +17 −0 LICENSE
  2. +18 −0 README.md
  3. +104 −0 lib/date-af-ZA.js
  4. +104 −0 lib/date-ar-AE.js
  5. +104 −0 lib/date-ar-BH.js
  6. +104 −0 lib/date-ar-DZ.js
  7. +104 −0 lib/date-ar-EG.js
  8. +104 −0 lib/date-ar-IQ.js
  9. +104 −0 lib/date-ar-JO.js
  10. +104 −0 lib/date-ar-KW.js
  11. +104 −0 lib/date-ar-LB.js
  12. +104 −0 lib/date-ar-LY.js
  13. +104 −0 lib/date-ar-MA.js
  14. +104 −0 lib/date-ar-OM.js
  15. +104 −0 lib/date-ar-QA.js
  16. +104 −0 lib/date-ar-SA.js
  17. +104 −0 lib/date-ar-SY.js
  18. +104 −0 lib/date-ar-TN.js
  19. +104 −0 lib/date-ar-YE.js
  20. +104 −0 lib/date-az-Cyrl-AZ.js
  21. +104 −0 lib/date-az-Latn-AZ.js
  22. +104 −0 lib/date-be-BY.js
  23. +104 −0 lib/date-bg-BG.js
  24. +104 −0 lib/date-bs-Latn-BA.js
  25. +104 −0 lib/date-ca-ES.js
  26. +104 −0 lib/date-cs-CZ.js
  27. +104 −0 lib/date-cy-GB.js
  28. +104 −0 lib/date-da-DK.js
  29. +104 −0 lib/date-de-AT.js
  30. +104 −0 lib/date-de-CH.js
  31. +104 −0 lib/date-de-DE.js
  32. +104 −0 lib/date-de-LI.js
  33. +104 −0 lib/date-de-LU.js
  34. +104 −0 lib/date-dv-MV.js
  35. +104 −0 lib/date-el-GR.js
  36. +104 −0 lib/date-en-029.js
  37. +104 −0 lib/date-en-AU.js
  38. +104 −0 lib/date-en-BZ.js
  39. +104 −0 lib/date-en-CA.js
  40. +104 −0 lib/date-en-GB.js
  41. +104 −0 lib/date-en-IE.js
  42. +104 −0 lib/date-en-JM.js
  43. +104 −0 lib/date-en-NZ.js
  44. +104 −0 lib/date-en-PH.js
  45. +104 −0 lib/date-en-TT.js
  46. +104 −0 lib/date-en-US.js
  47. +104 −0 lib/date-en-ZA.js
  48. +104 −0 lib/date-en-ZW.js
  49. +104 −0 lib/date-es-AR.js
  50. +104 −0 lib/date-es-BO.js
  51. +104 −0 lib/date-es-CL.js
  52. +104 −0 lib/date-es-CO.js
  53. +104 −0 lib/date-es-CR.js
  54. +104 −0 lib/date-es-DO.js
  55. +104 −0 lib/date-es-EC.js
  56. +104 −0 lib/date-es-ES.js
  57. +104 −0 lib/date-es-GT.js
  58. +104 −0 lib/date-es-HN.js
  59. +104 −0 lib/date-es-MX.js
  60. +104 −0 lib/date-es-NI.js
  61. +104 −0 lib/date-es-PA.js
  62. +104 −0 lib/date-es-PE.js
  63. +104 −0 lib/date-es-PR.js
  64. +104 −0 lib/date-es-PY.js
  65. +104 −0 lib/date-es-SV.js
  66. +104 −0 lib/date-es-UY.js
  67. +104 −0 lib/date-es-VE.js
  68. +104 −0 lib/date-et-EE.js
  69. +104 −0 lib/date-eu-ES.js
  70. +104 −0 lib/date-fa-IR.js
  71. +104 −0 lib/date-fi-FI.js
  72. +104 −0 lib/date-fo-FO.js
  73. +104 −0 lib/date-fr-BE.js
  74. +104 −0 lib/date-fr-CA.js
  75. +104 −0 lib/date-fr-CH.js
  76. +104 −0 lib/date-fr-FR.js
  77. +104 −0 lib/date-fr-LU.js
  78. +104 −0 lib/date-fr-MC.js
  79. +104 −0 lib/date-gl-ES.js
  80. +104 −0 lib/date-gu-IN.js
  81. +104 −0 lib/date-he-IL.js
  82. +104 −0 lib/date-hi-IN.js
  83. +104 −0 lib/date-hr-BA.js
  84. +104 −0 lib/date-hr-HR.js
  85. +104 −0 lib/date-hu-HU.js
  86. +104 −0 lib/date-hy-AM.js
  87. +104 −0 lib/date-id-ID.js
  88. +104 −0 lib/date-is-IS.js
  89. +104 −0 lib/date-it-CH.js
  90. +104 −0 lib/date-it-IT.js
  91. +104 −0 lib/date-ja-JP.js
  92. +104 −0 lib/date-ka-GE.js
  93. +104 −0 lib/date-kk-KZ.js
  94. +104 −0 lib/date-kn-IN.js
  95. +104 −0 lib/date-ko-KR.js
  96. +104 −0 lib/date-kok-IN.js
  97. +104 −0 lib/date-ky-KG.js
  98. +104 −0 lib/date-lt-LT.js
  99. +104 −0 lib/date-lv-LV.js
  100. +104 −0 lib/date-mi-NZ.js
  101. +104 −0 lib/date-mk-MK.js
  102. +104 −0 lib/date-mn-MN.js
  103. +104 −0 lib/date-mr-IN.js
  104. +104 −0 lib/date-ms-BN.js
  105. +104 −0 lib/date-ms-MY.js
  106. +104 −0 lib/date-mt-MT.js
  107. +104 −0 lib/date-nb-NO.js
  108. +104 −0 lib/date-nl-BE.js
  109. +104 −0 lib/date-nl-NL.js
  110. +104 −0 lib/date-nn-NO.js
  111. +104 −0 lib/date-ns-ZA.js
  112. +104 −0 lib/date-pa-IN.js
  113. +104 −0 lib/date-pl-PL.js
  114. +104 −0 lib/date-pt-BR.js
  115. +104 −0 lib/date-pt-PT.js
  116. +104 −0 lib/date-quz-BO.js
  117. +104 −0 lib/date-quz-EC.js
  118. +104 −0 lib/date-quz-PE.js
  119. +104 −0 lib/date-ro-RO.js
  120. +104 −0 lib/date-ru-RU.js
  121. +104 −0 lib/date-sa-IN.js
  122. +104 −0 lib/date-se-FI.js
  123. +104 −0 lib/date-se-NO.js
  124. +104 −0 lib/date-se-SE.js
  125. +104 −0 lib/date-sk-SK.js
  126. +104 −0 lib/date-sl-SI.js
  127. +104 −0 lib/date-sma-NO.js
  128. +104 −0 lib/date-sma-SE.js
  129. +104 −0 lib/date-smj-NO.js
  130. +104 −0 lib/date-smj-SE.js
  131. +104 −0 lib/date-smn-FI.js
  132. +104 −0 lib/date-sms-FI.js
  133. +104 −0 lib/date-sq-AL.js
  134. +104 −0 lib/date-sr-Cyrl-BA.js
  135. +104 −0 lib/date-sr-Cyrl-CS.js
  136. +104 −0 lib/date-sr-Latn-BA.js
  137. +104 −0 lib/date-sr-Latn-CS.js
  138. +104 −0 lib/date-sv-FI.js
  139. +104 −0 lib/date-sv-SE.js
  140. +104 −0 lib/date-sw-KE.js
  141. +104 −0 lib/date-syr-SY.js
  142. +104 −0 lib/date-ta-IN.js
  143. +104 −0 lib/date-te-IN.js
  144. +104 −0 lib/date-th-TH.js
  145. +104 −0 lib/date-tn-ZA.js
  146. +104 −0 lib/date-tr-TR.js
  147. +104 −0 lib/date-tt-RU.js
  148. +104 −0 lib/date-uk-UA.js
  149. +104 −0 lib/date-ur-PK.js
  150. +104 −0 lib/date-uz-Cyrl-UZ.js
  151. +104 −0 lib/date-uz-Latn-UZ.js
  152. +104 −0 lib/date-vi-VN.js
  153. +104 −0 lib/date-xh-ZA.js
  154. +104 −0 lib/date-zh-CN.js
  155. +104 −0 lib/date-zh-HK.js
  156. +104 −0 lib/date-zh-MO.js
  157. +104 −0 lib/date-zh-SG.js
  158. +104 −0 lib/date-zh-TW.js
  159. +104 −0 lib/date-zu-ZA.js
  160. +104 −0 lib/date.js
  161. +20 −0 package.json
  162. +20 −0 test/sanity.js
@@ -0,0 +1,17 @@
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to
+deal in the Software without restriction, including without limitation the
+rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+sell copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
+IN THE SOFTWARE.
@@ -0,0 +1,18 @@
+DateJS
+------
+
+This is a simple NPM wrapper around the excellent datejs client-side library.
+
+It modifies the Data prototype - this technique is looked down upon, but it's
+a very useful library.
+
+See http://www.datejs.com/ for more information.
+
+NPM package datejs v0.0.1 corresponds to datejs Alpha1. It hasn't changed for
+three years, so hopefully it won't be too much of a maintenance nightmare.
+
+I've just included all of the non-US locales in lib - I've not written any way
+to access them yet.
+
+What I'll probably do is create a wrapper which defaults to en-US, but can be
+called with other locales.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
@@ -0,0 +1,20 @@
+{ "name" : "datejs"
+, "description" : "datejs, wrapped up as an npm package"
+, "version" : "0.0.1"
+, "maintainers" :
+ [ { "name": "Chris Dew"
+ , "email": "cmsdew@gmail.com"
+ }
+ ]
+, "bugs" : { "web" : "http://github.com/chrisdew/datejs/issues" }
+, "licenses" : [ { "type" : "MIT" } ]
+, "repositories" :
+ [ { "type" : "git"
+ , "url" : "http://github.com/chrisdew/datejs"
+ }
+ ]
+, "main" : "./lib/date.js"
+, "engines" : { "node" : ">=0.2.6" }
+, "dependencies" : { "vows" : ">=0.5.2"
+ }
+}
@@ -0,0 +1,20 @@
+var vows = require('vows')
+ , assert = require('assert')
+ , datejs = require('datejs')
+ ;
+
+vows.describe('A sanity test').addBatch({
+ 'parse': { topic: "2011-02-02 10:25:00"
+ , 'parses"': function(topic) {
+ var date = Date.parse(topic);
+ assert.equal(date.getFullYear(), 2011);
+ assert.equal(date.getMonth(), 1);
+ assert.equal(date.getDate(), 2);
+ assert.equal(date.getHours(), 10);
+ assert.equal(date.getMinutes(), 25);
+ assert.equal(date.getSeconds(), 0);
+
+ assert.equal(date.is().wednesday(), true);
+ }
+ }
+}).export(module);

0 comments on commit beea5a2

Please sign in to comment.