1OSMIUM-CAT(1)                                                    OSMIUM-CAT(1)
2
3
4

NAME

6       osmium-cat - concatenate OSM files and convert to different formats
7

SYNOPSIS

9       osmium cat [OPTIONS] OSM-FILE...
10

DESCRIPTION

12       Concatenates  all input files and writes the result to the output file.
13       The data is not sorted in any way but strictly  copied  from  input  to
14       output.
15
16       Because  this  program supports several different input and output for‐
17       mats, it can be used to convert OSM files from one format into another.
18
19       This commands reads its input file(s) only once and writes  its  output
20       file  in  one go so it can be streamed, ie.  it can read from STDIN and
21       write to STDOUT.
22

OPTIONS

24       -c, --clean=ATTR
25              Clean the attribute (version, timestamp, changeset, uid,  user),
26              from  the  data before writing it out again.  The attribute will
27              be set to 0 (the user will be set to the  empty  string).   This
28              option  can  be  given  multiple times.  Depending on the output
29              format these attributes might show up as 0 or  not  show  up  at
30              all.
31
32       -t, --object-type=TYPE
33              Read  only  objects  of given type (node, way, relation, change‐
34              set).  By default all types are read.  This option can be  given
35              multiple times.
36

COMMON OPTIONS

38       -h, --help
39              Show usage help.
40
41       -v, --verbose
42              Set  verbose  mode.   The  program will output information about
43              what it is doing to STDERR.
44
45       --progress
46              Show progress bar.  Usually a progress bar is only displayed  if
47              STDOUT  and  STDERR  are detected to be TTY.  With this option a
48              progress bar is always shown.  Note that  a  progress  bar  will
49              never be shown when reading from STDIN or a pipe.
50
51       --no-progress
52              Do  not  show progress bar.  Usually a progress bar is displayed
53              if STDOUT and STDERR are detected to be a TTY.  With this option
54              the  progress  bar is suppressed.  Note that a progress bar will
55              never be shown when reading from STDIN or a pipe.
56

INPUT OPTIONS

58       -F, --input-format=FORMAT
59              The format of the input file(s).  Can be used to set  the  input
60              format  if it can’t be autodetected from the file name(s).  This
61              will set the format for all input files, there is no way to  set
62              the  format  for  some  input  files only.  See osmium-file-for‐
63              mats(5) or the libosmium manual for details.
64

OUTPUT OPTIONS

66       -f, --output-format=FORMAT
67              The format of the output file.  Can be used to  set  the  output
68              file  format  if  it  can’t be autodetected from the output file
69              name.  See osmium-file-formats(5) or the  libosmium  manual  for
70              details.
71
72       --fsync
73              Call  fsync after writing the output file to force flushing buf‐
74              fers to disk.
75
76       --generator=NAME
77              The name and version of the program generating the output  file.
78              It  will  be added to the header of the output file.  Default is
79osmium/” and the version of osmium.
80
81       -o, --output=FILE
82              Name of the output file.  Default is `-' (STDOUT).
83
84       -O, --overwrite
85              Allow an existing  output  file  to  be  overwritten.   Normally
86              osmium will refuse to write over an existing file.
87
88       --output-header=OPTION=VALUE
89              Add  output header option.  This command line option can be used
90              multiple times for different OPTIONs.  See the libosmium  manual
91              for  a  list of available header options.  For some commands you
92              can use the special format “OPTION!” (ie.  an  exclamation  mark
93              after  the OPTION and no value set) to set the value to the same
94              as in the input file.
95

DIAGNOSTICS

97       osmium cat exits with exit code
98
99       0      if everything went alright,
100
101       1      if there was an error processing the data, or
102
103       2      if there was a problem with the command line arguments.
104

MEMORY USAGE

106       osmium cat does all its work on the fly and doesn’t keep much  data  in
107       main memory.
108

EXAMPLES

110       Convert a PBF file to a compressed XML file:
111
112              osmium cat -o out.osm.bz2 in.osm.pbf
113
114       Concatenate all change files in the `changes' directory into one:
115
116              osmium cat -o all-changes.osc.gz changes/*.osc.gz
117
118       Copy nodes and ways from source to destination file:
119
120              osmium cat -o dest.osm.pbf source.osm.pbf -t node -t way
121
122       Remove changeset, uid, and user from a file to protect personal data:
123
124              osmium cat -c changeset -c uid -c user -o cleaned.osm.pbf data.osm.pbf
125

SEE ALSO

127       · osmium(1), osmium-file-formats(5)
128
129       · Osmium website (https://osmcode.org/osmium-tool/)
130
132       Copyright (C) 2013-2020 Jochen Topf <jochen@topf.org>.
133
134       License      GPLv3+:     GNU     GPL     version     3     or     later
135       <https://gnu.org/licenses/gpl.html>.  This is free  software:  you  are
136       free  to  change  and  redistribute  it.   There is NO WARRANTY, to the
137       extent permitted by law.
138

CONTACT

140       If you have any questions or  want  to  report  a  bug,  please  go  to
141       https://osmcode.org/contact.html
142

AUTHORS

144       Jochen Topf <jochen@topf.org>.
145
146
147
148                                    1.12.1                       OSMIUM-CAT(1)
Impressum