Skip to content

Commit

Permalink
version bump 1.1.1: infrastructure
Browse files Browse the repository at this point in the history
  • Loading branch information
SheetJSDev committed Jan 19, 2018
1 parent 4cb7279 commit 9ef2c47
Show file tree
Hide file tree
Showing 19 changed files with 333 additions and 100 deletions.
13 changes: 6 additions & 7 deletions .eslintrc
Expand Up @@ -5,15 +5,14 @@
"ecmaVersion": 3,
},
"plugins": [ "html", "json" ],
"extends": "eslint:recommended",
"rules": {
"no-use-before-define": [ 1, {
"functions":false, "classes":true, "variables":true
}],
"no-bitwise": 0,
"curly": 0,
"comma-style": [ 2, "last" ],
"comma-dangle": [ 2, "never" ],
"curly": 0,
"no-bitwise": 0,
"no-console": 0,
"no-trailing-spaces": 2,
"semi": [ 2, "always" ],
"comma-dangle": [ 2, "never" ]
"semi": [ 2, "always" ]
}
}
1 change: 1 addition & 0 deletions .npmignore
Expand Up @@ -19,3 +19,4 @@ MANIFEST
*.tgz
*.py
*.html
.spelling
8 changes: 8 additions & 0 deletions .spelling
@@ -0,0 +1,8 @@
# frac.js (C) 2012-present SheetJS -- http://sheetjs.com
SheetJS
frac

Aberth
CommonJS
npm
prepend
15 changes: 15 additions & 0 deletions Makefile
Expand Up @@ -42,6 +42,9 @@ ctest: ## Build browser test (into ctest/ subdirectory)
ctestserv: ## Start a test server on port 8000
@cd ctest && python -mSimpleHTTPServer

.PHONY: fullint
fullint: lint old-lint tslint flow mdlint ## Run all checks

.PHONY: lint
lint: $(TARGET) $(AUXTARGETS) ## Run eslint checks
@eslint --ext .js,.njs,.json,.html,.htm $(TARGET) $(AUXTARGETS) $(CMDS) $(HTMLLINT) package.json bower.json
Expand All @@ -56,6 +59,12 @@ old-lint: $(TARGET) $(AUXTARGETS) ## Run jshint and jscs checks
@jscs $(TARGET) $(AUXTARGETS)
if [ -e $(CLOSURE) ]; then java -jar $(CLOSURE) $(REQS) $(FLOWTARGET) --jscomp_warning=reportUnknownTypes >/dev/null; fi

.PHONY: tslint
tslint: $(TARGET) ## Run typescript checks
#@npm install dtslint typescript
#@npm run-script dtslint
dtslint types

.PHONY: flow
flow: lint ## Run flow checker
@flow check --all --show-all-errors
Expand All @@ -70,6 +79,12 @@ misc/coverage.html: $(TARGET) test.js
coveralls: ## Coverage Test + Send to coveralls.io
mocha --require blanket --reporter mocha-lcov-reporter -t 20000 | node ./node_modules/coveralls/bin/coveralls.js

MDLINT=README.md frac.md
.PHONY: mdlint
mdlint: $(MDLINT) ## Check markdown documents
alex $^
mdspell -a -n -x -r --en-us $^

.PHONY: dist
dist: dist-deps $(TARGET) ## Prepare JS files for distribution
cp $(TARGET) dist/
Expand Down
9 changes: 4 additions & 5 deletions README.md
Expand Up @@ -13,7 +13,7 @@ replicate fraction formats.

### JS

With [npm](https://www.npmjs.org/package/frac):
With [`npm`](https://www.npmjs.org/package/frac):

```bash
$ npm install frac
Expand All @@ -25,13 +25,12 @@ In the browser:
<script src="frac.js"></script>
```

The script will manipulate `module.exports` if available (e.g. in a CommonJS
`require` context). This is not always desirable. To prevent the behavior,
define `DO_NOT_EXPORT_FRAC`
The script will manipulate `module.exports` if available . This is not always
desirable. To prevent the behavior, define `DO_NOT_EXPORT_FRAC`

### Python

From [PyPI](https://pypi.python.org/pypi/frac):
From [`PyPI`](https://pypi.python.org/pypi/frac):

```bash
$ pip install frac
Expand Down
1 change: 1 addition & 0 deletions ctest/frac.js
Expand Up @@ -38,4 +38,5 @@ frac.cont = function cont(x, D, mixed) {
var q = Math.floor(sgn * P/Q);
return [q, sgn*P - q*Q, Q];
};
// eslint-disable-next-line no-undef
if(typeof module !== 'undefined' && typeof DO_NOT_EXPORT_FRAC === 'undefined') module.exports = frac;

0 comments on commit 9ef2c47

Please sign in to comment.