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

Closed
BillWagner opened this issue Dec 3, 2024 · 1 comment
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
@gewarren gewarren removed their assignment Jan 11, 2025
@BillWagner BillWagner moved this from 🔖 Ready to 🏗 In progress in dotnet/docs January 2025 sprint project Jan 27, 2025
@BillWagner BillWagner moved this from 🏗 In progress to 👀 In review in dotnet/docs January 2025 sprint project Jan 30, 2025
@BillWagner
Copy link
Member Author

Fixed in #469

@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in dotnet/docs January 2025 sprint project Jan 31, 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
No open projects
Development

No branches or pull requests

2 participants