MCPcopy Index your code
hub / github.com/react/react / getDateStringForCommit

Function getDateStringForCommit

scripts/release/utils.js:98–109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96};
97
98const getDateStringForCommit = async commit => {
99 let dateString = await execRead(
100 `git show -s --no-show-signature --format=%cd --date=format:%Y%m%d ${commit}`
101 );
102
103 // On CI environment, this string is wrapped with quotes '...'s
104 if (dateString.startsWith("'")) {
105 dateString = dateString.slice(1, 9);
106 }
107
108 return dateString;
109};
110
111const getCommitFromCurrentBuild = async () => {
112 const cwd = join(__dirname, '..', '..');

Callers 2

runFunction · 0.70
getBuildInfoFunction · 0.70

Calls 1

execReadFunction · 0.70

Tested by

no test coverage detected