Any comprehensive guide to cursor rules please?

Good strategies to prompt cursor to build tue rules for itself?

Example:
“Look at this code and build rules from it.”