Merge pull request #381 from afischerdev/update-version
Update workflow, add check equal folder #379
This commit is contained in:
commit
010141af47
4 changed files with 28 additions and 3 deletions
12
.github/workflows/gradle-publish.yml
vendored
12
.github/workflows/gradle-publish.yml
vendored
|
@ -12,6 +12,7 @@ jobs:
|
|||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
environment: BRouter
|
||||
permissions:
|
||||
contents: read
|
||||
packages: write
|
||||
|
@ -27,6 +28,17 @@ jobs:
|
|||
server-id: github # Value of the distributionManagement/repository/id field of the pom.xml
|
||||
settings-path: ${{ github.workspace }} # location for the settings.xml file
|
||||
|
||||
- name: Setup keystore
|
||||
env:
|
||||
BROUTER_KEYSTORE_BASE64: ${{ secrets.BROUTER_KEYSTORE_BASE64 }}
|
||||
run: |
|
||||
echo $BROUTER_KEYSTORE_BASE64 | base64 -di > ${{ github.workspace }}/brouter.jks
|
||||
- name: Build with Gradle
|
||||
env:
|
||||
ORG_GRADLE_PROJECT_RELEASE_STORE_FILE: ${{ secrets.BROUTER_KEYSTORE_FILE }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_KEY_ALIAS: ${{ secrets.BROUTER_KEY_ALIAS }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_KEY_PASSWORD: ${{ secrets.BROUTER_KEY_PASSWORD }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_STORE_PASSWORD: ${{ secrets.BROUTER_STORE_PASSWORD }}
|
||||
- name: Build with Gradle
|
||||
run: gradle build
|
||||
|
||||
|
|
12
.github/workflows/gradle.yml
vendored
12
.github/workflows/gradle.yml
vendored
|
@ -13,7 +13,7 @@ jobs:
|
|||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
environment: BRouter
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- name: Set up JDK 11
|
||||
|
@ -24,7 +24,17 @@ jobs:
|
|||
cache: gradle
|
||||
- name: Create local.properties
|
||||
run: touch local.properties
|
||||
- name: Setup keystore
|
||||
env:
|
||||
BROUTER_KEYSTORE_BASE64: ${{ secrets.BROUTER_KEYSTORE_BASE64 }}
|
||||
run: |
|
||||
echo $BROUTER_KEYSTORE_BASE64 | base64 -di > ${{ github.workspace }}/brouter.jks
|
||||
- name: Build with Gradle
|
||||
env:
|
||||
ORG_GRADLE_PROJECT_RELEASE_STORE_FILE: ${{ secrets.BROUTER_KEYSTORE_FILE }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_KEY_ALIAS: ${{ secrets.BROUTER_KEY_ALIAS }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_KEY_PASSWORD: ${{ secrets.BROUTER_KEY_PASSWORD }}
|
||||
ORG_GRADLE_PROJECT_RELEASE_STORE_PASSWORD: ${{ secrets.BROUTER_STORE_PASSWORD }}
|
||||
run: ./gradlew build
|
||||
- name: Upload ZIP
|
||||
uses: actions/upload-artifact@v2
|
||||
|
|
|
@ -596,7 +596,8 @@ public class BRouterActivity extends Activity implements ActivityCompat.OnReques
|
|||
}
|
||||
}
|
||||
|
||||
if (checkExternalStorageWritable()) {
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q
|
||||
&& checkExternalStorageWritable()) {
|
||||
res.add(Environment.getExternalStorageDirectory());
|
||||
}
|
||||
|
||||
|
|
|
@ -204,7 +204,9 @@ public class BRouterView extends View {
|
|||
|
||||
// new init is done move old files
|
||||
if (waitingForMigration) {
|
||||
moveFolders(oldMigrationPath, basedir + "/brouter");
|
||||
Log.d("BR", "path " + oldMigrationPath + " " + basedir);
|
||||
if (!oldMigrationPath.equals(basedir + "/brouter"))
|
||||
moveFolders(oldMigrationPath, basedir + "/brouter");
|
||||
waitingForMigration = false;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue