How to add copyright to Android-Studio?
The title says everything. If I want to add copyright comment in code files in Android Studio?
I, of course, find the Copyright settings in Preference/Copyright, but I can't make it work... copyrights just don't appear when I create a new Java file.
Is it a bug of Android Studio or did I miss something ?
On the file you want to insert the copyright notice you have to press Alt+Insert for Windows and GNU/Linux or Command+N for Mac and select the copyright to be inserted.
http://www.jetbrains.com/idea/webhelp/generating-and-updating-copyright-notice.html
File > Settings > Editor > Copyright > Copyright Profiles > + add -> profile name
Sample Copyright Template Text
/**
* Created by $username on $today
* Copyright (c) $today.year . All rights reserved.
* Last modified $file.lastModified
*/
If you need any extra variables, please visit source Copyright Profiles
You need to first create a copyright profile (Settings | Copyright | Copyright profiles
), then go to Settings | Copyright
and change the default copyright.