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

cloudcannon-hugo

Package Overview
Dependencies
Maintainers
7
Versions
54
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cloudcannon-hugo - npm Package Compare versions

Comparing version 1.0.6 to 1.0.7

2

package.json
{
"name": "cloudcannon-hugo",
"type": "module",
"version": "1.0.6",
"version": "1.0.7",
"description": "Generates the files necessary for a hugo site to integrate with CloudCannon CMS",

@@ -6,0 +6,0 @@ "main": "src/index.js",

@@ -11,7 +11,10 @@ import Papa from 'papaparse';

async function getHugoUrls() {
async function getHugoUrls(hugoConfig) {
log('⏳ Listing files from Hugo...');
const { source } = pathHelper.getPaths();
const cmdArgs = ['list', 'all', ...(source ? ['--source', source] : [])];
const { environment } = hugoConfig;
const cmdArgs = ['list', 'all', '--environment', environment || 'production'];
cmdArgs.push(...(source ? ['--source', source] : []));
const raw = await runProcess('hugo', cmdArgs);

@@ -34,3 +37,3 @@ const startIndex = raw.search(/^path,/m); // hugo logs warnings before this point

const config = await getConfig(hugoConfig);
const hugoUrls = await getHugoUrls();
const hugoUrls = await getHugoUrls(hugoConfig);

@@ -37,0 +40,0 @@ pathHelper.getSupportedLanguages(hugoConfig);

@@ -31,3 +31,3 @@ import { join, extname, basename } from 'path';

const sourceDir = flags.source || '';
const environment = flags.environment || 'production'; // or just use root
const environment = flags.environment || process.env.HUGO_ENVIRONMENT || 'production';

@@ -126,2 +126,6 @@ const configDir = flags.configDir || 'config';

if (flags.environment) {
configObject.environment = flags.environment;
}
if (flags.destination) {

@@ -128,0 +132,0 @@ configObject.destination = flags.destination;

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