{"id":15406751,"url":"https://github.com/dannyben/getcomments","last_synced_at":"2025-09-10T05:12:14.225Z","repository":{"id":56874029,"uuid":"83891892","full_name":"DannyBen/getcomments","owner":"DannyBen","description":"Extract Comments from Ruby Code","archived":false,"fork":false,"pushed_at":"2023-04-09T14:08:42.000Z","size":27,"stargazers_count":2,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-27T19:02:43.976Z","etag":null,"topics":["comments","documentation","gem","ruby"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DannyBen.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-03-04T12:30:23.000Z","updated_at":"2023-08-10T15:35:35.000Z","dependencies_parsed_at":"2024-10-19T12:33:21.103Z","dependency_job_id":"8c9b8ef6-e2b3-4ad2-954d-39a1451e26d1","html_url":"https://github.com/DannyBen/getcomments","commit_stats":{"total_commits":33,"total_committers":2,"mean_commits":16.5,"dds":0.3939393939393939,"last_synced_commit":"fbabcd244ea16e67345df51409775c3ecf14e606"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/DannyBen/getcomments","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DannyBen%2Fgetcomments","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DannyBen%2Fgetcomments/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DannyBen%2Fgetcomments/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DannyBen%2Fgetcomments/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DannyBen","download_url":"https://codeload.github.com/DannyBen/getcomments/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DannyBen%2Fgetcomments/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274416273,"owners_count":25280925,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-10T02:00:12.551Z","response_time":83,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["comments","documentation","gem","ruby"],"created_at":"2024-10-01T16:25:13.265Z","updated_at":"2025-09-10T05:12:14.218Z","avatar_url":"https://github.com/DannyBen.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"GetComments - Extract Comments from Ruby Code\n==================================================\n\nThis library provides an easy way to extract comments from a ruby source file.\n\n\nInstall\n--------------------------------------------------\n\n```\n$ gem install getcomments\n```\n\nOr with bundler:\n\n```\ngem 'getcomments'\n```\n\n\nUsage\n--------------------------------------------------\n\nGet comments from a file:\n\n```ruby\n# GetComments.from_file\nrequire 'getcomments'\ncomments = GetComments.from_file 'spec/fixtures/minimal.rb'\ncomments.each do |key, value|\n  puts \"#{key}: #{value}\"\nend\n\n#=\u003e module TestModule: Module comment\n#=\u003e class TestClass: Class comment\n#=\u003e attr_reader :some_attr: Attribute comment\n#=\u003e def some_method: Method comment\n```\n\nGet comments from a string:\n\n```ruby\n# GetComments.from_string\ncode = \u003c\u003c-EOF\n  # This function just sits here\n  def the_function\n  end\nEOF\n\ncomments = GetComments.from_string code\ncomments.each do |key, value|\n  puts \"#{key}: #{value}\"\nend\n\n#=\u003e def the_function: This function just sits here\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdannyben%2Fgetcomments","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdannyben%2Fgetcomments","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdannyben%2Fgetcomments/lists"}