Java – How do I add author templates to an existing file in Android Studio?

How do I add author templates to an existing file in Android Studio?… here is a solution to the problem.

How do I add author templates to an existing file in Android Studio?

I’m going to add this

/**
 * Created by cyborn on 1/10/15.
 */

Template to my existing Java file in Android Studio.

Solution

From File > Settings, open the Editor tab. Select File and Code Templates. Click the Include tab. You can define your own templates and define variables.

#set ($USER = "Basim")
/**
 * Created by ${USER} on ${DATE}.
 */

Related Problems and Solutions