Skip to content

Commit

Permalink
Add locale to snap package
Browse files Browse the repository at this point in the history
  • Loading branch information
LyzardKing committed Jan 7, 2024
1 parent a89134a commit 2b1d62a
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions snap/snapcraft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,21 @@ parts:
- PARTS_PYTHON_VENV_ARGS: "--system-site-packages"
organize:
lib/python3/dist-packages/umake/version: lib/python3.10/site-packages/umake/version
locale:
plugin: nil
source: .
build-packages:
- gettext
override-build: |
craftctl default
for lang in $(ls po/*.po | cut -d/ -f2 | cut -d. -f1); do \
mkdir -p $SNAPCRAFT_PART_INSTALL/usr/share/locale/$lang/LC_MESSAGES; \
msgfmt -o $SNAPCRAFT_PART_INSTALL/usr/share/locale/$lang/LC_MESSAGES/ubuntu-make.mo po/$lang.po; \
done
stage:
- usr/share/locale/*
prime:
- usr/share/locale/*
python3:
plugin: nil
source: .
Expand Down

0 comments on commit 2b1d62a

Please sign in to comment.