Merge pull request #13075 from backstage/rugvip/depr
scaffolder-backend: deprecate publish:file action
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-scaffolder-backend': patch
|
||||
---
|
||||
|
||||
The `publish:file` action has been deprecated in favor of testing templates using the template editor instead. Note that this action is not and was never been installed by default.
|
||||
@@ -303,7 +303,7 @@ export function createPublishBitbucketServerAction(options: {
|
||||
token?: string | undefined;
|
||||
}>;
|
||||
|
||||
// @public
|
||||
// @public @deprecated
|
||||
export function createPublishFileAction(): TemplateAction<{
|
||||
path: string;
|
||||
}>;
|
||||
|
||||
@@ -29,6 +29,7 @@ import { createTemplateAction } from '../../createTemplateAction';
|
||||
* production, as it writes the files to the local filesystem of the scaffolder.
|
||||
*
|
||||
* @public
|
||||
* @deprecated This action will be removed, prefer testing templates using the template editor instead.
|
||||
*/
|
||||
export function createPublishFileAction() {
|
||||
return createTemplateAction<{ path: string }>({
|
||||
@@ -47,6 +48,10 @@ export function createPublishFileAction() {
|
||||
},
|
||||
},
|
||||
async handler(ctx) {
|
||||
ctx.logger.warn(
|
||||
'[DEPRECATED] This action will be removed, prefer testing templates using the template editor instead.',
|
||||
);
|
||||
|
||||
const { path } = ctx.input;
|
||||
|
||||
const exists = await fs.pathExists(path);
|
||||
|
||||
Reference in New Issue
Block a user