While trying to symlink some udev rules out of `/etc/udev/rules.d/`, I used a wildcard and removed all the rules.
There is an exact copy of the rules.d inside of /lib/udev/rules.d/
So you can just copy them across:
sudo cp -r --no-clobber /lib/udev/rules.d/* /etc/udev/rules.d/
Or if you did it the other way, e.g. you accidentally delete files from /lib/udev/rules.d/
, you can just swap etc
and lib
in the command above. Very important, note the * symbol!
Hope this helps!