{"id":13412075,"url":"https://github.com/plentz/lol_dba","last_synced_at":"2026-10-19T12:04:50.403Z","repository":{"id":2589192,"uuid":"3570815","full_name":"plentz/lol_dba","owner":"plentz","description":"lol_dba is a small package of rake tasks that scan your application models and displays a list of columns that probably should be indexed. Also, it can generate .sql migration scripts.","archived":false,"fork":false,"pushed_at":"2026-03-23T18:59:18.000Z","size":416,"stargazers_count":1595,"open_issues_count":15,"forks_count":70,"subscribers_count":11,"default_branch":"master","last_synced_at":"2026-10-14T14:29:37.423Z","etag":null,"topics":["database","database-migrations","gem","migrations","rails","ruby","ruby-on-rails","sql"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/plentz.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2012-02-28T12:31:11.000Z","updated_at":"2026-09-01T20:20:09.000Z","dependencies_parsed_at":"2024-06-18T15:26:16.350Z","dependency_job_id":"d924db29-2a1a-47f0-bc77-4aa303aff51d","html_url":"https://github.com/plentz/lol_dba","commit_stats":{"total_commits":384,"total_committers":31,"mean_commits":"12.387096774193548","dds":"0.36458333333333337","last_synced_commit":"58e51ae4487fd797b09182e4fb96a2d87a51eab8"},"previous_names":[],"tags_count":20,"template":false,"template_full_name":null,"purl":"pkg:github/plentz/lol_dba","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plentz%2Flol_dba","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plentz%2Flol_dba/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plentz%2Flol_dba/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plentz%2Flol_dba/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/plentz","download_url":"https://codeload.github.com/plentz/lol_dba/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/plentz%2Flol_dba/sbom","scorecard":{"id":737674,"data":{"date":"2025-08-11","repo":{"name":"github.com/plentz/lol_dba","commit":"58e51ae4487fd797b09182e4fb96a2d87a51eab8"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":2.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 1/19 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/build.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/build.yml:20: update your workflow using https://app.stepsecurity.io/secureworkflow/plentz/lol_dba/build.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/build.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/plentz/lol_dba/build.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/build.yml:31: update your workflow using https://app.stepsecurity.io/secureworkflow/plentz/lol_dba/build.yml/master?enable=pin","Info:   0 out of   1 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   2 third-party GitHubAction dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":0,"reason":"license file not detected","details":["Warn: project does not have a license file"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":-1,"reason":"internal error: error during branchesHandler.setup: internal error: githubv4.Query: Resource not accessible by integration","details":null,"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 22 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Vulnerabilities","score":0,"reason":"26 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-4g8v-vg43-wpgf","Warn: Project is vulnerable to: GHSA-9822-6m93-xqf4","Warn: Project is vulnerable to: GHSA-fwhr-88qx-h9g7","Warn: Project is vulnerable to: GHSA-vfg9-r3fq-jvx4","Warn: Project is vulnerable to: GHSA-vfm5-rmrh-j26v","Warn: Project is vulnerable to: GHSA-x76w-6vjr-8xgj","Warn: Project is vulnerable to: GHSA-xp5h-f8jf-rc8q","Warn: Project is vulnerable to: GHSA-76r7-hhxj-r776","Warn: Project is vulnerable to: GHSA-cr5q-6q9f-rq6q","Warn: Project is vulnerable to: GHSA-pj73-v5mw-pm9j","Warn: Project is vulnerable to: GHSA-353f-x4gh-cqq8","Warn: Project is vulnerable to: GHSA-5w6v-399v-w3cc","Warn: Project is vulnerable to: GHSA-mrxw-mxhj-p664","Warn: Project is vulnerable to: GHSA-pxvg-2qj5-37jq","Warn: Project is vulnerable to: GHSA-r95h-9x8f-r3f7","Warn: Project is vulnerable to: GHSA-vvfq-8hwr-qm4m","Warn: Project is vulnerable to: GHSA-xc9x-jj77-9p9j","Warn: Project is vulnerable to: GHSA-22f2-v57c-j9cx","Warn: Project is vulnerable to: GHSA-54rr-7fvw-6x8f","Warn: Project is vulnerable to: GHSA-7g2v-jj9q-g3rg","Warn: Project is vulnerable to: GHSA-7wqh-767x-r66v","Warn: Project is vulnerable to: GHSA-8cgq-6mh2-7j6v","Warn: Project is vulnerable to: GHSA-c6qg-cjj8-47qp","Warn: Project is vulnerable to: GHSA-gjh7-p2fx-99vx","Warn: Project is vulnerable to: GHSA-vpfw-47h7-xj4g","Warn: Project is vulnerable to: GHSA-xj5v-6v4g-jfw6"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-22T16:22:50.867Z","repository_id":2589192,"created_at":"2025-08-22T16:22:50.867Z","updated_at":"2025-08-22T16:22:50.867Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":344872684,"owners_count":38356448,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-10-03T21:59:58.778Z","status":"online","status_checked_at":"2026-10-19T02:00:06.414Z","response_time":53,"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":["database","database-migrations","gem","migrations","rails","ruby","ruby-on-rails","sql"],"created_at":"2024-07-30T20:01:20.755Z","updated_at":"2026-10-19T12:04:50.397Z","avatar_url":"https://github.com/plentz.png","language":"Ruby","funding_links":[],"categories":["Ruby","Active Record Plugins","ActiveRecord","Database Tools","WebSocket","Awesome Ruby CLIs"],"sub_categories":["Active Record Index Assistants","Database"],"readme":"# lol_dba [![ci](https://github.com/plentz/lol_dba/actions/workflows/build.yml/badge.svg)](https://github.com/plentz/lol_dba/actions) [![Maintainability](https://api.codeclimate.com/v1/badges/a5cc1172ec1291536904/maintainability)](https://codeclimate.com/github/plentz/lol_dba/maintainability) [![Test Coverage](https://api.codeclimate.com/v1/badges/a5cc1172ec1291536904/test_coverage)](https://codeclimate.com/github/plentz/lol_dba/test_coverage)\n\nlol_dba is a small package of rake tasks that scan your application models and displays a list of columns that probably should be indexed. Also, it can generate .sql migration scripts.\n\n### Quick example\n\nTo use lol_dba in the easiest way possible you have to do two things:\n\n\tgem install lol_dba\n\nThen run one of the following commands...\n\nTo display a migration for adding/removing all necessary indexes based on associations:\n\n\tlol_dba db:find_indexes\n\nTo generate .sql files for your migrations inside db/migrate_sql folder:\n\n\tlol_dba db:migrate_sql # defaults to all migrations\n\tlol_dba db:migrate_sql[pending] # only pending migrations\n\tlol_dba db:migrate_sql[20120221205526] # generate sql only for migration 20120221205526\n\n### Not-so-quick example\n\nIf you want to use lol_dba with rake, you should do a few more steps:\n\nAdd lol_dba to your Gemfile\n\n    gem \"lol_dba\"\n\nRun the install command\n\n    bundle install\n\nUse it the same way you use other rake commands\n\n\trake db:find_indexes\n\trake db:migrate_sql # defaults to all migrations\n\trake db:migrate_sql[pending] # only pending migrations\n\trake db:migrate_sql[20120221205526] # generate sql only for migration 20120221205526\n\n### Compatibility\n\nCompatible with Ruby 2.x, Ruby 3.x and Rails 3.x, 4.x, 5.x, 6.x, 7.x and 8.x.\n\n### About primary_key\n\n\u003eThe primary key is always indexed. This is generally true for all storage engines that at all supports indexes.\n\nFor this reason, we no longer suggest to add indexes to primary keys.\n\n### Tests\n\nTo run lol_dba tests, just clone the repo and run:\n\n    bundle install \u0026\u0026 rake\n\n### Contributors\nMost of the initial code came from [rails_indexes](https://github.com/warpc/rails_indexes) and [migration_sql_generator](https://github.com/muness/migration_sql_generator). [Other people helped as well](https://github.com/plentz/lol_dba/graphs/contributors).\n\n### License\n\nLol DBA is released under the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplentz%2Flol_dba","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fplentz%2Flol_dba","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fplentz%2Flol_dba/lists"}