Skip to content

Commit 6e22d5d

Browse files
stuartmorgan-gKyleFin
authored andcommitted
[flutter_plugin_tools] Check licenses in Kotlin (flutter#4373)
The license check overlooked Kotlin, since it's not currently widely used in our repositories. Also adds the missing license to one Kotlin file, from an example that was (likely accidentally) re-generated using Kotlin instead of Java.
1 parent 671dbdd commit 6e22d5d

File tree

4 files changed

+7
-0
lines changed

4 files changed

+7
-0
lines changed

packages/shared_preferences/shared_preferences/example/android/app/src/main/kotlin/io/flutter/plugins/example/MainActivity.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
// Copyright 2013 The Flutter Authors. All rights reserved.
2+
// Use of this source code is governed by a BSD-style license that can be
3+
// found in the LICENSE file.
4+
15
package io.flutter.plugins.example
26

37
import io.flutter.embedding.android.FlutterActivity

script/tool/CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
- Added flags to `version-check` to allow overriding the platform interface
1010
major version change restriction.
1111
- Improved error handling and error messages in CHANGELOG version checks.
12+
- `license-check` now validates Kotlin files.
1213

1314
## 0.7.1
1415

script/tool/lib/src/license_check_command.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ const Set<String> _codeFileExtensions = <String>{
1616
'.h',
1717
'.html',
1818
'.java',
19+
'.kt',
1920
'.m',
2021
'.mm',
2122
'.swift',

script/tool/test/license_check_command_test.dart

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@ void main() {
6666
'html': true,
6767
'java': true,
6868
'json': false,
69+
'kt': true,
6970
'm': true,
7071
'md': false,
7172
'mm': true,

0 commit comments

Comments
 (0)