|  |  | The `translate` Command

## The `translate` Command

The `translate` command reads information from a file in a given format and writes it to another file in another given format:

    translate IN-FORMAT [IN-PARAMS] [IN-TYPES] IN-PATH \
              OUT-FORMAT [OUT-PARAMS] [OUT-TYPES] OUT-PATH

where:

- `IN-FORMAT [IN-PARAMS]` and `OUT-FORMAT [OUT-PARAMS]` are the input file format and the output file format and their parameters (if any); use `show formats` for a list of the currently accepted formats;
- `IN-TYPES` are the data types to read; the possible types depend on the input format and some formats impose that there is a single data type per file; they may be absent if the format requires a unique data type or if the files can have items of different types; `all` can be used as an abbreviation of `WP RT TR LN`;
- `IN-PATH` is the path to the file to read from, or, in the case of the `Shapefile` format, the path to the Shapefiles basename (file extensions will be discarded). If the `IN-PATH` is `stdin` input will be from the standard input unless the format is the `Shapefile` format (in which case the command fails);
- `OUT-TYPES` may be absent in which case they are taken to be `IN-TYPES`; if `RT` occurs in `IN-TYPES` then `WP` can appear in `OUT-TYPES` but no other type "conversions" are allowed; some file formats impose that there is a single data type per file; `all` can be used as an abbreviation of `WP RT TR LN`;
- `OUT-PATH` is the path to the output file, or, in the case of the `Shapefile` format, the path to the Shapefiles basename (file extensions will be discarded). If the `OUT-PATH` is `stdout` output will be to the standard output unless the format is the `Shapefile` format (in which case the command fails). Existing files will be silently overwritten.

|  |  | The `translate` Command