Git Product home page Git Product logo

gsheet_to_arb's Introduction

GSheet to ARB

pub package

Imports Application Resource Bundle (ARB) from Google Sheets

https://github.com/googlei18n/app-resource-bundle/wiki/ApplicationResourceBundleSpecification

Usage

Import ARB files from the Google Sheet

  1. Setup plugin configuration

  2. To import ARB files from Google Sheet run the gsheet_to_arb:import program.

    pub run gsheet_to_arb:import --config gsheet_to_arb.yaml
    
  3. Optionally generate Dart classes from the ARB files using gsheet_to_arb:arb_to_dart program.

    pub run gsheet_to_arb:arb_to_dart --config gsheet_to_arb.yaml
    

Setup

1. Copy Google Sheet template

  1. Open sample Google spreadsheet template available at:

  2. Copy sample to your Drive account

    • File -> Make a copy
  3. Save DOCUMENT_ID of the Google spreadsheet

2. Authenticate

Create Google Sheets API credentials either by using Client or Server authentication.

3. Configure your Dart project

  1. Add gsheet_to_arb dev dependency to the pubspec.yaml

    dev_dependencies:
      gsheet_to_arb: ^0.0.8
  2. Updated dependencies pub update

  3. Create plugin configuration

    pub run gsheet_to_arb:import --create-config gsheet_to_arb.yaml
  4. Update plugin configuration gsheet_to_arb.yaml e.g.

    gsheet_to_arb:
      arb_file_prefix: 'intl'
      output_directory: 'lib/src/i18n'
      gsheet:
        document_id: '<DOCUMENT_ID>'
        sheet_id: '0'
        auth:
          service_account_key_path: "~/.ssh/gsheet-to-arb-server-config.json"

TODO

  • Support ARB plurals

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.