Skip to content

feat: packaging and devshell with various cargo-pgrx versions! #1277

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

Merged
merged 6 commits into from
Oct 22, 2024

Conversation

samrose
Copy link
Collaborator

@samrose samrose commented Oct 16, 2024

What kind of change does this PR introduce?

This PR allows us to package any cargo-pgrx package with any version of cargo-pgrx we choose, and any version of rust we choose, per package

It also includes a way to create a devShell that can be accessed through nix develop to have the version of cargo-pgrx you need on path without having to manage it on your machine. We can also specify rust versions in the shell too

example

samrose@Sams-MBP-2 postgres % nix develop .#cargo-pgrx_0_11_3        
Restored session: Wed Oct 16 12:28:59 EDT 2024
(nix:nix-shell-env) Sams-MBP-2:postgres samrose$ cargo-pgrx --version
cargo 0.11.3
(nix:nix-shell-env) Sams-MBP-2:postgres samrose$ exit
exit

Saving session...
...saving history...truncating history files...
...completed.
samrose@Sams-MBP-2 postgres % nix develop .#cargo-pgrx_0_12_6
warning: 'https://cache.flakehub.com' does not appear to be a binary cache
Restored session: Wed Oct 16 12:32:24 EDT 2024
(nix:nix-shell-env) Sams-MBP-2:postgres samrose$ cargo-pgrx --version
cargo 0.12.6

@samrose samrose requested review from olirice and burmecia October 16, 2024 16:26
@samrose samrose marked this pull request as ready for review October 17, 2024 13:35
@samrose samrose requested a review from a team as a code owner October 17, 2024 13:35
@samrose samrose merged commit 743c6f7 into develop Oct 22, 2024
5 of 8 checks passed
@samrose samrose deleted the sam/cargo-pgrx-versions branch October 22, 2024 14:46
soedirgo added a commit that referenced this pull request Oct 28, 2024
damonrand pushed a commit to cepro/postgres that referenced this pull request Jun 15, 2025
…ase#1277)

* feat: packaging and devshell with various cargo-pgrx versions!

* feat: cargo-pgrx_0_12_6 instead

* feat: devshell with rust versions

* rust versions in devshell + try to make wrappers build again

* feat: override rust versions in buildPgrxExtension

* chore: newline

---------

Co-authored-by: Sam Rose <samuel@supabase.io>
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.

4 participants