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

Support for the user specified version of the init command #1250

Closed

Conversation

ongchi
Copy link

@ongchi ongchi commented Aug 4, 2023

In current version, user pass path to pg_config tool or download to use local installed or download and build from source from postgres latest release tarball.

This pr extends init option to support custom version:

cargo pgrx init --pg12 12.10

Passing latest as option will also download and install the latest version from source release, which is identical to download, while the download option still remains for backward compatibility.

Closes: #149

@eeeebbbbrrrr
Copy link
Contributor

eeeebbbbrrrr commented Aug 4, 2023

I haven’t looked at the PR yet but I’m not keen on this idea.

We’ve already had a PR for this and I didn’t find the argument very persuasive. EDIT: sorry I guess it was the issue linked above.

If pgrx is to support specific major versions then it needs a lot more consideration than just this.

I still think the correct way to handle this workflow is to install that version locally yourself and use cargo pgrx init with a different PGRX_HOME.

In day-to-day development of a pgrx extension there should be no differences between point releases of a major version. So the only reason to install a specific one would be to evaluate an extension against an older Postgres that probably had a bug. I don’t see this as under pgrx’ perview.

@ongchi
Copy link
Author

ongchi commented Aug 5, 2023

Thank you for your feedback and I understand your decision. I'll close this PR.

@ongchi ongchi closed this Aug 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: cargo pgx init --pg12=https://ftp.postgresql.org/pub/source/v12.6/postgresql-12.6.tar.bz2
2 participants