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

proposal: create an ARCHIVE.MD #4200

Closed
switchupcb opened this issue Apr 25, 2022 · 1 comment
Closed

proposal: create an ARCHIVE.MD #4200

switchupcb opened this issue Apr 25, 2022 · 1 comment

Comments

@switchupcb
Copy link
Contributor

switchupcb commented Apr 25, 2022

Instead of removing projects, it may be useful to archive them. This can be implemented using a bot that (on update):

  1. Parses raw markdown from README.MD: https://github.com/yuin/goldmark
  2. Checks library URLs with the Github API for archive status: https://docs.github.com/en/rest/repos/repos#get-a-repository
  3. Remove archived libraries from the README (delete the line from the MD).
  4. Add the removed library to the ARCHIVE.

Instead of "deleting" the line, simply iterate line by line and include it when necessary.

var ARCHIVE strings.Builder
var README strings.Builder

// content represents the lines or file.
for _, line := range content {
    repo := getRepository(line)

    // add conditions where necessary
    switch {
      case repo.archive:
        ARCHIVE.WriteString(line)
      default:        
        README.WriteString(line)
    } 
}

You could also add reasons for archive in that README such as archived, standards, etc.

@phanirithvij
Copy link
Collaborator

Just adding to this, the current process is manual.
Usually when a project is archived it's eol (abandoned) and thus in such cases a community/other fork will replace the one in the readme if there is one.
This is the more important part where we need to focus, I believe than to maintain a list of old abandoned projects.

@avelino avelino closed this as completed May 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants