Skip to content

Commit

Permalink
Replace Global Rush (#8820)
Browse files Browse the repository at this point in the history
  • Loading branch information
wanlwanl authored Aug 13, 2024
1 parent b444030 commit 34de2dc
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 12 deletions.
8 changes: 4 additions & 4 deletions tools/js-sdk-release-tools/src/hlc/generateMgmt.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,10 @@ export async function generateMgmt(options: {
}
}

logger.logGreen(`rush update`);
execSync('rush update', {stdio: 'inherit'});
logger.logGreen(`rush build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
execSync(`rush build -t ${packageName}`, {stdio: 'inherit'});
logger.logGreen(`node common/scripts/install-run-rush.js update`);
execSync('node common/scripts/install-run-rush.js update', {stdio: 'inherit'});
logger.logGreen(`node common/scripts/install-run-rush.js build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
execSync(`node common/scripts/install-run-rush.js build -t ${packageName}`, {stdio: 'inherit'});
logger.logGreen('Generating Changelog and Bumping Version...');
let changelog: Changelog | undefined;
if (!options.skipGeneration) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -224,11 +224,11 @@ export async function generateRLCInPipeline(options: {
}
}

logger.logGreen(`rush update...`);
execSync('rush update', {stdio: 'inherit'});
logger.logGreen(`rush build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
logger.logGreen(`node common/scripts/install-run-rush.js update...`);
execSync('node common/scripts/install-run-rush.js update', {stdio: 'inherit'});
logger.logGreen(`node common/scripts/install-run-rush.js build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
// To build generated codes except test and sample, we need to change tsconfig.json.
execSync(`rush build -t ${packageName}`, {stdio: 'inherit'});
execSync(`node common/scripts/install-run-rush.js build -t ${packageName}`, {stdio: 'inherit'});
logger.logGreen(`node common/scripts/install-run-rush.js pack --to ${packageName} --verbose`);
execSync(`node common/scripts/install-run-rush.js pack --to ${packageName} --verbose`, {stdio: 'inherit'});
if (!options.skipGeneration) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ export async function generateCodes(sdkRepo: string, packagePath: string, packag

export async function buildGeneratedCodes(sdkrepo: string, packagePath: string, packageName: string) {
shell.cd(sdkrepo);
logger.logGreen(`rush update`);
execSync('rush update', {stdio: 'inherit'});
logger.logGreen(`rush build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
logger.logGreen(`node common/scripts/install-run-rush.js update`);
execSync('node common/scripts/install-run-rush.js update', {stdio: 'inherit'});
logger.logGreen(`node common/scripts/install-run-rush.js build -t ${packageName}: Build generated codes, except test and sample, which may be written manually`);
// To build generated codes except test and sample, we need to change tsconfig.json.
changeConfigOfTestAndSample(packagePath, ChangeModel.Change, SdkType.Rlc);
execSync(`rush build -t ${packageName}`, {stdio: 'inherit'});
execSync(`node common/scripts/install-run-rush.js build -t ${packageName}`, {stdio: 'inherit'});
changeConfigOfTestAndSample(packagePath, ChangeModel.Revert, SdkType.Rlc);
shell.cd(packagePath);
logger.logGreen(`Generate changelog`);
Expand Down

0 comments on commit 34de2dc

Please sign in to comment.