Team Ai
Datasetpublic

codekingpro/portable-devtools

sourceHugging Faceupdated 5mo agoView on Hugging Face
1likes15kdownloads
inc.js22 linesDownload Raw Back to functions
1'use strict'
2
3const SemVer = require('../classes/semver')
4
5const inc = (version, release, options, identifier, identifierBase) => {
6  if (typeof (options) === 'string') {
7    identifierBase = identifier
8    identifier = options
9    options = undefined
10  }
11
12  try {
13    return new SemVer(
14      version instanceof SemVer ? version.version : version,
15      options
16    ).inc(release, identifier, identifierBase).version
17  } catch (er) {
18    return null
19  }
20}
21module.exports = inc
22 
codekingpro/portable-devtools · Team Ai