You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To include the comments of the `.xml`/`.strings` input file in the output file, add the `-p` (also `--print-comments`) flag. Note that it will be ignored for other input file types.
To convert multiple files at once and save them to the specified directory passed in the `-d` flag, use the`-t` flag followed by the desired file type extension (e.g., `.json`). Note that the program will create the directory if it doesn't exist.
For multiple file inputs and directories, the name of the files will be the same as the input file. For example, if there is a file named `spanish.xml` in a directory, the output file name will be `spanish.[TARGET_TYPE]`
323
+
304
324
See the [Generating a Spreadsheet in Google Sheets](#generating-a-spreadsheet-in-google-sheets) section to create a spreadsheet in your Google account.
|`-h` or `--help`| Displays help text for the program |
311
-
|`-o` or `--output-filepath`| Specifies the filepath for storing the converted file. The file extension can be chosen from the list of supported file types mentioned [here](#about-the-project). |
312
-
|`-g` or `--google-sheets`| Followed by the name of the sheet, creates a new Google Sheets spreadsheet with the specified name. |
313
-
|`-c` or `--credentials`| Followed by the path to your `service_account.json` file is mandatory if you want to generate a spreadsheet in your Google account. |
314
-
|`-p` or `--print-comments`| The output file will contain all commented strings that were present in the original file (only applicable if the input file is a `.xml` or `.strings` file). Otherwise it will be ignored. |
|`-h` or `--help`| Displays help text for the program. |
331
+
|`-f` or `--output-filepath`| Path to save the converted file. Only works if only one input file is provided. The file extension can be chosen from [the list of supported file types](#file-types-supported). |
332
+
|`-d` or `--output-dir`| Directory where the converted files will be saved. Compatible with single and multiple input files as well as directories. The specified directory will be created if it does not already exist. |
333
+
|`-t` or `--target-type`| Target file type to convert the files (e.g., .pdf, .json). Required if multiple file paths or the `--output-dir` is specified. |
334
+
|`-g` or `--google-sheets`| If provided, a Google spreadsheet will be created in your Google account. You must pass the `service_account.json` with the `-c` flag. |
335
+
|`-c` or `--credentials`|`service_account.json` filepath. Mandatory if you want to generate a spreadsheet in your Google account. You can learn how to generate it in the [Generating a Spreadsheet in Google Sheets](#generating-a-spreadsheet-in-google-sheets) section. |
336
+
|`-p` or `--print-comments`| If provided, the commented strings will be printed in the output file. Only valid for input files of type `.xml` or `.strings`. Otherwise it is ignored. |
315
337
316
338
<palign="right">(<ahref="#top">back to top</a>)</p>
317
339
@@ -348,15 +370,17 @@ Alternatively, you can create an `.xlsx` file and open it in Google Sheets if yo
348
370
349
371
Once you have the `service_account.json` file, you can create a spreadsheet in Google Sheets by running the following command:
0 commit comments