po-language-server
This is a Markov-chain based completion language
server for
gettext po files.
Installation
python3 -m pip install po-language-server
It should be compatible with vim, emacs, vscode, and other text editors acting as language server clients. I only tried it using emacs though.
Emacs configuration
I did not packaged it yet (feel free to help), but it's not that hard to configure:
(require 'lsp-mode)
(add-to-list 'lsp-language-id-configuration '(po-mode . "gettext"))
(lsp-register-client
(make-lsp-client
:new-connection (lsp-stdio-connection "po-language-server")
:activation-fn (lsp-activate-on "gettext" "plaintext")
:priority -1
:server-id 'po
))
(add-hook 'po-mode-hook #'lsp)
;; lsp-mode can only work on named buffers
(defun po-mode-name-buffer ()
(setq-local buffer-file-name "msgstr.po")
(lsp))
(defun po-mode-unname-buffer ()
(setq-local buffer-file-name nil))
(add-hook 'po-mode-hook
(lambda ()
(advice-add 'po-edit-msgstr :after 'po-mode-name-buffer)
(advice-add 'po-subedit-exit :before 'po-mode-unname-buffer)))
(add-to-list 'lsp-enabled-clients 'po)
Metadata
Release files for po-language-server 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| po-language-server-0.0.2.tar.gz | 3.2 kB | Without provenance | Details for po-language-server-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| po_language_server-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for po_language_server-0.0.2-py3-none-any.whl |
Total release size: 6.5 kB
Release files / po-language-server-0.0.2.tar.gz
| Download URL | po-language-server-0.0.2.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2c5a8b33b3c79032b97dfc2805067d18a95a2b1ab96ca8c8bf9ba7409da4d73b
|
|
BLAKE2b-256 checksum How to use checksums |
c5abe0b59f0e4267c0f9d1b3749881859befefb827ecf05e323e2cd4a304db21
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
|
Release files / po_language_server-0.0.2-py3-none-any.whl
| Download URL | po_language_server-0.0.2-py3-none-any.whl |
|---|---|
| Size | 3.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
d32187b296ccf6581c01453ce8c402421aed2f03c5d38220e1bd01b77b742feb
|
|
BLAKE2b-256 checksum How to use checksums |
d9dfe5dbb64a0a4b5ffbaf9af4bf674e2b2bfaac95c8c8bc2071b608e539f874
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.4
|
Security for po-language-server 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.