Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@platformatic/metaconfig

Package Overview
Dependencies
Maintainers
6
Versions
128
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@platformatic/metaconfig - npm Package Compare versions

Comparing version 0.33.1 to 0.34.0

3

package.json
{
"name": "@platformatic/metaconfig",
"version": "0.33.1",
"version": "0.34.0",
"main": "metaconfig.js",

@@ -16,2 +16,3 @@ "description": "Manage mulitple configuration versions at the same time",

"devDependencies": {
"proxyquire": "^2.1.3",
"snazzy": "^9.0.0",

@@ -18,0 +19,0 @@ "standard": "^17.1.0",

@@ -7,2 +7,3 @@ 'use strict'

const pkg = require('../package.json')
const proxyquire = require('proxyquire')

@@ -115,1 +116,15 @@ test('specified version is bigger than the current version (minor)', async (t) => {

})
test('upgrade patch versions', async (t) => {
const FromZeroEighteenToWillSee = proxyquire('../versions/from-zero-eighteen-to-will-see', {
'../package.json': {
version: '0.33.1'
}
})
const version = '0.33.0'
const meta = new FromZeroEighteenToWillSee({ version, config: { } })
const upped = meta.up()
t.match(upped, {
version: '0.33.1'
})
})

@@ -13,3 +13,10 @@ 'use strict'

if (semver.satisfies(version, '~' + this.version) || semver.gt(this.version, version)) {
let increment = 'minor'
if (semver.satisfies(version, '~' + this.version)) {
if (!semver.eq(version, this.version)) {
increment = 'patch'
} else {
return
}
} else if (semver.gt(this.version, version)) {
return

@@ -21,3 +28,3 @@ }

const config = rfdc(original)
const version = semver.inc(this.version, 'minor')
const version = semver.inc(this.version, increment)
config.$schema = `https://platformatic.dev/schemas/v${version}/${this.kind}`

@@ -24,0 +31,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc