Skip to content

Commit d00a42a

Browse files
committed
version 0.2.0
1 parent 8d653e8 commit d00a42a

7 files changed

Lines changed: 106 additions & 82 deletions

File tree

.github/workflows/publish.yml

Lines changed: 52 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -10,22 +10,22 @@ jobs:
1010
name: "Publish Android"
1111
runs-on: "ubuntu-latest"
1212
steps:
13-
- uses: actions/checkout@v3
13+
- uses: actions/checkout@v4
1414
- uses: subosito/flutter-action@v2
1515
with:
1616
channel: 'stable'
17-
- uses: actions/setup-java@v2
17+
- uses: actions/setup-java@v4
1818
with:
1919
distribution: 'zulu'
20-
java-version: '11'
20+
java-version: '17'
2121
- run: flutter pub get
2222
- run: flutter build apk
2323
- run: flutter build appbundle
24-
- uses: actions/upload-artifact@v3
24+
- uses: actions/upload-artifact@v4
2525
with:
2626
name: android
2727
path: build/app/outputs/flutter-apk/app-release.apk
28-
- uses: actions/upload-artifact@v3
28+
- uses: actions/upload-artifact@v4
2929
with:
3030
name: android_bundle
3131
path: build/app/outputs/bundle/release/app.aab
@@ -34,13 +34,13 @@ jobs:
3434
runs-on: "ubuntu-latest"
3535
name: "Publish Web"
3636
steps:
37-
- uses: actions/checkout@v3
37+
- uses: actions/checkout@v4
3838
- uses: subosito/flutter-action@v2
3939
with:
4040
channel: 'stable'
4141
- run: flutter pub get
4242
- run: flutter build web
43-
- uses: actions/upload-artifact@v3
43+
- uses: actions/upload-artifact@v4
4444
with:
4545
name: web
4646
path: build/web/
@@ -49,15 +49,14 @@ jobs:
4949
name: "Publish Linux"
5050
runs-on: "ubuntu-latest"
5151
steps:
52-
- uses: actions/checkout@v3
52+
- uses: actions/checkout@v4
5353
- uses: subosito/flutter-action@v2
5454
with:
5555
channel: 'stable'
56-
- run: sudo apt-get update -y && sudo apt-get install -y ninja-build libgtk-3-dev
57-
- run: flutter config --enable-linux-desktop
56+
- run: sudo apt-get update -y && sudo apt-get install -y ninja-build libgtk-3-dev libsecret-1-dev
5857
- run: flutter pub get
5958
- run: flutter build linux
60-
- uses: actions/upload-artifact@v3
59+
- uses: actions/upload-artifact@v4
6160
with:
6261
name: linux_x64
6362
path: build/linux/x64/release/bundle/
@@ -66,14 +65,50 @@ jobs:
6665
runs-on: windows-latest
6766
name: "Publish Windows"
6867
steps:
69-
- uses: actions/checkout@v3
68+
- uses: actions/checkout@v4
7069
- uses: subosito/flutter-action@v2
7170
with:
72-
channel: 'beta'
73-
- run: flutter config --enable-windows-desktop
71+
channel: 'stable'
7472
- run: flutter pub get
7573
- run: flutter build windows
76-
- uses: actions/upload-artifact@v3
74+
- uses: actions/upload-artifact@v4
75+
with:
76+
name: windows_x64
77+
path: build/windows/x64/runner/Release/
78+
79+
macos:
80+
name: "Publish macOS"
81+
runs-on: macos-latest
82+
steps:
83+
- uses: actions/checkout@v4
84+
- uses: subosito/flutter-action@v2
85+
with:
86+
channel: 'stable'
87+
- run: flutter pub get
88+
- run: flutter build macos
89+
- uses: actions/upload-artifact@v4
90+
with:
91+
name: macos
92+
path: build/macos/Build/Products/Release/*.app
93+
94+
release:
95+
name: "Create Release"
96+
needs: [android, web, linux, windows, macos]
97+
runs-on: ubuntu-latest
98+
permissions:
99+
contents: write
100+
steps:
101+
- uses: actions/download-artifact@v4
102+
with:
103+
path: artifacts/
104+
- name: Archive artifacts
105+
run: |
106+
cd artifacts
107+
for dir in */; do
108+
name="${dir%/}"
109+
zip -r "../${name}.zip" "$dir"
110+
done
111+
- uses: softprops/action-gh-release@v2
77112
with:
78-
name: windows_64
79-
path: build/windows/runner/Release/
113+
files: "*.zip"
114+
generate_release_notes: true

android/app/build.gradle

