The reality is much more nuanced than that, especially when you're dealing with sensitive human-subjects data. Confidentiality and consent are important factors to consider. Let's say you're doing work on how abusive romantic partners use technology to keep tabs on their victims [1]. Would it be reasonable to expect the raw recordings, transcripts, and recruitment process be made publicly available?
This example is a little clunky, bc was ~2 years ago, but for
a GWAS study we did on Early-Onset Preeclampsia where we had clinical and genomic data for 109 pregnant woman in Hawai'i, we put everything on GitHub.
[1] We created a grammar for the schema, which not only allowed us to double check the type safety of our data but then also synthesize a CSV [2] with one click and stick that in the repo so that reviewers/researchers could `git clone` the repo and reproduce everything without any permissions bottlenecks (obviously the results are gibberish with the synth data, and you have to contact us to get the real data, but this way you can get the code working and then it's just a simple file move to reproduce the full results). This is the way.
[1] https://dl.acm.org/doi/10.1145/3173574.3174241