Trump sought dismissal of a lawsuit challenging energy emergency procedures, representing a legal defense of administration policy.