Last Update November 3, 2020: We improved the overall article.
Gradle Version Seting Up :
First open your existing project in android studio >
Create version.properties file in your root project. See flowing image
Now Open version.properties File and insert flowing line to add
VERSION_CODE=14
Than Open gradle.build file add the flowing code insert the android{ insert here }
Now we need signing Configuration add flowing line here . Tips : please type code manually by using your hand not copy and past than understand properly.
Now Need Setting Up Buildtype add flowing line here
Here my full gradle.build file source file
Congratulations! You have done ! now Run You Apps See the signed .apk file with version .