Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2,739 changes: 2,368 additions & 371 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/contentstack-launch/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ $ npm install -g @contentstack/cli-launch
$ csdx COMMAND
running command...
$ csdx (--version|-v)
@contentstack/cli-launch/1.2.1 darwin-arm64 node-v22.2.0
@contentstack/cli-launch/1.2.2 darwin-arm64 node-v22.2.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack-launch/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@contentstack/cli-launch",
"version": "1.2.1",
"version": "1.2.2",
"description": "Launch related operations",
"author": "Contentstack CLI",
"bin": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,14 @@ export class CloudFunctions {
).default;
app.use(express.json());
app.use(express.urlencoded({ extended: true }));

app.use((request: Request, response: Response, next) => {
if (!response.getHeader('cache-control')) {
response.setHeader('cache-control', 'no-store');
}
next();
});

app.all(
cloudFunctionResource.apiResourceURI,
async (request: Request, response: Response) => {
Expand All @@ -94,6 +102,11 @@ export class CloudFunctions {
);
}

private isProxyEdgeFile(filename: string): boolean {
const PROXY_EDGE_FILENAME = '[proxy].edge.js';
return filename === PROXY_EDGE_FILENAME;
}

private async parseCloudFunctionResources(): Promise<
CloudFunctionResource[]
> {
Expand All @@ -103,10 +116,9 @@ export class CloudFunctions {
for await (const filePath of filePaths) {
const parsedPath = path.parse(filePath);

if (
parsedPath.ext !== CLOUD_FUNCTIONS_SUPPORTED_EXTENSION ||
!(await this.checkDefaultExport(filePath))
) {
if (this.isProxyEdgeFile(parsedPath.base)
|| parsedPath.ext !== CLOUD_FUNCTIONS_SUPPORTED_EXTENSION
|| !await this.checkDefaultExport(filePath)) {
continue;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { stub, createSandbox } from 'sinon';
import { cliux } from '@contentstack/cli-utilities';
import fs from 'fs';
import { FileUpload, BaseClass } from '../../../src/adapters';
import { BaseCommand } from '../../../src/commands/launch/base-command';
import { BaseCommand } from '../../../src/base-command';

describe('File Upload', () => {
let inquireStub, prepareApiClientsStub, prepareConfigStub, getConfigStub;
Expand Down Expand Up @@ -152,6 +152,7 @@ describe('File Upload', () => {
{ name: 'NextJs', value: 'NEXTJS' },
{ name: 'Other', value: 'OTHER' },
],
outputDirectories:""
},
};
let archiveMockData = { zipName: 'abc.zip', zipPath: 'path/to/zip', projectName: 'test' };
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { stub, createSandbox } from 'sinon';
import { cliux } from '@contentstack/cli-utilities';
import { githubAdapterMockData } from '../mock/index';
import { GitHub, BaseClass } from '../../../src/adapters';
import { BaseCommand } from '../../../src/commands/launch/base-command';
import { BaseCommand } from '../../../src/base-command';

describe('GitHub', () => {
let inquireStub, prepareApiClientsStub, prepareConfigStub, getConfigStub;
Expand Down
2 changes: 1 addition & 1 deletion packages/contentstack/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ $ npm install -g @contentstack/cli
$ csdx COMMAND
running command...
$ csdx (--version|-v)
@contentstack/cli/1.25.0 darwin-arm64 node-v22.2.0
@contentstack/cli/1.25.1 darwin-arm64 node-v22.8.0
$ csdx --help [COMMAND]
USAGE
$ csdx COMMAND
Expand Down
4 changes: 2 additions & 2 deletions packages/contentstack/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@contentstack/cli",
"description": "Command-line tool (CLI) to interact with Contentstack",
"version": "1.25.0",
"version": "1.25.1",
"author": "Contentstack",
"bin": {
"csdx": "./bin/run.js"
Expand Down Expand Up @@ -35,7 +35,7 @@
"@contentstack/cli-cm-seed": "~1.8.0",
"@contentstack/cli-command": "~1.3.1",
"@contentstack/cli-config": "~1.7.1",
"@contentstack/cli-launch": "~1.2.1",
"@contentstack/cli-launch": "~1.2.2",
"@contentstack/cli-migration": "~1.6.1",
"@contentstack/cli-utilities": "~1.7.3",
"@contentstack/management": "~1.17.0",
Expand Down
Loading