Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,6 @@ static const ${tagProperty}Value = '$tagValue';
final superClassProperty = superclass?.getProperty(property.name);
if (superClassProperty != null) {
// This property will be already set in the super constructor.
// TODO: The parameter in the constructor currently has the super class
// property type.
continue;
}
if (property.setterPrivate) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ void main(List<String> args) async {
? ToLinkHook(packageName)
: const ToAppBundle(),
);
// TODO(https://github.com/dart-lang/native/issues/1208): Report
// dependency on asset.
output.addDependency(dataAsset.uri);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,6 @@ void main(List<String> args) async {
? const ToLinkHook('complex_link')
: const ToAppBundle(),
);
// TODO(https://github.com/dart-lang/native/issues/1208): Report
// dependency on asset.
output.addDependency(dataAsset.uri);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ void main(List<String> args) async {
? ToLinkHook(packageName)
: const ToAppBundle(),
);
// TODO(https://github.com/dart-lang/native/issues/1208): Report
// dependency on asset.
output.addDependency(dataAsset.uri);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,8 @@ import 'package:native_assets_cli/code_assets_builder.dart';
import 'package:native_assets_cli/native_assets_cli.dart';

void main(List<String> args) async {
// TODO(https://github.com/dart-lang/native/issues/39): Use user-defines to
// control this instead.
const localBuild = false;

await build(args, (input, output) async {
// ignore: dead_code
final localBuild = input.userDefines['local_build'] as bool? ?? false;
if (localBuild) {
await runBuild(input, output);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,3 +21,11 @@ dev_dependencies:
ffigen: ^18.0.0
lints: ^5.1.1
test: ^1.25.15

# Note: If pub workspaces are in use, the user-defines must be in the workspace
# pub file. These defines are only in effect if `resolution: workspace` above is
# removed.
hooks:
user_defines:
download_asset: # package name
local_build: false
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ void main(List<String> args) async {
? ToLinkHook(packageName)
: const ToAppBundle(),
);
// TODO(https://github.com/dart-lang/native/issues/1208): Report
// dependency on asset.
output.addDependency(dataAsset.uri);
}
});
Expand Down
3 changes: 2 additions & 1 deletion pkgs/native_assets_cli/lib/src/config.dart
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,8 @@ extension type HookInputUserDefines._(HookInput _input) {
if (pubspecSource != null) {
sources.add(pubspecSource);
}
// TODO: Add commandline arguments.
// TODO(https://github.com/dart-lang/native/issues/2215): Add commandline
// arguments.
for (final source in sources) {
final relativepath = source.defines[key];
if (relativepath is String) {
Expand Down
2 changes: 2 additions & 0 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,8 @@ workspace:
# Hook user-defines are specified in the pub workspace.
hooks:
user_defines:
download_asset:
local_build: false
user_defines: # package name
user_define_key: user_define_value
user_define_key2:
Expand Down
Loading