Skip to content
language19 active rulesVerified 2026-09-30

O Caml .gitignore Template

Standard O Caml gitignore template from upstream github/gitignore collection. Generated and merged deterministically with upstream GitHub repository patterns to keep your repository clean of package directories, temporary build artifacts, and local environment files.

Interactive Stack Generator

Preconfigured with O Caml
Search for templates
Quick add:
Selected1
O Caml
Selected Templates (1)
.gitignore
19 rules
### O Caml ###
*.annot
*.cmo
*.cma
*.cmi
*.a
*.o
*.cmx
*.cmxs
*.cmxa
# Files containing detailed information about the compilation (generated
# by `ocamlc`/`ocamlopt` when invoked using the option `-bin-annot`).
# These files are typically useful for code inspection tools
# (e.g. Merlin).
*.cmt
*.cmti
# ocamlbuild and Dune default working directory
_build/
# ocamlbuild targets
*.byte
*.native
# oasis generated files
setup.data
setup.log
# Merlin configuring file for Vim and Emacs
.merlin
# Dune generated files
*.install
# Local OPAM switch
_opam/
38 lines•UTF-8
Deterministic

Raw O Caml .gitignore

Crawlable upstream source template
ocaml.gitignore•37 lines•UTF-8
*.annot
*.cmo
*.cma
*.cmi
*.a
*.o
*.cmx
*.cmxs
*.cmxa
# Files containing detailed information about the compilation (generated
# by `ocamlc`/`ocamlopt` when invoked using the option `-bin-annot`).
# These files are typically useful for code inspection tools
# (e.g. Merlin).
*.cmt
*.cmti
# ocamlbuild and Dune default working directory
_build/
# ocamlbuild targets
*.byte
*.native
# oasis generated files
setup.data
setup.log
# Merlin configuring file for Vim and Emacs
.merlin
# Dune generated files
*.install
# Local OPAM switch
_opam/

Key Pattern Breakdown

Build Outputs & Compiled Artifacts

Generated binary files, compilation targets, and distribution bundles that can be reliably reproduced from source.

*.annot*.a*.o_build/

Execution Caches & Runtime Logs

Diagnostic logs, runtime metadata, test coverage reports, and incremental compiler caches that cause noisy repository diffs.

setup.log

Source & Verification

License: CC0-1.0

Place this file in the root directory of your project as .gitignore. Changes take effect on newly added or untracked files.