mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-12 17:08:14 +00:00
chore: 自动更新 preset-vision 版本号
This commit is contained in:
parent
ea9d12ca85
commit
e0b06bc827
@ -11,7 +11,8 @@
|
||||
],
|
||||
"scripts": {
|
||||
"start": "build-scripts start",
|
||||
"build": "build-scripts build --skip-demo",
|
||||
"version:update": "node ./scripts/version.js",
|
||||
"build": "tnpm run version:update && build-scripts build --skip-demo",
|
||||
"cloud-build": "build-scripts build --skip-demo",
|
||||
"test": "build-scripts test --config build.test.json"
|
||||
},
|
||||
@ -50,6 +51,7 @@
|
||||
"build-plugin-fusion": "^0.1.0",
|
||||
"build-plugin-moment-locales": "^0.1.0",
|
||||
"build-plugin-react-app": "^1.1.2",
|
||||
"fs-extra": "^9.0.1",
|
||||
"prop-types": "^15.7.2",
|
||||
"tsconfig-paths-webpack-plugin": "^3.2.0"
|
||||
},
|
||||
|
||||
21
packages/editor-preset-vision/scripts/version.js
Normal file
21
packages/editor-preset-vision/scripts/version.js
Normal file
@ -0,0 +1,21 @@
|
||||
/* eslint-disable @typescript-eslint/no-var-requires */
|
||||
/* eslint-disable @typescript-eslint/no-require-imports */
|
||||
const { execSync } = require('child_process');
|
||||
const { join } = require('path');
|
||||
const fse = require('fs-extra');
|
||||
|
||||
const gitBranchName = execSync('git rev-parse --abbrev-ref HEAD', { encoding: 'utf-8' });
|
||||
const reBranchVersion = /^(?:[a-z]+\/)(\d+\.\d+\.\d+)$/im;
|
||||
|
||||
const match = reBranchVersion.exec(gitBranchName);
|
||||
if (!match) {
|
||||
throw new Error(`[checkversion] gitBranchName: ${gitBranchName}`);
|
||||
}
|
||||
|
||||
const releaseVersion = match[1];
|
||||
|
||||
const indexFile = join(__dirname, '../src/index.ts');
|
||||
|
||||
const indexContent = fse.readFileSync(indexFile, 'utf-8');
|
||||
|
||||
fse.writeFileSync(indexFile, indexContent.replace('{VERSION}', releaseVersion));
|
||||
@ -11,7 +11,6 @@ import {
|
||||
removeBuiltinComponentAction,
|
||||
// modifyBuiltinComponentAction,
|
||||
} from '@ali/lowcode-designer';
|
||||
import { ILowCodePluginContext, ILowCodePluginConfig } from '@ali/lowcode-types';
|
||||
import { createElement } from 'react';
|
||||
import { VE_EVENTS as EVENTS, VE_HOOKS as HOOKS, VERSION as Version } from './base/const';
|
||||
import Bus from './bus';
|
||||
@ -183,10 +182,9 @@ export {
|
||||
plugins,
|
||||
};
|
||||
|
||||
const version = '1.0.28';
|
||||
|
||||
console.log(
|
||||
`%c AliLowCodeEngine %c v${version} `,
|
||||
'%c AliLowCodeEngine %c v1.0.28 ',
|
||||
'padding: 2px 1px; border-radius: 3px 0 0 3px; color: #fff; background: #606060; font-weight: bold;',
|
||||
'padding: 2px 1px; border-radius: 0 3px 3px 0; color: #fff; background: #42c02e; font-weight: bold;',
|
||||
);
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { findIndex } from 'lodash';
|
||||
import { DocumentModel, Node, Root } from '@ali/lowcode-designer';
|
||||
import { DocumentModel, Node, RootNode } from '@ali/lowcode-designer';
|
||||
|
||||
/**
|
||||
* RootNodeVisitor for VisualEngine Page
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user