Low commit activity in last 3 years
No release in over a year
Creates .strings files for iOS and strings.xml files for Android
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 3.0.6
 Project Readme

google_sheet_localize plugin

fastlane Plugin Badge

Getting Started

This project is a fastlane plugin. To get started with fastlane-plugin-google_sheet_localize, add it to your project by running:

fastlane add_plugin google_sheet_localize

About google_sheet_localize

Creates .strings files for iOS and strings.xml files for Android

to use our plugin you have to duplicate this google sheet: Example

Google Drive access token: Guide

  • The language_titles (the columns which should be exported)
  • The default_language (If a string is not present in a specific language, this is the fallback)
  • The base_language (The language which is placed in the base values folder)

Sheet Language

Arguments: (Android + iOS + Web)

English: Mario ate a %2s %1s.
German: Mario hat %1s einen %2s gegessen.

In this case %2s stands for Apple and %1s for Today, the order is different in this example, so we need to take care of it.

Mapped iOS: Mario ate a %2$@ %1$@.
Mapped Android: Mario ate a %2s %1s.
Mapped Web: Mario ate a {2} {1}.

Plurals: (Android + iOS)

one|%d artist
other|%d artists

String Array: (Android)

["Monday", "Tuesday", "Wednesday"]

iOS specifics

In order to support Objective-C, the plugin provides the support_objc argument, which is default false.
Therefore, if you need Objective-C support pass support_objc: true.

Example

  lane :localize do
    google_sheet_localize(service_account_path: "./fastlane/google_drive_credentials.json",
                                      sheet_id: "sheet id",
                                      platform: "ios",
                                          tabs: ["3TV"], #array of tab titles in google sheet
                             localization_path: "./Kit/TVKit",
                               language_titles: ["de", "en"], #language titles in google sheet
                              default_language: "de", #default language for google sheet
                                 base_language: "en") #ios: Base.lproj android: values 
  end

Run tests for this plugin

To run both the tests, and code style validation, run

rake

To automatically fix many of the styling issues, use

rubocop -a

Issues and Feedback

For any other issues and feedback about this plugin, please submit it to this repository.

Troubleshooting

If you have trouble using plugins, check out the Plugins Troubleshooting guide.

Using fastlane Plugins

For more information about how the fastlane plugin system works, check out the Plugins documentation.

About fastlane

fastlane is the easiest way to automate beta deployments and releases for your iOS and Android apps. To learn more, check out fastlane.tools.