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

[CleanRepo] Add a command to compare / list latest commit, size and ms.date metadata #449

Open
BillWagner opened this issue Dec 3, 2024 · 0 comments
Assignees
Labels
📌 seQUESTered Identifies that an issue has been imported into Quest.

Comments

@BillWagner
Copy link
Member

BillWagner commented Dec 3, 2024

We think there are situations where an article gets a major update, but the ms.date metadata isn't updated in that commit. To find those, add a command to CleanRepo that traverses all the source files in the local copy of the repo and compares the dates of recent commits to the ms.date value.

To get the commit history, a query like this works:

query FileHistory {  repository(owner: "dotnet", name: "docs") 
{
    defaultBranchRef{
      target {
        ...on Commit{
            history(first:10,path: "docs/csharp/fundamentals/program-structure/top-level-statements.md"){
            nodes {
              committedDate
              changedFilesIfAvailable
               additions
              deletions
            }
          }
        }
      }
    }
  }
}

To find the ms.date value, the metadata block for each file needs to be read. Also, the docfx.json file needs to be partially processed to read any global metadata for ms.date and any file path based metadata for ms.date.


Associated WorkItem - 360306

@BillWagner BillWagner added the 🗺️ reQUEST Triggers an issue to be imported into Quest. label Jan 6, 2025
@sequestor sequestor bot added 📌 seQUESTered Identifies that an issue has been imported into Quest. and removed 🗺️ reQUEST Triggers an issue to be imported into Quest. labels Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📌 seQUESTered Identifies that an issue has been imported into Quest.
Projects
Development

No branches or pull requests

2 participants