Skip to content

Commit

Permalink
update registration regex
Browse files Browse the repository at this point in the history
  • Loading branch information
varadarajan-tw committed Mar 4, 2024
1 parent 0bcc1ed commit 8f79aeb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/compute-labels.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ async function computeFileBasedLabels(github, context, core) {
const files = await github.paginate(opts)

// The following regexes are used to match the new destinations
const newCloudDestinationRegex = /packages\/destination\-actions\/src\/destinations\/.*\/index\.ts/i
const newBrowserDestinationRegex = /packages\/browser\-destinations\/destinations\/.*\/src\/index\.ts/i
const newCloudDestinationRegex = /packages\/destination\-actions\/src\/destinations\/[^\/]+\/index\.ts/i
const newBrowserDestinationRegex = /packages\/browser\-destinations\/destinations\/[^\/]+\/src\/index\.ts/i
const isNew = (filename) => newCloudDestinationRegex.test(filename) || newBrowserDestinationRegex.test(filename)

const isNewDestination = files.some((file) => isNew(file.filename) && file.status === 'added')
Expand Down

0 comments on commit 8f79aeb

Please sign in to comment.