Re: Add pgindent test to check if codebase is correctly formatted

Поиск
Список
Период
Сортировка
От Tristan Partin
Тема Re: Add pgindent test to check if codebase is correctly formatted
Дата
Msg-id CYGLEFXQWRH4.Y3NP0SLR2UI3@neon.tech
обсуждение исходный текст
Ответ на Re: Add pgindent test to check if codebase is correctly formatted  (Bruce Momjian <bruce@momjian.us>)
Ответы Re: Add pgindent test to check if codebase is correctly formatted  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
On Tue Jan 16, 2024 at 7:27 PM CST, Bruce Momjian wrote:
> On Tue, Jan 16, 2024 at 07:22:23PM -0600, Tristan Partin wrote:
> > I think a good solution would be to distribute pgindent and pg_bsd_indent.
> > At Neon, we are trying to format our extension code using pgindent. I am
> > sure there are other extension authors out there too that format using
> > pgindent. Distributing pg_bsd_indent and pgindent in the postgresql-devel
> > package would be a great help to those of us that pgindent out of tree code.
> > It would also have the added benefit of adding the tools to $PREFIX/bin,
> > which would make the test that I added not need a hack to get the
> > pg_bsd_indent executable.
>
> So your point is that pg_bsd_indent and pgindent are in the source tree,
> but not in any package distribution?  Isn't that a packager decision?

It requires changes to at least the Meson build files. pg_bsd_indent is
not marked for installation currently. There is a TODO there. pgindent
has no install_data() for instance. pg_bsd_indent seemingly gets
installed somewhere in autotools given the contents of its Makefile, but
I didn't see anything in my install tree afterward.

Sure RPM/DEB packagers can solve this issue downstream, but that doesn't
help those of that run "meson install" or "make install" upstream.
Packagers are probably more likely to package the tools if they are
marked for installation by upstream too.

Hope this helps to better explain what changes would be required within
the Postgres source tree.

--
Tristan Partin
Neon (https://neon.tech)



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: Add pgindent test to check if codebase is correctly formatted
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Add pgindent test to check if codebase is correctly formatted