{"id":30858712,"url":"https://github.com/urbica/pg-migrate","last_synced_at":"2025-09-07T14:17:01.775Z","repository":{"id":41128724,"uuid":"98910364","full_name":"urbica/pg-migrate","owner":"urbica","description":"PostgreSQL migration tool","archived":false,"fork":false,"pushed_at":"2023-11-29T14:08:21.000Z","size":3122,"stargazers_count":47,"open_issues_count":13,"forks_count":4,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-08-08T23:50:00.679Z","etag":null,"topics":["database","migration","migrations","nodejs","postgresql"],"latest_commit_sha":null,"homepage":"https://urbica.github.io/pg-migrate","language":"JavaScript","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/urbica.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","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}},"created_at":"2017-07-31T16:53:13.000Z","updated_at":"2025-04-09T20:14:23.000Z","dependencies_parsed_at":"2023-11-29T15:29:15.298Z","dependency_job_id":"5d4d81ab-5c80-4672-9e4e-ecbbccd1e868","html_url":"https://github.com/urbica/pg-migrate","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"purl":"pkg:github/urbica/pg-migrate","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/urbica%2Fpg-migrate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/urbica%2Fpg-migrate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/urbica%2Fpg-migrate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/urbica%2Fpg-migrate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/urbica","download_url":"https://codeload.github.com/urbica/pg-migrate/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/urbica%2Fpg-migrate/sbom","scorecard":{"id":911870,"data":{"date":"2025-08-11","repo":{"name":"github.com/urbica/pg-migrate","commit":"b26c42318a8d08ddfe72b2559908babcb6e8f0ab"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.3,"checks":[{"name":"Code-Review","score":2,"reason":"Found 3/15 approved changesets -- score normalized to 2","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":"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":"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":"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":"Pinned-Dependencies","score":5,"reason":"dependency not pinned by hash detected -- score normalized to 5","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/urbica/pg-migrate/ci.yml/master?enable=pin","Info:   0 out of   1 GitHub-owned GitHubAction dependencies pinned","Info:   1 out of   1 npmCommand 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":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/ci.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":"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":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"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":"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 21 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":"34 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-whgm-jr23-g3j9","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq","Warn: Project is vulnerable to: GHSA-4gmj-3p3h-gm8h","Warn: Project is vulnerable to: GHSA-8mmm-9v2q-x3f9","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-mwcw-c2x4-8c55","Warn: Project is vulnerable to: GHSA-3j8f-xvm3-ffx4","Warn: Project is vulnerable to: GHSA-4p35-cfcx-8653","Warn: Project is vulnerable to: GHSA-7f3x-x4pr-wqhj","Warn: Project is vulnerable to: GHSA-jpp7-7chh-cf67","Warn: Project is vulnerable to: GHSA-q6wq-5p59-983w","Warn: Project is vulnerable to: GHSA-j9fq-vwqv-2fm2","Warn: Project is vulnerable to: GHSA-pqw5-jmp5-px4v","Warn: Project is vulnerable to: GHSA-ff9h-848c-4xfj","Warn: Project is vulnerable to: GHSA-7fh5-64p2-3v2j","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-hpqj-7cj6-hfj8","Warn: Project is vulnerable to: GHSA-4vrv-93c7-m92j","Warn: Project is vulnerable to: GHSA-4x6g-3cmx-w76r","Warn: Project is vulnerable to: GHSA-6hwc-9h8r-3vmf","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-g3ch-rx76-35fx","Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7"],"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-24T19:30:36.843Z","repository_id":41128724,"created_at":"2025-08-24T19:30:36.843Z","updated_at":"2025-08-24T19:30:36.843Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274046016,"owners_count":25212985,"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-07T02:00:09.463Z","response_time":67,"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","migration","migrations","nodejs","postgresql"],"created_at":"2025-09-07T14:16:45.228Z","updated_at":"2025-09-07T14:17:01.763Z","avatar_url":"https://github.com/urbica.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Urbica PG Migrate\n\n[![npm version](https://img.shields.io/npm/v/@urbica/pg-migrate.svg)](https://www.npmjs.com/package/@urbica/pg-migrate)\n[![npm downloads](https://img.shields.io/npm/dt/@urbica/pg-migrate.svg)](https://www.npmjs.com/package/@urbica/pg-migrate)\n[![CI](https://github.com/urbica/pg-migrate/workflows/CI/badge.svg)](https://github.com/urbica/pg-migrate/actions)\n\nPostgreSQL migration tool.\n\n[Documentation](https://urbica.github.io/pg-migrate/).\n\n![Screenshot](https://raw.githubusercontent.com/urbica/pg-migrate/master/screenshot.png)\n\n## Installation\n\n`pg-migrate` requires node v7.6.0 or higher for ES2015 and async function support.\n\n```shell\nnpm install -g @urbica/pg-migrate\n```\n\n...or build from source\n\n```shell\ngit clone https://github.com/urbica/pg-migrate.git\ncd pg-migrate\nnpm install\n```\n\n## Usage\n\n```shell\nUsage:\n  pg-migrate [options] new \u003cname\u003e\n  pg-migrate [options] migrate\n  pg-migrate [options] rollback \u003cN\u003e\n  pg-migrate [options] reset\n  pg-migrate --help\n  pg-migrate --version\n\nExamples:\n  pg-migrate new create-users\n  pg-migrate migrate\n  pg-migrate rollback 1\n  pg-migrate reset\n\nOptions:\n  --help                        Show this screen\n  --version                     Show version\n  --verbose                     Show verbose output\n  -m --migrations-dir=DIR       The directory containing your migration files [default: ./migrations]\n  -t --migrations-table=TABLE   Set the name of the migrations table          [default: migrations]\n  -s --migrations-schema=SCHEMA Set the name of the migrations table scheme   [default: public]\n\nConnection options:\n  -c --connection=DATABASE_URL        database connection string in libpq format\n  -d --db=PGDATABASE                  database name to connect to\n  -h --host=PGHOST                    database server host or socket directory      [default: localhost]\n  -p --port=PGPORT                    database server port                          [default: 5432]\n  -U --user=PGUSER                    database user name\n  -W --password=PGPASSWORD            database user name password\n```\n\n## Node.js API\n\nUsing Promises\n\n```js\nconst PgMigrate = require('@urbica/pg-migrate');\nconst pgMigrate = new PgMigrate({\n  database: 'test',\n  migrationsDir: './migrations'\n});\n\npgMigrate\n  .connect()\n  .then(() =\u003e pgMigrate.migrate())\n  .then(() =\u003e pgMigrate.end());\n```\n\n...or using async/await\n\n```js\nconst pgMigrate = new PgMigrate({ database, user, migrationsDir });\n\nasync function migrate() {\n  await pgMigrate.connect();\n  await pgMigrate.migrate();\n  await pgMigrate.end();\n}\n\nmigrate();\n```\n\nSee [API](https://urbica.github.io/pg-migrate/) for more info.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Furbica%2Fpg-migrate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Furbica%2Fpg-migrate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Furbica%2Fpg-migrate/lists"}