cianru / huawei-appgallery-publish-gradle-plugin

Huawei AppGallery Publish Gradle Plugin allows you to publish the android release build file (*.apk or *.aab) to the Huawei AppGallery store
Apache License 2.0
111 stars 20 forks source link

Country code param #41

Closed vmtrue closed 1 year ago

vmtrue commented 1 year ago

Hello,

Is there any way to set up list of countries that my app would be available, or use countries from previous release? Now when I publish the app by plugin I need to choose countries every time. When I publish the app manually I don't have to do such things, countries list got from previous release.

Thanks

cosic commented 1 year ago

@vmtrue Please try your changes on 1.3.5-SNAPSHOT plugin version. Don't forget to add maven { url 'https://oss.sonatype.org/content/repositories/snapshots' } repository.

vmtrue commented 1 year ago

@cosic Hi, I've checked publishing it works

cosic commented 1 year ago

I will add description how to fix issue for history.

Just add appBasicInfo parametr into plugin extention

huaweiPublish {
    instances {
        release {
           ...
            appBasicInfo = "$projectDir/app-basic-info.json"
            ...
        }
    }
}

or use CLI param

./gradlew publishHuaweiAppGalleryRelease --appBasicInfo="./app/app-basic-info.json"

where app-basic-info.json contains json like this

{"publishCountry": "BY,MD,RU,AM,AZ,GE,KZ,KG,MN,TJ,TM,UZ"}

For more info and param options see API documentation https://developer.huawei.com/consumer/en/doc/development/AppGallery-connect-References/agcapi-app-info-update-0000001111685198