I have file a.css and b.css in the same folder. My framework combines those files in a file called temp.a12cab4598347b07f0079d.css<
It will work as expected.
Also, if you need to do this recursively in any subdirectory
**/temp.*.css
Yes, that works just fine. The wildcard character in the middle of your string works well.
A great reference for gitignore patterns, matching, and rules is the official documentation on gitignore.