Skip to content

Commit 6da33c9

Browse files
committed
chore(ui-scripts,pkg-utils): add debug logs for manual npm release
1 parent 22311c7 commit 6da33c9

File tree

2 files changed

+22
-0
lines changed

2 files changed

+22
-0
lines changed

packages/pkg-utils/lib/get-changed-packages.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable no-console */
12
/*
23
* The MIT License (MIT)
34
*
@@ -32,11 +33,21 @@ module.exports = function getChangedPackages(
3233
) {
3334
allPackages = allPackages || getPackages() // eslint-disable-line no-param-reassign
3435

36+
// TODO REMOVE DEBUG LOG
37+
console.log('\n\nDEBUG LOG: allPackages')
38+
console.log(allPackages)
39+
console.log('---------\n\n')
40+
3541
const result = childProcess
3642
.execSync('git diff ' + commitIsh + ' --name-only', { stdio: 'pipe' })
3743
.toString()
3844
const changedFiles = result.split('\n')
3945

46+
// TODO REMOVE DEBUG LOG
47+
console.log('\n\nDEBUG LOG: changedFiles')
48+
console.log(changedFiles)
49+
console.log('---------\n\n')
50+
4051
return allPackages.filter((pkg) => {
4152
const relativePath = path.relative('.', pkg.location) + path.sep
4253
return (

packages/ui-scripts/lib/utils/npm.js

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
/* eslint-disable no-console */
12
/*
23
* The MIT License (MIT)
34
*
@@ -39,6 +40,11 @@ const syncRootPackageVersion = async (useProjectVersion) => {
3940
const project = new Project(process.cwd())
4041
const rootPkg = pkgUtils.getPackage()
4142

43+
// TODO REMOVE DEBUG LOG
44+
console.log('\n\nDEBUG LOG 1: project')
45+
console.log(project)
46+
console.log('---------\n\n')
47+
4248
let projectVersion
4349

4450
if (project.isIndependent() || useProjectVersion) {
@@ -97,6 +103,11 @@ export async function bumpPackages(packageName, requestedVersion) {
97103

98104
releaseVersion = await syncRootPackageVersion(true)
99105

106+
// TODO REMOVE DEBUG LOG
107+
console.log('\n\nDEBUG LOG 2: releaseVersion')
108+
console.log(releaseVersion)
109+
console.log('---------\n\n')
110+
100111
info(`📦 Done bumping ${packageName} to ${releaseVersion}!`)
101112
} catch (err) {
102113
error(err)

0 commit comments

Comments
 (0)