Lines changed: 26 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,71 +1,60 @@
1+
plugins {
2+
id "com.android.application"
3+
id "kotlin-android"
4+
id "dev.flutter.flutter-gradle-plugin"
5+
}
6+
17
def localProperties = new Properties()
2-
def localPropertiesFile = rootProject.file('local.properties')
8+
def localPropertiesFile = rootProject.file("local.properties")
39
if (localPropertiesFile.exists()) {
4-
localPropertiesFile.withReader('UTF-8') { reader ->
10+
localPropertiesFile.withReader("UTF-8") { reader ->
511
localProperties.load(reader)
612
}
713
}
814

9-
def flutterRoot = localProperties.getProperty('flutter.sdk')
10-
if (flutterRoot == null) {
11-
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12-
}
13-
14-
def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15+
def flutterVersionCode = localProperties.getProperty("flutter.versionCode")
1516
if (flutterVersionCode == null) {
16-
flutterVersionCode = '1'
17+
flutterVersionCode = "1"
1718
}
1819

19-
def flutterVersionName = localProperties.getProperty('flutter.versionName')
20+
def flutterVersionName = localProperties.getProperty("flutter.versionName")
2021
if (flutterVersionName == null) {
21-
flutterVersionName = '1.0'
22+
flutterVersionName = "1.0"
2223
}
2324

24-
apply plugin: 'com.android.application'
25-
apply plugin: 'kotlin-android'
26-
apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
27-
2825
android {
29-
compileSdkVersion flutter.compileSdkVersion
30-
ndkVersion flutter.ndkVersion
26+
namespace = "com.github.aminalaee.s3gui"
27+
compileSdk = flutter.compileSdkVersion
28+
ndkVersion = flutter.ndkVersion
3129

3230
compileOptions {
33-
sourceCompatibility JavaVersion.VERSION_1_8
34-
targetCompatibility JavaVersion.VERSION_1_8
31+
sourceCompatibility = JavaVersion.VERSION_17
32+
targetCompatibility = JavaVersion.VERSION_17
3533
}
3634

3735
kotlinOptions {
38-
jvmTarget = '1.8'
36+
jvmTarget = "17"
3937
}
4038

4139
sourceSets {
42-
main.java.srcDirs += 'src/main/kotlin'
40+
main.java.srcDirs += "src/main/kotlin"
4341
}
4442

4543
defaultConfig {
46-
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
47-
applicationId "com.github.aminalaee.s3gui"
48-
// You can update the following values to match your application needs.
49-
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-build-configuration.
50-
minSdkVersion flutter.minSdkVersion
51-
targetSdkVersion flutter.targetSdkVersion
52-
versionCode flutterVersionCode.toInteger()
53-
versionName flutterVersionName
44+
applicationId = "com.github.aminalaee.s3gui"
45+
minSdk = flutter.minSdkVersion
46+
targetSdk = flutter.targetSdkVersion
47+
versionCode = flutterVersionCode.toInteger()
48+
versionName = flutterVersionName
5449
}
5550

5651
buildTypes {
5752
release {
58-
// TODO: Add your own signing config for the release build.
59-
// Signing with the debug keys for now, so `flutter run --release` works.
60-
signingConfig signingConfigs.debug
53+
signingConfig = signingConfigs.debug
6154
}
6255
}
6356
}
6457

6558
flutter {
66-
source '../..'
67-
}
68-
69-
dependencies {
70-
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
59+
source "../.."
7160
}

android/app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2-
package="com.github.aminalaee.s3gui">
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
32
<application
43
android:label="s3gui"
54
android:name="${applicationName}"

android/build.gradle

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,18 @@
1-
buildscript {
2-
ext.kotlin_version = '1.6.10'
3-
repositories {
4-
google()
5-
mavenCentral()
6-
}
7-
8-
dependencies {
9-
classpath 'com.android.tools.build:gradle:7.1.2'
10-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
11-
}
12-
}
13-
141
allprojects {
152
repositories {
163
google()
174
mavenCentral()
185
}
196
}
207

21-
rootProject.buildDir = '../build'
8+
rootProject.buildDir = "../build"
229
subprojects {
2310
project.buildDir = "${rootProject.buildDir}/${project.name}"
2411
}
2512
subprojects {
26-
project.evaluationDependsOn(':app')
13+
project.evaluationDependsOn(":app")
2714
}
2815

29-
task clean(type: Delete) {
16+
tasks.register("clean", Delete) {
3017
delete rootProject.buildDir
3118
}

android/gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
33
zipStoreBase=GRADLE_USER_HOME
44
zipStorePath=wrapper/dists
5-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.4-all.zip
5+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.3-all.zip

android/settings.gradle

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,25 @@
1-
include ':app'
1+
pluginManagement {
2+
def flutterSdkPath = {
3+
def properties = new Properties()
4+
file("local.properties").withInputStream { properties.load(it) }
5+
def flutterSdkPath = properties.getProperty("flutter.sdk")
6+
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
7+
return flutterSdkPath
8+
}()
29

3-
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
4-
def properties = new Properties()
10+
includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
511

6-
assert localPropertiesFile.exists()
7-
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
12+
repositories {
13+
google()
14+
mavenCentral()
15+
gradlePluginPortal()
16+
}
17+
}
818

9-
def flutterSdkPath = properties.getProperty("flutter.sdk")
10-
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
11-
apply from: "$flutterSdkPath/packages/flutter_tools/gradle/app_plugin_loader.gradle"
19+
plugins {
20+
id "dev.flutter.flutter-plugin-loader" version "1.0.0"
21+
id "com.android.application" version "8.1.0" apply false
22+
id "org.jetbrains.kotlin.android" version "1.9.22" apply false
23+
}
24+
25+
include ":app"

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ description: S3 GUI for desktop and mobile.
33

44
publish_to: 'none'
55

6-
version: 0.1.0+1
6+
version: 0.2.0+2
77

88
environment:
99
sdk: '>=3.0.0 <4.0.0'

0 commit comments

Comments
 (0)