-
Notifications
You must be signed in to change notification settings - Fork 29
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
Add support for development branch? #25
Comments
It sounds interesting, but I see a lot of things to think about. However, I would not touch |
Thinking after a coffee, it could be worth adding a kind of |
Yeah, I like the idea of a |
This command acts as an alias for 'build dev', that is introduces the special version 'dev' to instrument the build process to download the source tree via git instead of getting a tarball. If the 'dev' version has never been created, than a complete checkout is performed; otherwise a fetch is done. The build process continues as usual, with patching, make, and etc. At the end, the 'pgenv-dev' directory will be in place to indicate the new version of PostgreSQL. It is possible to configure the git process via two special variables, that have not been introduced in the configuration mechanism because they represent developer tweaks; they can be manually added in any case. Documentation updated. See theory#25
I've implemented a first possible approach to the problem. See pull request #26 At the moment I'm not able to complete the build process on my machine for a docbook problem, but seems correct to me. Probably there is the need for some tweaking around the git checkout and fetch process. |
I am rather late to the party and did not notice this issue at first. |
@e7e6 while avoiding git dependency could sound good, I think that for this particular feature it is better to keep git working, since it could help "upgrading" the code base instead of having to download the whole source tree every time. |
The application already has a way to build from a local git repository. The idea of this commit is to provide a way to specify the HEAD version to indicate PostgreSQL has to be built from the current git checkout. Specify the `git_tag` as a possible argument to `build git`. Update the documentation accordingly. See discussion and initial work in theory#26
@fluca1978 @xzilla I'm interested in this! Wondering if it was completed at some point in time in the past or was still a WIP? I'd be available to help test compilation on Mac and sliding those commands into shell scripts, if it helps. My ideal DX would be something like Or maybe running compilation steps from my local git checkout, like |
Well, so far we have the chance to compile from a local repostiory by means of setting the environment variable |
I tried this last week, by coincidence. It already uses tags, so if you tell it to build 16.2, it knows to build To get this to work, I think we'd need loosen the version checking when |
I'm wondering about the idea of adding support for the development branch (currently postgres 12).
One issue is that you need to make this development version available. One option would be to force a "development branch" version into the versions hash after it does the lookup to the default source repo. This feels a bit ugly though especially in cases where people may have pointed to a custom source directory where they don't expect this other version to appear.
Another issue is how to build it. We could build out machinery to pull from git, which might make the most sense, since that way people could rebuild the dev version anytime they saw a new commit they were interested in. The downside, of course, is you need to add a bunch of routines to compile everything. It might be possible to download a zip file directly from GitHub, but that would still take some working out. If we want to leverage the existing build code, the easiest way would be to force dev to come from https://ftp.postgresql.org/pub/snapshot/dev/, although I think that is only built nightly, not per commit.
Or maybe this is all a bad idea? Thoughts?
The text was updated successfully, but these errors were encountered: