Update release stats workflow (#17580)
Follow-up to https://github.com/vercel/next.js/pull/17533 this makes sure the file used to signal release stats should be skipped for a non-release merge is created in a location that is accessible by the stats action and also updates the release action info detection for the new workflow
This commit is contained in:
parent
b42be17593
commit
100a1d3acc
3 changed files with 5 additions and 3 deletions
|
@ -27,7 +27,7 @@ if (!allowedActions.has(actionInfo.actionName) && !actionInfo.isRelease) {
|
|||
|
||||
;(async () => {
|
||||
try {
|
||||
if (await fs.pathExists(path.join(process.cwd(), 'SKIP_NEXT_STATS.txt'))) {
|
||||
if (await fs.pathExists(path.join(__dirname, '../SKIP_NEXT_STATS.txt'))) {
|
||||
console.log(
|
||||
'SKIP_NEXT_STATS.txt file present, exiting stats generation..'
|
||||
)
|
||||
|
|
|
@ -56,7 +56,9 @@ module.exports = function actionInfo() {
|
|||
isLocal: LOCAL_STATS,
|
||||
commitId: null,
|
||||
issueId: ISSUE_ID,
|
||||
isRelease: releaseTypes.has(GITHUB_ACTION),
|
||||
isRelease:
|
||||
GITHUB_REPOSITORY === 'vercel/next.js' &&
|
||||
(GITHUB_REF || '').includes('canary'),
|
||||
}
|
||||
|
||||
// get comment
|
||||
|
|
|
@ -4,7 +4,7 @@ git describe --exact-match
|
|||
|
||||
if [[ ! $? -eq 0 ]];then
|
||||
echo "Nothing to publish, exiting.."
|
||||
touch SKIP_NEXT_STATS.txt
|
||||
touch .github/actions/next-stats-action/SKIP_NEXT_STATS.txt
|
||||
exit 0;
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in a new issue