I have a big (to me) project with lots of files that are just used for development - for example, the full Bootstrap 4 source code. I use that source code to generate
bootstrap.css
style.css
.scss
.css
.gitignore
While I don't really recommend using git as a deployment tool, if it's what you're going to do then sparse checkout is probably the easiest way to get git to do what you want.
(Using a build tool to explicitly construct a deployment package is a far more flexible solution that's less likely to bite you in the rear later. I see where you've written that it's not what you want to do, but if I'm leaving this answer I'm including this caveat so you can't say I didn't warn you.)