Skip to content

Commit

Permalink
Log gitoid search
Browse files Browse the repository at this point in the history
Signed-off-by: John Kjell <[email protected]>
  • Loading branch information
jkjell committed Apr 13, 2024
1 parent dcfa3ac commit 8199b82
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -30669,11 +30669,14 @@ function extractDesiredGitOID(output) {
const lines = output.split("\n");
const desiredSubstring = "Stored in archivist as ";

console.log("Looking for Git OID in the output")
for (const line of lines) {
const startIndex = line.indexOf(desiredSubstring);
if (startIndex !== -1) {
console.log("Checking line: ", line)
const match = line.match(/[0-9a-fA-F]{64}/);
if (match) {
console.log("Found Git OID: ", match[0])
return match[0];
}
}
Expand Down
3 changes: 3 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,11 +192,14 @@ function extractDesiredGitOID(output) {
const lines = output.split("\n");
const desiredSubstring = "Stored in archivist as ";

console.log("Looking for Git OID in the output")
for (const line of lines) {
const startIndex = line.indexOf(desiredSubstring);
if (startIndex !== -1) {
console.log("Checking line: ", line)
const match = line.match(/[0-9a-fA-F]{64}/);
if (match) {
console.log("Found Git OID: ", match[0])
return match[0];
}
}
Expand Down

0 comments on commit 8199b82

Please sign in to comment.