poe

poe is a .po (GNU gettext) file editor with a terminal UI.

Manual

See https://strahinja.srht.site/man/poe/poe.1.html.

Q&A

Q: Why?

A:

  • There should be no need for GNOME to edit .po files.

  • Some folks prefer terminal to GUI.

  • No, plugin for vi(m) isn't enough.

Q: Why C?

A: Because <Go/Rust/whatever soydev language of the moment> sucks.

Q: Why is poe saying there are <N+1> messages in my file when other editors say there are <N> messages?

A: Because poe takes into account (and allows editing of) the first, special msgid.

Q: This doesn't do X!

A: I might consider adding a feature if I have time, but already poe has all the major ones I planned. It is meant to be a simple .po editing program.

Q: Is this suckless?

A: Definitely not. Any TUI is not suckless. gettext is not suckless, and thus .po files are also not suckless. Despite that, some suggestions for a suckless approach to editing .po files are: vi, ed. Still, termbox, used by poe, is less bloated than ncurses.

Prerequisites

Install

$ git clone https://git.sr.ht/~strahinja/poe
$ cd poe
$ su
# make install

With got:

$ got clone https://git.sr.ht/~strahinja/poe
$ got checkout poe.git
$ cd poe
$ su
# make install

Persistent build configuration file

The file config.mk will be sourced when building targets which also accept configuration through environment variables. For example, CPPFLAGS and PREFIX are specified in config.mk.

OpenBSD

Before running make(1), comment the CPPFLAGS definition in config.mk above the line with the “OpenBSD” comment and uncomment the one below it:

#CPPFLAGS	= -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200809L 
#		  -D_XOPEN_SOURCE=700
# OpenBSD
CPPFLAGS	= -D_DEFAULT_SOURCE -D_POSIX_C_SOURCE=200809L 
		  -D_XOPEN_SOURCE=700 -D_BSD_SOURCE

Also, do the same for MANPREFIX:

#MANPREFIX	= $(DESTDIR)$(PREFIX)/share/man
# OpenBSD
MANPREFIX	= $(DESTDIR)$(PREFIX)/man

Install (Arch)

$ git clone https://aur.archlinux.org/poe.git
$ cd poe
$ makepkg -si

Bugs and limitations

Bugs can be reported using the ticket tracker. See the manpage (man poe) after installing poe for more information.

License

poe - .po file editor
Copyright (C) 2021-2024 Страхиња Радић

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see https://www.gnu.org/licenses/.

File termbox.h is based on termbox2 TUI library, (c) 2021 termbox developers, which is released under the terms of Expat license, see the file LICENSE.termbox.

Generated by slweb © 2020-2024 Strahinya Radich.