...
 
Commits (2)
cache:
key: "$CI_JOB_NAME"
untracked: true
paths:
- node_modules/
before_script:
- npm install
.test_template: &npm_test
script:
- npm run lint
- npm test
test:node4:
image: node:4
<<: *npm_test
test:node6:
image: node:6
<<: *npm_test
test:node8:
image: node:8
<<: *npm_test
test:node10:
image: node:10
<<: *npm_test
Phil Booth <[email protected]> (https://github.com/philbooth)
Phil Booth <[email protected]> (https://philbooth.me/)
Andrew Lawson (https://github.com/adlawson)
Tim O'Sulg (https://github.com/timgluz)
# Changes
## 1.0.1
### Other changes
* project: migrate to gitlab (0046018)
## 1.0.0
* Update:a83cc21 Update dependencies. (a83cc21)
......
# tryer
[![Package status](https://img.shields.io/npm/v/tryer.svg?style=flat-square)](https://www.npmjs.com/package/tryer)
[![Build status](https://img.shields.io/travis/philbooth/tryer.svg?style=flat-square)](https://travis-ci.org/philbooth/tryer)
[![License](https://img.shields.io/github/license/philbooth/tryer.svg?style=flat-square)](https://opensource.org/licenses/MIT)
[![Build status](https://gitlab.com/philbooth/tryer/badges/master/pipeline.svg)](https://gitlab.com/philbooth/tryer/pipelines)
[![Package status](https://img.shields.io/npm/v/tryer.svg)](https://www.npmjs.com/package/tryer)
[![Downloads](https://img.shields.io/npm/dm/tryer.svg)](https://www.npmjs.com/package/tryer)
[![License](https://img.shields.io/npm/l/tryer.svg)](https://opensource.org/licenses/MIT)
Because everyone loves a tryer!
Conditional
......@@ -78,7 +80,7 @@ npm i tryer --save
Or if you just want the git repo:
```
git clone [email protected]hub.com:philbooth/tryer.git
git clone [email protected]lab.com:philbooth/tryer.git
```
## How do I use it?
......@@ -294,8 +296,8 @@ npm run minify
[chai]: http://chaijs.com/
[jshint]: http://jshint.com/
[mocha]: http://mochajs.org/
[please-release-me]: https://github.com/philbooth/please-release-me
[spooks.js]: https://github.com/philbooth/spooks.js
[please-release-me]: https://gitlab.com/philbooth/please-release-me
[spooks.js]: https://gitlab.com/philbooth/spooks.js
[uglifyjs]: http://lisperator.net/uglifyjs/
[license]: COPYING
{
"name": "tryer",
"version": "1.0.0",
"version": "1.0.1",
"main": "lib/tryer.min.js",
"ignore": [
"AUTHORS",
......
{
"name": "tryer",
"version": "1.0.0",
"version": "1.0.1",
"description": "Because everyone loves a tryer! Conditional and repeated task invocation for node and browser.",
"repo": "philbooth/tryer",
"license": "MIT",
......
!function(n){"use strict";function t(n){function t(){u()&&o()}function u(){return r("when",t)}function r(t,i){return!!n[t]()||(m(n),d(n)?n.fail():p(i,h(n)),!1)}function o(){var t;if(s(n))return(t=n.action())&&e(t.then)?t.then(f,f):f();n.action(f)}function f(){r("until",o)&&n.pass()}n=i(n),t()}function i(n){return n=n||{},{count:0,when:u(n.when),until:u(n.until),action:o(n.action),fail:o(n.fail),pass:o(n.pass),interval:a(n.interval,-1e3),limit:a(n.limit,-1)}}function u(n){return c(n,e,r)}function e(n){return"function"==typeof n}function r(){return!0}function o(n){return c(n,e,f)}function f(){}function c(n,t,i){return t(n)?n:i}function a(n,t){return c(n,l,t)}function l(n){return"number"==typeof n&&n===n}function s(n){return 0===n.action.length}function m(n){n.count+=1}function d(n){return n.limit>=0&&n.count>=n.limit}function h(n){var t=n.interval;return n.interval<0&&(n.interval*=2),t}function p(n,t){setTimeout(n,Math.abs(t))}"function"==typeof define&&define.amd?define(function(){return t}):"undefined"!=typeof module&&null!==module?module.exports=t:n.tryer=t}(this);
\ No newline at end of file
!function(n){"use strict";function t(r){var n;function t(){i("when",t)&&e()}function i(n,t){return!!r[n]()||(r.count+=1,0<=(u=r).limit&&u.count>=u.limit?r.fail():(i=t,e=function(n){var t=n.interval;n.interval<0&&(n.interval*=2);return t}(r),setTimeout(i,Math.abs(e))),!1);var i,e,u}function e(){var n;if(0===r.action.length)return(n=r.action())&&f(n.then)?n.then(u,u):u();r.action(u)}function u(){i("until",e)&&r.pass()}r={count:0,when:o((n=(n=r)||{}).when),until:o(n.until),action:c(n.action),fail:c(n.fail),pass:c(n.pass),interval:a(n.interval,-1e3),limit:a(n.limit,-1)},t()}function o(n){return u(n,f,i)}function f(n){return"function"==typeof n}function i(){return!0}function c(n){return u(n,f,e)}function e(){}function u(n,t,i){return t(n)?n:i}function a(n,t){return u(n,r,t)}function r(n){return"number"==typeof n&&n==n}"function"==typeof define&&define.amd?define(function(){return t}):"undefined"!=typeof module&&null!==module?module.exports=t:n.tryer=t}(this);
\ No newline at end of file
{
"name": "tryer",
"version": "1.0.0",
"version": "1.0.1",
"description": "Because everyone loves a tryer! Conditional and repeated task invocation for node and browser.",
"homepage": "https://github.com/philbooth/tryer",
"bugs": "https://github.com/philbooth/tryer/issues",
"homepage": "https://gitlab.com/philbooth/tryer",
"bugs": "https://gitlab.com/philbooth/tryer/issues",
"license": "MIT",
"author": "Phil Booth <[email protected]> (https://philbooth.me/)",
"main": "./src/tryer",
"repository": {
"type": "git",
"url": "https://github.com/philbooth/tryer.git"
"url": "git+https://gitlab.com/philbooth/tryer.git"
},
"keywords": [
"repeat",
......@@ -27,10 +27,10 @@
"devDependencies": {
"chai": "4.1.x",
"jshint": "2.9.x",
"mocha": "3.5.x",
"please-release-me": "1.0.x",
"mocha": "5.2.x",
"please-release-me": "2.0.x",
"spooks": "2.0.x",
"uglify-js": "3.0.x"
"uglify-js": "3.4.x"
},
"scripts": {
"lint": "jshint src/tryer.js test/unit.js",
......@@ -38,4 +38,3 @@
"minify": "uglifyjs ./src/tryer.js --compress --mangle --output ./lib/tryer.min.js"
}
}