chore: fix base_ref

This commit is contained in:
usbharu 2024-08-10 14:11:15 +09:00
parent 6062230e78
commit 3fcd7ae917
Signed by: usbharu
GPG Key ID: 6556747BF94EEBC8
1 changed files with 3 additions and 2 deletions

View File

@ -21,11 +21,12 @@ jobs:
const fs = require('fs')
const {execSync} = require('child_process');
const jsonData = JSON.parse(fs.readFileSync('./.github/monorepo.json', 'utf8'));
const baseRef = github.context.payload.pull_request.base.ref
console.log(baseRef)
var tags = []
for (let [key, value] of Object.entries(jsonData.projects)) {
const command = "git diff origin/master HEAD --name-only --relative=" + key + "\n";
const command = "git diff " + baseRef + " HEAD --name-only --relative=" + key + "\n";
const output = execSync(command, {encoding: 'utf8'});
if (output.length != 0) {
tags.push(value)