OSMIUM-CHANGESET-FILTER(1)

✨ OSMIUM-CHANGESET-FILTER ✨

okay bestie, gather round, because this is the osmium-changeset-filter manual page and it's literally here to filter changesets out of an OSM changeset file πŸ’– she's from the osmium family of tools, and she's about to become your new obsession.


🌸 SYNOPSIS 🌸

osmium changeset-filter [OPTIONS] OSM-CHANGESET-FILE

πŸ’… DESCRIPTION πŸ’…

So what she does is: she copies the changesets that match all of the criteria you gave her, and those matches go straight to the output. And how do you give her criteria? Through command line options, obviously. πŸ‘‘

The way this command works is she reads her input file exactly once and writes her output file in one go, which means she can be streamed β€” iykyk β€” meaning she can read from STDIN and write to STDOUT. no cap. ✨


πŸŽ€ FILTER OPTIONS πŸŽ€

  • -a, --after=TIMESTAMP β€” only copy changesets that were closed after the given time. heads up bestie: this will always include all the open changesets too, no exceptions.
  • -b, --before=TIMESTAMP β€” only copy changesets that were created before the given time.
  • -B, --bbox=LONG1,LAT1,LONG2,LAT2 β€” only copy changesets whose bounding box overlaps the box you specify. LONG1,LAT1 is one arbitrary corner, and LONG2,LAT2 is the opposite corner. opposite corners, slay.
  • -c, --with-changes β€” only copy changesets that have changes.
  • -C, --without-changes β€” only copy changesets that have no changes.
  • -d, --with-discussion β€” only copy changesets with discussions, meaning changesets with at least one comment.
  • -D, --without-discussion β€” only copy changesets without discussions, meaning changesets with zero comments.
  • --open β€” only copy open changesets.
  • --closed β€” only copy closed changesets.
  • -u, --user=USER β€” only copy changesets made by the given user name.
  • -U, --uid=UID β€” only copy changesets made by the given user ID.

🌈 COMMON OPTIONS 🌈

  • -h, --help β€” show usage help. your safety net fr fr.
  • -v, --verbose β€” set verbose mode. she'll tell you what she's doing by outputting info to STDERR.
  • --progress β€” show a progress bar. usually a progress bar only shows up if STDOUT and STDERR are detected to be a TTY, but with this option it's always shown. > one thing though: a progress bar will never be shown when reading from STDIN or a pipe.
  • --no-progress β€” do not show a progress bar. usually a progress bar is displayed if STDOUT and STDERR are detected to be a TTY, but with this option it's suppressed. > same deal: a progress bar will never be shown when reading from STDIN or a pipe.

πŸ¦‹ INPUT OPTIONS πŸ¦‹

  • -F, --input-format=FORMAT β€” the format of the input file(s). use this to set the input format when it can't be autodetected from the file name(s). important: this sets the format for all input files, there's literally no way to set the format for just some input files only. see osmium-file-formats(5) or the libosmium manual for the deets.

⭐ OUTPUT OPTIONS ⭐

  • -f, --output-format=FORMAT β€” the format of the output file. use this to set the output file format when it can't be autodetected from the output file name. see osmium-file-formats(5) or the libosmium manual for the deets.
  • --fsync β€” call fsync after writing the output file to force flushing buffers to disk. very responsible of her πŸ’…
  • --generator=NAME β€” the name and version of the program generating the output file. it gets added to the header of the output file. default is "osmium/" plus the version of osmium.
  • -o, --output=FILE β€” name of the output file. default is - (that's STDOUT).
  • -O, --overwrite β€” allow an existing output file to be overwritten. normally osmium will straight up refuse to write over an existing file, so this is your permission slip.
  • --output-header=OPTION=VALUE β€” add an output header option. you can use this command line option multiple times for different OPTIONs. check the osmium-output-headers(5) man page for the list of available header options. and for some commands you can use the special format "OPTION!" (that's an exclamation mark after the OPTION, with no value set) to set the value to the same as in the input file. cute.

πŸ‘‘ DIAGNOSTICS πŸ‘‘

osmium changeset-filter exits with exit code:

  • 0 β€” if everything went alright ✨
  • 1 β€” if there was an error processing the data, or
  • 2 β€” if there was a problem with the command line arguments.

🧚 MEMORY USAGE 🧚

osmium changeset-filter does all its work on the fly and doesn't keep much data in main memory. lowkey the most efficient queen. πŸ’œ


πŸ“ EXAMPLES πŸ“

wanna see all changesets by user "foo"? say less:

osmium changeset-filter -u foo -f debug changesets.osm.bz2

and to create an OPL file containing only open changesets:

osmium changeset-filter --open -o open-changesets.opl.bz2 changesets.osm.bz2

πŸ’– SEE ALSO πŸ’–


Copyright (C) 2013-2026 Jochen Topf <jochen@topf.org>.

License GPLv3+: GNU GPL version 3 or later <https://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law.


🫢 CONTACT 🫢

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


✨ AUTHORS ✨

Jochen Topf <jochen@topf.org>.


and that's the whole page bestie, version 1.19.1 of the OSMIUM-CHANGESET-FILTER(1) manual, go forth and filter your changesets, you absolute icon πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from