bintrayUpload.gradle 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. apply plugin: 'maven'
  2. Properties properties = new Properties()
  3. properties.load(project.rootProject.file('local.properties').newDataInputStream())
  4. uploadArchives {
  5. repositories {
  6. mavenDeployer {
  7. repository(url: properties.getProperty("POM_URL")) {
  8. authentication(userName: properties.getProperty("nexus.user"), password: properties.getProperty("nexus.password"))
  9. }
  10. //
  11. // pom.groupId = properties.getProperty("POM_GROUP_ID")
  12. // pom.artifactId = properties.getProperty("POM_ATRIFACT_ID")
  13. // pom.version = properties.getProperty("POM_VERSION")
  14. //
  15. // pom.project {
  16. // licenses {
  17. // license {
  18. // name 'The Apache Software License, Version 2.0'
  19. // url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
  20. // }
  21. // }
  22. // }
  23. pom.project {
  24. version properties.getProperty("POM_VERSION")
  25. artifactId properties.getProperty("POM_ATRIFACT_ID")
  26. groupId properties.getProperty("POM_GROUP_ID")
  27. packaging 'aar'
  28. description properties.getProperty("POM_DESCRIPTION")
  29. licenses {
  30. license {
  31. name 'The Apache Software License, Version 2.0'
  32. url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
  33. }
  34. }
  35. }
  36. }
  37. }
  38. }
  39. //gradlew bintrayUpload terminal中输入