I can translate an object to the position of a bone with snap menu. But I would also like to give the object the same orientation as the bone. Is there a way to do this (without using a script)?
In 2.8 can add a constraint, tweak the settings to suit, then hit the Disable and Keep Transform button to RHS of influence slider.
Remove constraint and it still has the transform.
As a script, in pose mode, Suzanne has default XYZ Euler rotation mode
>>> monkey = C.scene.objects['Suzanne'] >>> C.active_pose_bone bpy.data.objects['Armature'].pose.bones["Bone"] >>> M = C.object.matrix_world @ C.active_pose_bone.matrix >>> monkey.rotation_euler = M.to_euler()