Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add translation for iOS Notes #690

Merged
merged 1 commit into from
Dec 6, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions translations/Dockerfile-iOSNotes
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
FROM ghcr.io/nextcloud/continuous-integration-translations:latest

MAINTAINER Tobias Kaminsky <[email protected]>

ADD handleiOSNotesTranslations.sh /handleTranslations.sh
6 changes: 6 additions & 0 deletions translations/config.json
Original file line number Diff line number Diff line change
Expand Up @@ -215,6 +215,12 @@
""
]
},
{
"name": "iosnotes",
"arguments": [
""
]
},
{
"name": "desktop",
"arguments": [
Expand Down
53 changes: 53 additions & 0 deletions translations/handleiOSNotesTranslations.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
#!/bin/sh

# verbose and exit on error
set -xe

# import GPG keys
gpg --import /gpg/nextcloud-bot.public.asc
gpg --allow-secret-key-import --import /gpg/nextcloud-bot.asc
gpg --list-keys

# fetch git repo
git clone [email protected]:nextcloud/notes-ios /app
git checkout -b develop origin/develop

# remove all translations (they are added afterwards anyways but allows to remove languages via transifex)
rm -r Source/*.lproj/Localizable.strings
rm -r Source/*.lproj/Main_iPhone.strings
rm -r Source/*.lproj/Categories.strings
rm -r Source/Settings.bundle/*.lproj/Root.strings
rm -r Source/Screens/Settings/*.lproj/Settings.strings

git checkout -- Source/en.lproj/Localizable.strings
git checkout -- Source/en.lproj/Main_iPhone.strings
git checkout -- Source/en.lproj/Categories.strings
git checkout -- Source/Settings.bundle/en.lproj/Root.strings
git checkout -- Source/Screens/Settings/en.lproj/Settings.strings


# push sources
tx push -s

# pull translations
tx pull -f -a --minimum-perc=25


# use de_DE instead of de
rm -rf Source/de.lproj/Localizable.strings
rm -rf Source/de.lproj/Main_iPhone.strings
rm -rf Source/de.lproj/Categories.strings
rm -rf Source/Settings.bundle/de.lproj/Root.strings
rm -rf Source/Screens/Settings/de.lproj/Settings.strings

mv Source/de_DE.lproj/Localizable.strings Source/de.lproj/Localizable.strings
mv Source/de_DE.lproj/Main_iPhone.strings Source/de.lproj/Main_iPhone.strings
mv Source/de_DE.lproj/Categories.strings Source/de.lproj/Categories.strings
mv Source/Settings.bundle/de_DE.lproj/Root.strings Source/Settings.bundle/de.lproj/Root.strings
mv Source/Screens/Settings/de_DE.lproj/Settings.strings Source/Screens/Settings/de.lproj/Settings.strings

# create git commit and push it
git add .
git commit -am "[tx-robot] updated from transifex" || true
git push origin develop
echo "done"