Skip to content

Commit

Permalink
Merge pull request #2 from boughtbymany/fix/no-valid-tags-in-monorepo
Browse files Browse the repository at this point in the history
fix: check more tags to workaround monorepo issue
  • Loading branch information
roblambell authored Nov 15, 2023
2 parents eeaf892 + 4fa152c commit 50f5665
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -31080,7 +31080,7 @@ async function main () {
const tagsRaw = await gh.graphql(`
query lastTags ($owner: String!, $repo: String!) {
repository (owner: $owner, name: $repo) {
refs(first: 10, refPrefix: "refs/tags/", orderBy: { field: TAG_COMMIT_DATE, direction: DESC }) {
refs(first: 100, refPrefix: "refs/tags/", orderBy: { field: TAG_COMMIT_DATE, direction: DESC }) {
nodes {
name
target {
Expand Down Expand Up @@ -31115,7 +31115,7 @@ async function main () {
}

if (!latestTag) {
return core.setFailed(skipInvalidTags ? 'None of the 10 latest tags are valid semver!' : 'Latest tag is invalid (does not conform to semver)!')
return core.setFailed(skipInvalidTags ? 'None of the 100 latest tags are valid semver!' : 'Latest tag is invalid (does not conform to semver)!')
}

core.info(`Comparing against latest tag: ${prefix}${latestTag.name}`)
Expand Down
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ async function main () {
const tagsRaw = await gh.graphql(`
query lastTags ($owner: String!, $repo: String!) {
repository (owner: $owner, name: $repo) {
refs(first: 10, refPrefix: "refs/tags/", orderBy: { field: TAG_COMMIT_DATE, direction: DESC }) {
refs(first: 100, refPrefix: "refs/tags/", orderBy: { field: TAG_COMMIT_DATE, direction: DESC }) {
nodes {
name
target {
Expand Down Expand Up @@ -76,7 +76,7 @@ async function main () {
}

if (!latestTag) {
return core.setFailed(skipInvalidTags ? 'None of the 10 latest tags are valid semver!' : 'Latest tag is invalid (does not conform to semver)!')
return core.setFailed(skipInvalidTags ? 'None of the 100 latest tags are valid semver!' : 'Latest tag is invalid (does not conform to semver)!')
}

core.info(`Comparing against latest tag: ${prefix}${latestTag.name}`)
Expand Down

0 comments on commit 50f5665

Please sign in to comment.