{"id":28181629,"url":"https://github.com/victorcazanave/google-sheets-i18n-generator","last_synced_at":"2025-07-25T02:03:19.238Z","repository":{"id":43196088,"uuid":"234498005","full_name":"VictorCazanave/google-sheets-i18n-generator","owner":"VictorCazanave","description":"Generate i18n JSON/JS files from a Google Sheets spreadsheet","archived":false,"fork":false,"pushed_at":"2023-03-03T11:52:47.000Z","size":925,"stargazers_count":12,"open_issues_count":6,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-13T14:49:10.847Z","etag":null,"topics":["commonjs","es-modules","google-sheets","i18n","json","nodejs","spreadsheet"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VictorCazanave.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-01-17T07:47:05.000Z","updated_at":"2025-03-23T18:27:45.000Z","dependencies_parsed_at":"2024-08-30T05:01:36.531Z","dependency_job_id":null,"html_url":"https://github.com/VictorCazanave/google-sheets-i18n-generator","commit_stats":{"total_commits":60,"total_committers":3,"mean_commits":20.0,"dds":0.2833333333333333,"last_synced_commit":"c93f7a4499be616e8f3b811ad5f2c181f5f114b8"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VictorCazanave%2Fgoogle-sheets-i18n-generator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VictorCazanave%2Fgoogle-sheets-i18n-generator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VictorCazanave%2Fgoogle-sheets-i18n-generator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VictorCazanave%2Fgoogle-sheets-i18n-generator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VictorCazanave","download_url":"https://codeload.github.com/VictorCazanave/google-sheets-i18n-generator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254459050,"owners_count":22074606,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["commonjs","es-modules","google-sheets","i18n","json","nodejs","spreadsheet"],"created_at":"2025-05-16T03:13:25.996Z","updated_at":"2025-05-16T03:13:27.640Z","avatar_url":"https://github.com/VictorCazanave.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# google-sheets-i18n-generator\n\n[![npm version](https://img.shields.io/npm/v/google-sheets-i18n-generator)](https://www.npmjs.com/package/google-sheets-i18n-generator)\n[![Build Status](https://travis-ci.com/VictorCazanave/google-sheets-i18n-generator.svg?branch=master)](https://travis-ci.com/VictorCazanave/google-sheets-i18n-generator)\n[![codecov](https://codecov.io/gh/VictorCazanave/google-sheets-i18n-generator/branch/master/graph/badge.svg)](https://codecov.io/gh/VictorCazanave/google-sheets-i18n-generator)\n[![Dependency Status](https://david-dm.org/VictorCazanave/google-sheets-i18n-generator.svg)](https://david-dm.org/VictorCazanave/google-sheets-i18n-generator)\n[![GitHub](https://img.shields.io/github/license/VictorCazanave/google-sheets-i18n-generator?color=blue)](https://github.com/VictorCazanave/google-sheets-i18n-generator/blob/master/LICENSE)\n\nGenerate i18n JSON/JS files from a Google Sheets spreadsheet\n\n## Installation\n\n### npm\n\n`npm install --save-dev google-sheets-i18n-generator`\n\n### yarn\n\n`yarn add --dev google-sheets-i18n-generator`\n\n## Usage\n\n1. Create a Google Sheets spreadsheet to store the i18n strings\n   \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/spreadsheet.png\" alt=\"Example of spreadsheet\" height=\"150\"\u003e\n\n2. If needed, configure Google Sheets (only the first time):\n   \u003cdetails\u003e\n     \u003csummary\u003eMore details\u003c/summary\u003e\n\n     2.1. Enable the Google Sheets API for your project following [this documentation](https://support.google.com/googleapi/answer/6158841)\n\n     \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/google-sheets-api.png\" alt=\"Menu to Google Sheets API\" height=\"150\"\u003e\n\n     \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/enable-google-sheets-api.png\" alt=\"Button to enable Google Sheets API\" height=\"150\"\u003e\n\n     2.2. Create OAuth ID credentials for your application\n\n     \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/create-credentials.png\" alt=\"Menu to create credentials\" height=\"200\"\u003e\n\n     2.3. Download the `client_secret_xxx.json` file of your application, then eventually move it to the right folder and rename it\n\n     \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/download-client-secret.png\" alt=\"Button to download client secret file\" height=\"100\"\u003e\n\u003c/details\u003e\n\n3. Copy the ID of the spreadsheet (can be found in the URL `https://docs.google.com/spreadsheets/d/\u003cspreadsheetId\u003e/edit#gid=0`)\n\n4. Run the command: `gs-i18n \u003cspreadsheetId\u003e`\n\n5. If needed, follow the instructions to allow `gs-i18n` to access your Google Sheets and download the `credentials.json` files (only the first time)\n   \u003cdetails\u003e\n     \u003csummary\u003eMore details\u003c/summary\u003e\n\n     ```\n     Authorize this app by visiting this url: https://accounts.google.com/o/oauth2/v2/auth?access_type=offline\u0026scope=https%3A%2F%2Fwww.googleapis.com%2Fauth%2Fspreadsheets.readonly\u0026response_type=code\u0026client_id=...\u0026redirect_uri=...\n     Enter the code from that page here:\n     ```\n\n     \u003cimg src=\"https://raw.githubusercontent.com/VictorCazanave/google-sheets-i18n-generator/master/doc/allow-gs-i18n-access.png\" alt=\"Button to allow gs-i18n to access Google Sheets API\" height=\"400\"\u003e\n   \u003c/details\u003e\n\n6. The JSON files are generated in the `./locales` folder\n\nTo customize the options, see the [API section](#api).\n\n## API\n\n```\nUsage: gs-i18n \u003cspreadsheetId\u003e [options]\n\nOptions:\n  -v, --version            output the version number\n  -b, --beautify \u003cnumber\u003e  number of spaces to insert white space in JSON/JS files (min: 0, max: 10) (default: 0)\n  -c, --client \u003cpath\u003e      path of client secret file (default: \"./client_secret.json\")\n  -f, --format \u003cformat\u003e    format of generated files (available values: \"cjs\", \"esm\", \"json\") (default: \"json\")\n  -k, --key \u003cindex\u003e        index of key column (default: 0)\n  -l, --lang \u003cindex\u003e       index of first language column (default: 1)\n  -o, --output \u003cpath\u003e      path of output directory (default: \"./locales\")\n  -r, --range \u003crange\u003e      range of data to parse (default: \"Sheet1\")\n  -t, --token \u003cpath\u003e       path of credentials file (default: \"./credentials.json\")\n  -h, --help               output usage information\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvictorcazanave%2Fgoogle-sheets-i18n-generator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvictorcazanave%2Fgoogle-sheets-i18n-generator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvictorcazanave%2Fgoogle-sheets-i18n-generator/lists"}