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

@antora/site-publisher

Package Overview
Dependencies
Maintainers
2
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@antora/site-publisher - npm Package Compare versions

Comparing version 1.0.0-rc.2 to 1.0.0

6

lib/providers/archive.js

@@ -11,6 +11,8 @@ 'use strict'

function publishToArchive (config, files, playbook) {
const destFile = expandPath(config.path || DEFAULT_DEST_ARCHIVE, '~+', playbook.dir || '.')
return publishStream(vzipDest(destFile), files)
const destFile = config.path || DEFAULT_DEST_ARCHIVE
const absDestFile = expandPath(destFile, '~+', playbook.dir || '.')
const report = { provider: 'archive', path: destFile, resolvedPath: absDestFile }
return publishStream(vzipDest(absDestFile), files).then(() => report)
}
module.exports = publishToArchive

@@ -5,2 +5,4 @@ 'use strict'

const fs = require('fs-extra')
const ospath = require('path')
const posixify = ospath.sep === '\\' ? (p) => p.replace(/\\/g, '/') : undefined
const publishStream = require('./common/publish-stream')

@@ -12,8 +14,18 @@ const { dest: vfsDest } = require('vinyl-fs')

function publishToFs (config, files, playbook) {
const destDir = expandPath(config.path || DEFAULT_DEST_FS, '~+', playbook.dir || '.')
const destDir = config.path || DEFAULT_DEST_FS
const absDestDir = expandPath(destDir, '~+', playbook.dir || '.')
const report = {
provider: 'fs',
path: destDir,
resolvedPath: absDestDir,
fileUri: 'file://' + (posixify ? '/' + posixify(absDestDir) : absDestDir),
}
return config.clean
? fs.remove(destDir).then(() => publishStream(vfsDest(destDir), files))
: publishStream(vfsDest(destDir), files)
? fs
.remove(absDestDir)
.then(() => publishStream(vfsDest(absDestDir), files))
.then(() => report)
: publishStream(vfsDest(absDestDir), files).then(() => report)
}
module.exports = publishToFs

@@ -44,3 +44,3 @@ 'use strict'

if (!destinations.length) return
if (!destinations.length) return []

@@ -71,5 +71,3 @@ const clean = output.clean

return Promise.all(publishers.map((publish) => publish(new ReadableOutputFileArray(files), playbook))).then(
() => undefined
)
return Promise.all(publishers.map((publish) => publish(new ReadableOutputFileArray(files), playbook)))
}

@@ -76,0 +74,0 @@

@@ -5,3 +5,3 @@ 'use strict'

const DOT_RELATIVE_RX = new RegExp(`^\\.{1,2}[${[...new Set(['/', ospath.sep])].join('').replace('\\', '\\\\')}]`)
const DOT_RELATIVE_RX = new RegExp(`^\\.{1,2}[/${ospath.sep.replace('/', '').replace('\\', '\\\\')}]`)

@@ -8,0 +8,0 @@ /**

{
"name": "@antora/site-publisher",
"version": "1.0.0-rc.2",
"version": "1.0.0",
"description": "Publishes the files generated in an Antora documentation pipeline to the destination(s) specified in the playbook.",

@@ -5,0 +5,0 @@ "license": "MPL-2.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