Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Commit checks from forks are now included #72

Draft
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

PriyaBihani
Copy link
Contributor

Fixes #52

@ljharb
Copy link
Owner

ljharb commented Mar 31, 2022

I'd have preferred to reuse #62; let's now keep both open so they can be kept in sync.

Comment on lines +51 to +55
return response.repository.commit?.statusCheckRollup?.contexts?.nodes;
} catch (error) {
console.log(error);
return null;
}
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
return response.repository.commit?.statusCheckRollup?.contexts?.nodes;
} catch (error) {
console.log(error);
return null;
}
} catch (error) {
console.log(error);
return null;
}
return response.repository.commit?.statusCheckRollup?.contexts?.nodes;

Comment on lines +59 to +60
const node = JSON.parse(JSON.stringify(ogNode));
// console.log(JSON.stringify(node,undefined,2));
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rather than cloning here, maybe we could { ...ogNode, commit: { ...ogNode.commit, ...newCommit } }?

Comment on lines +8 to +10
const command = short ? `git show ${identifier} -s --format="%h"` : `git show ${identifier} -s --format="%H"`;
const stdout = String(exec(command));
return stdout;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
const command = short ? `git show ${identifier} -s --format="%h"` : `git show ${identifier} -s --format="%H"`;
const stdout = String(exec(command));
return stdout;
const command = `git show ${identifier} -s --format="%${short ? 'h' : 'H'}"`;
return String(exec(command));

@ljharb ljharb marked this pull request as draft April 26, 2022 04:51
ljharb pushed a commit that referenced this pull request Apr 26, 2022
@ljharb ljharb closed this Apr 29, 2022
@ljharb ljharb reopened this Apr 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

commit statuses from forks are not included
2 participants