소스 검색

Improved the release scripts.

Kamil Piechaczek 7 년 전
부모
커밋
0c3dc27ed9
3개의 변경된 파일12개의 추가작업 그리고 3개의 파일을 삭제
  1. 1 1
      scripts/release-ckeditor5.sh
  2. 5 1
      scripts/release/changelog.js
  3. 6 1
      scripts/release/release-dependencies.js

+ 1 - 1
scripts/release-ckeditor5.sh

@@ -20,7 +20,7 @@ then
 	mgit exec 'git checkout -b stable 2> /dev/null && git push origin stable && git checkout master'
 	mgit exec 'git checkout -b stable 2> /dev/null && git push origin stable && git checkout master'
 
 
 	# Update all `stable` branches in all packages.
 	# Update all `stable` branches in all packages.
-	mgit exec 'git checkout stable && git merge master && git checkout master'
+	mgit exec 'git checkout stable && git pull origin stable && git merge master && git checkout master'
 
 
 	# Make sure that `mgit.json` for `stable` and `master` branches is correct.
 	# Make sure that `mgit.json` for `stable` and `master` branches is correct.
 	# `stable` branch.
 	# `stable` branch.

+ 5 - 1
scripts/release/changelog.js

@@ -9,10 +9,14 @@
 
 
 'use strict';
 'use strict';
 
 
+// In order to use the same version for all packages (including builds and ckeditor5 itself), you can call:
+// npm run changelog [newVersion]
+
 const devEnv = require( '@ckeditor/ckeditor5-dev-env' );
 const devEnv = require( '@ckeditor/ckeditor5-dev-env' );
 const commonOptions = {
 const commonOptions = {
 	cwd: process.cwd(),
 	cwd: process.cwd(),
-	packages: 'packages'
+	packages: 'packages',
+	newVersion: process.argv[ 2 ] || null
 };
 };
 const editorBuildsGlob = '@ckeditor/ckeditor5-build-*';
 const editorBuildsGlob = '@ckeditor/ckeditor5-build-*';
 
 

+ 6 - 1
scripts/release/release-dependencies.js

@@ -9,8 +9,13 @@
 
 
 'use strict';
 'use strict';
 
 
+// In order to test the whole process, you can use:
+// npm run release:dependencies -- --dry-run
+// It will create some commits but nothing will be pushed or published.
+
 require( '@ckeditor/ckeditor5-dev-env' )
 require( '@ckeditor/ckeditor5-dev-env' )
 	.releaseSubRepositories( {
 	.releaseSubRepositories( {
 		cwd: process.cwd(),
 		cwd: process.cwd(),
-		packages: 'packages'
+		packages: 'packages',
+		dryRun: process.argv.includes( '--dry-run' )
 	} );
 	} );