Skip to content

Commit 7d9e1a2

Browse files
adding channel param to install sdk (#49)
rename to release channel change version to channel change string to enum for channel add integration test for channel remove typo update comment remove local formatting changes Update executor Update machine executor version Co-authored-by: Alex Fernandez <alex@flyclops.com>
1 parent d163a37 commit 7d9e1a2

File tree

7 files changed

+48
-12
lines changed

7 files changed

+48
-12
lines changed

.circleci/test-deploy.yml

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: 2.1
22
orbs:
33
flutter: circleci/flutter@dev:<<pipeline.git.revision>>
44
orb-tools: circleci/orb-tools@11.1
5-
android: circleci/android@2.1.2
5+
android: circleci/android@3.0.1
66
filters: &filters
77
tags:
88
only: /.*/
@@ -19,13 +19,30 @@ jobs:
1919
app-dir: ./sample
2020
- flutter/install_ios_gem:
2121
app-dir: ./sample
22-
- run:
22+
- run:
2323
name: 'check that the sdk is installed properly'
2424
command: cd sample && flutter doctor && rbenv version
25+
integration-test-channel-beta:
26+
macos:
27+
xcode: 14.2.0
28+
resource_class: macos.m1.large.gen1
29+
steps:
30+
- checkout
31+
- flutter/install_sdk_and_pub:
32+
app-dir: ./sample
33+
channel: beta
34+
version: 3.27.0-0.1.pre
35+
- flutter/install_ios_pod:
36+
app-dir: ./sample
37+
- flutter/install_ios_gem:
38+
app-dir: ./sample
39+
- run:
40+
name: 'check that the sdk is installed properly from the beta channel'
41+
command: cd sample && flutter doctor && rbenv version
2542
integration-test-linux:
2643
executor:
27-
name: android/android-machine
28-
tag: '2022.09.1'
44+
name: android/android_machine
45+
tag: '2022.12.1'
2946
steps:
3047
- checkout
3148
- flutter/install_sdk_and_pub:
@@ -35,7 +52,7 @@ jobs:
3552
app-dir: ./sample
3653
- flutter/install_android_gem:
3754
app-dir: ./sample
38-
- run:
55+
- run:
3956
name: 'check that the sdk is installed properly'
4057
command: cd sample && flutter doctor && rvm version
4158
workflows:
@@ -44,6 +61,8 @@ workflows:
4461
# Make sure to include "filters: *filters" in every test job you want to run as part of your deployment.
4562
- integration-test-macos:
4663
filters: *filters
64+
- integration-test-channel-beta:
65+
filters: *filters
4766
- integration-test-linux:
4867
filters: *filters
4968
- flutter/unit_test:

CHANGELOG.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77
## [Unreleased]
88
- Current development changes [ to be moved to release ]
99

10-
## [1.0.0] - YYYY-MM-DD
10+
## [2.1.0] - 2024-10-31
1111
### Added
12-
- Initial Release
13-
### Changed
14-
- Initial Release
15-
### Removed
12+
- feat: added channal parameter to `flutter/install_sdk` and `flutter/install_sdk_and_pub` so that you can install from `beta` releases if you want
13+
14+
## [2.0.4] - 2024-04-06
15+
- fix: flutter installation fail by @KevinJ1008 in #41
16+
- fix: Address broken install script by @zaki-arain in #44
17+
18+
## [1.0.0] - 2020-06-22
1619
- Initial Release
1720

1821

src/commands/install_sdk.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
description: >
22
Install Flutter SDK
33
parameters:
4+
channel:
5+
type: enum
6+
description: The release channel your version is in.
7+
default: "stable"
8+
enum: ["stable", "beta"]
49
version:
510
type: string
611
description: The target version for the Flutter SDK.
@@ -18,6 +23,7 @@ steps:
1823
environment:
1924
ORB_EVAL_INSTALL_LOCATION: <<parameters.install-location>>
2025
ORB_VAL_FLUTTER_SDK_VERSION: <<parameters.version>>
26+
ORB_VAL_FLUTTER_RELEASE_CHANNEL: <<parameters.channel>>
2127
command: <<include(scripts/install-sdk.sh)>>
2228
- run:
2329
name: Run flutter doctor

src/commands/install_sdk_and_pub.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
description: >
22
Install Flutter SDK and your flutter packages with automated caching and best practices applied. Requires lock file.
33
parameters:
4+
channel:
5+
type: enum
6+
description: The release channel your version is in.
7+
default: "stable"
8+
enum: ["stable", "beta"]
49
version:
510
type: string
611
description: The target version for the Flutter SDK.
@@ -19,6 +24,7 @@ parameters:
1924
type: string
2025
steps:
2126
- install_sdk:
27+
channel: <<parameters.channel>>
2228
version: <<parameters.version>>
2329
install-location: <<parameters.install-location>>
2430
- install_pub:

src/examples/install_for_android_machine.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ usage:
1111
name: android/android-machine
1212
steps:
1313
- flutter/install_sdk_and_pub:
14+
channel: stable
1415
version: 3.0.3
1516
- flutter/install_android_gradle_dependencies
1617
- flutter/install_android_gem

src/examples/install_for_macos.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ usage:
1010
xcode: 12.5.1
1111
steps:
1212
- flutter/install_sdk_and_pub:
13+
channel: stable
1314
version: 3.0.3
1415
- flutter/install_ios_pod
1516
- flutter/install_ios_gem

src/scripts/install-sdk.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@ function install_flutter() {
1010
[[ $arch =~ "arm64" ]] && version="flutter_${uname}_arm64" || version="flutter_${uname}"
1111
[[ $uname == "linux" ]] && suffix="tar.xz" || suffix="zip"
1212

13-
baseurl="https://storage.googleapis.com/flutter_infra_release/releases/stable"
14-
fullurl="$baseurl/$uname/${version}_$ORB_VAL_FLUTTER_SDK_VERSION-stable.${suffix}"
13+
baseurl="https://storage.googleapis.com/flutter_infra_release/releases/$ORB_VAL_FLUTTER_RELEASE_CHANNEL"
14+
fullurl="$baseurl/$uname/${version}_$ORB_VAL_FLUTTER_SDK_VERSION-$ORB_VAL_FLUTTER_RELEASE_CHANNEL.${suffix}"
1515

1616
curl -o "flutter_sdk.${suffix}" "$fullurl"
1717

0 commit comments

Comments
 (0)