magento2 – Magento 2 – Pub/Static files create everything EXCEPT mage folder with important js files (like mixins.js or common.js)

I am using Magento 2.4.1 CE. I am not sure what changed, but since about a week when I create my static files the front- and backend break because two folders including important files are missing (e.h. mixins.js require.js) and the javascript files crash.

I have checked all the files and realized that every file and folder is available except the “mage” folder. I use the bin/magento s:s:d -f command.

So whats missing is

pub/static/frontend/theme/name/de_De/mage/

and

pub/static/adminhtml/theme/name/de_De/mage/

I have found a workaround by manually uploading the two mage folders from an old stage server into the static theme folders. Then both back- and frontend are fine. This however works only until the next static deployment of course…

I have already checked my file permissions, but since I did not change them, I don’t think it has something to do with it.

When I try to open the files by URL as in this example de_DE/mage/requirejs/mixins.js I get the following error message:

 Unable to resolve the source file for 'frontend/theme/name/de_DE/mage/requirejs/mixins.js'
<pre> #1 MagentoFrameworkAppStaticResource->launch() called at (vendor/magento/framework/App/Bootstrap.php:263)
#2 MagentoFrameworkAppBootstrap->run(&MagentoFrameworkAppStaticResource#0000000069ad91c00000000031b30d8d#) called at (pub/static.php:13) 
</pre>