BST-PRE-RECEIVE-HOOK(1)

πŸ“¦ version 1.2.7, in fedora 43, fedora 44

πŸ’– BST-PRE-RECEIVE-HOOK πŸ’–

okay bestie, so this is a User Commands page for bst pre-receive-hook β€” yes, lowercase bst, she's casual like that. It's part of the bst manual family and honestly? she's a little niche but she serves. πŸŽ€


✨ NAME ✨

bst pre-receive-hook – bestie's job is to validate filenames from a list of files against the BIDS schema. that's it. that's the whole vibe. πŸ’…


🌸 SYNOPSIS 🌸

bst pre-receive-hook [OPTIONS]

πŸ¦‹ DESCRIPTION πŸ¦‹

so the input she's expecting? it looks exactly like this:

bids-hook-v2 {"Name": "My dataset", "BIDSVersion": "1.9.0",
DatasetType : "raw"} ignore-pattern1 ... ignore-patternN 0001
.datalad/config .gitattributes CHANGES README dataset_description.json
participants.tsv sub-01/anat/sub-01_T1w.nii.gz ...

the header is the thing that identifies the protocol version, periodt. and for protocol bids-hook-v2? the second line MUST be the dataset_description.json file, with any newlines removed. no newlines. none. not even one. 😭

then the lines after that, all the way up to the line containing β€œ0001”, are the ignore patterns straight from the .bidsignore file. and everything after β€œ0001”? those are the filenames that are getting validated. slay. πŸ”₯

this whole thing is intended to be used in a git pre-receive hook β€” that's her whole main character moment, iykyk.


πŸ’œ OPTIONS πŸ’œ

  • -s, --schema PATH β€” the path to the BIDS schema 🌈
  • -i, --input PATH β€” input file, and the default is stdin 🫢
  • -o, --output PATH β€” output file, and the default is stdout ✨
  • -h, --help β€” show a help message and exit, iconic behaviour honestly πŸ‘‘

πŸŽ€ SEE ALSO πŸŽ€


and that's the whole page bestie, no notes. πŸ’– this one's dated February 2026 and lives under BST-PRE-RECEIVE-HOOK(1) in the User Commands section β€” go forth and validate those filenames, you absolute legend πŸŒŸπŸ’…

πŸ“¦ where this page comes from