DRY on the version number: it should be in package.json and nowhere else (#4400)

This commit is contained in:
Geoffrey Booth
2016-12-15 20:52:31 -08:00
committed by GitHub
parent 07d6eb6af5
commit be0f1cb8db
3 changed files with 13 additions and 4 deletions

View File

@@ -10,9 +10,12 @@ path = require 'path'
{parser} = require './parser'
helpers = require './helpers'
SourceMap = require './sourcemap'
# Require `package.json`, which is two levels above this file, as this file is
# evaluated from `lib/coffee-script`.
packageJson = require '../../package.json'
# The current CoffeeScript version number.
exports.VERSION = '1.12.1'
exports.VERSION = packageJson.version
exports.FILE_EXTENSIONS = ['.coffee', '.litcoffee', '.coffee.md']