You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ nix-shell
$ pg-build && with-pg psql
\create_function from ./src/pl/plpython/data/max.pypublic.max(a int, b int) returns int language plpython3u
selectmax(3, 4);
Alternatives
A special syntax highlighter for postgres functions with different langs in VIM? This would have to be done for various editors/IDEs though.
Another executable besides psql that deploys the functions based on mustache files.
The text was updated successfully, but these errors were encountered:
Really nice that this already sparked some discussion! Looks like the final interface will be like this though:
\file_read fbody source_file.txtCREATEFUNCTIONfoo() RETURNS whatever AS :'fbody' LANGUAGE ...;
@wolfgangwalther You mentioned you follow the mailing list daily. I was wondering, what's the protocol on implementing a feature? Should I just jump in with a new patch? Not sure if I should leave that to Tom Lane since he proposed it.
You mentioned you follow the mailing list daily. I was wondering, what's the protocol on implementing a feature? Should I just jump in with a new patch? Not sure if I should leave that to Tom Lane since he proposed it.
I don't expect him to work on this. If so, he would likely have said that.
I guess you could just write a patch for the above, yes.
Problem
As it can be seen on https://github.com/PostgREST/plmustache?tab=readme-ov-file#sections, regular syntax highlighting for mustache files doesn't work.
Solution
Add a
psql
command that can obtain the function body from another file.I've submitted this on https://www.postgresql.org/message-id/CAGRrpzZnoWY-kK_0qK-OY%3D-e0eDqhc5kdFSkuxN0mxe9iuiz0Q%40mail.gmail.com
It can also be tried on this branch https://github.com/steve-chavez/postgresql/tree/cf with:
Alternatives
psql
that deploys the functions based on mustache files.The text was updated successfully, but these errors were encountered: