Sun calculation js library which is fully based on formula from http://aa.quae.nl/en/reken/zonpositie.html
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
10 lines
294 B
10 lines
294 B
'use strict';
|
|
module.exports = function (flag, argv) {
|
|
argv = argv || process.argv;
|
|
|
|
var terminatorPos = argv.indexOf('--');
|
|
var prefix = /^-{1,2}/.test(flag) ? '' : '--';
|
|
var pos = argv.indexOf(prefix + flag);
|
|
|
|
return pos !== -1 && (terminatorPos === -1 ? true : pos < terminatorPos);
|
|
};
|
|
|