From 187e52d68bce34e791e2a9ad34e4db1b8a16b1e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Go=C5=82e=CC=A8biowski-Owczarek?= Date: Sat, 6 Feb 2021 00:42:20 +0100 Subject: [PATCH] Build: Make main the default branch instead of master --- README.md | 2 +- docs/usage.txt | 2 +- lib/bootstrap.js | 2 +- lib/repo.js | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 75afa27..f45ccd4 100644 --- a/README.md +++ b/README.md @@ -28,7 +28,7 @@ project=/path/to/fake-project cdn=/path/to/fake-cdn cd $project -git checkout master +git checkout main set +e git tag -d 0.0.1 set -e diff --git a/docs/usage.txt b/docs/usage.txt index 358017e..5359419 100644 --- a/docs/usage.txt +++ b/docs/usage.txt @@ -11,7 +11,7 @@ OPTIONS --branch=branch Specifies which branch to create the release from. - Defaults to master. + Defaults to main. --remote=repo Specifies the remote repository to work with. There are three diff --git a/lib/bootstrap.js b/lib/bootstrap.js index d7792f2..ccee740 100644 --- a/lib/bootstrap.js +++ b/lib/bootstrap.js @@ -41,7 +41,7 @@ Release.define( { } ); Release._parseRemote(); - Release.branch = Release.args.branch || "master"; + Release.branch = Release.args.branch || "main"; Release.preRelease = Release.args.preRelease || false; if ( Release.args.dryRun || Release.args.isTest ) { Release.isTest = true; diff --git a/lib/repo.js b/lib/repo.js index 6766348..b310db9 100644 --- a/lib/repo.js +++ b/lib/repo.js @@ -212,10 +212,10 @@ Release.define( { // Update package.json URLs console.log( "Updating package.json URLs..." ); json = Release.readPackage(); - json.author.url = json.author.url.replace( "master", Release.newVersion ); + json.author.url = json.author.url.replace( "main", Release.newVersion ); if ( json.licenses ) { json.licenses.forEach( function( license ) { - license.url = license.url.replace( "master", Release.newVersion ); + license.url = license.url.replace( "main", Release.newVersion ); } ); } Release.writePackage( json );