2021-08-20 09:33:53 -07:00
|
|
|
builders:
|
|
|
|
versions:
|
|
|
|
import: 'tool/write_versions.dart'
|
|
|
|
build_to: cache
|
|
|
|
builder_factories: ["writeVersions"]
|
|
|
|
build_extensions: {"$package$": ["lib/versions.json"]}
|
2022-07-10 05:27:56 -07:00
|
|
|
api_index:
|
|
|
|
import: 'package:code_snippets/indexer.dart'
|
|
|
|
build_to: cache
|
|
|
|
builder_factories: ['DartIndexBuilder.new']
|
|
|
|
auto_apply: all_packages
|
|
|
|
runs_before: [code_snippets]
|
|
|
|
build_extensions: {"lib/lib": ['api.json']}
|
2022-02-14 13:13:00 -08:00
|
|
|
code_snippets:
|
|
|
|
import: 'tool/snippets.dart'
|
|
|
|
build_to: cache
|
|
|
|
builder_factories: ["SnippetsBuilder.new"]
|
|
|
|
build_extensions: {"": [".excerpt.json"]}
|
|
|
|
auto_apply: none
|
2022-07-10 05:27:56 -07:00
|
|
|
defaults:
|
|
|
|
options:
|
|
|
|
release: false
|
|
|
|
release_options:
|
|
|
|
release: true
|
2021-08-20 09:33:53 -07:00
|
|
|
|
2021-03-12 12:14:45 -08:00
|
|
|
targets:
|
2023-01-22 13:53:45 -08:00
|
|
|
prepare:
|
2022-07-10 05:27:56 -07:00
|
|
|
auto_apply_builders: false
|
|
|
|
builders:
|
2023-01-22 13:53:45 -08:00
|
|
|
":versions":
|
|
|
|
enabled: true
|
2022-07-10 05:27:56 -07:00
|
|
|
drift_dev:preparing_builder:
|
|
|
|
enabled: true
|
2023-01-22 13:53:45 -08:00
|
|
|
sources:
|
|
|
|
- "$package$"
|
|
|
|
- "lib/versions.json"
|
|
|
|
- "lib/snippets/**"
|
|
|
|
- "tool/write_versions.dart"
|
|
|
|
- "tool/snippets.dart"
|
|
|
|
- "test/generated/**"
|
|
|
|
|
|
|
|
codegen:
|
|
|
|
dependencies: [":prepare"]
|
|
|
|
auto_apply_builders: false
|
|
|
|
builders:
|
|
|
|
drift_dev:preparing_builder:
|
|
|
|
enabled: false # Runs in prepare target
|
|
|
|
|
|
|
|
# Modular drift generation, suitable for standalone snippets that aren't part of a database
|
|
|
|
drift_dev:analyzer:
|
2022-07-10 05:27:56 -07:00
|
|
|
enabled: true
|
2023-01-22 13:53:45 -08:00
|
|
|
options: &options
|
2023-01-28 07:53:35 -08:00
|
|
|
sql:
|
|
|
|
dialect: sqlite
|
|
|
|
options:
|
|
|
|
version: "3.39"
|
2023-01-22 13:53:45 -08:00
|
|
|
generate_for:
|
|
|
|
include: &modular
|
2023-09-16 10:42:53 -07:00
|
|
|
- "lib/snippets/_shared/**"
|
2023-01-22 13:53:45 -08:00
|
|
|
- "lib/snippets/modular/**"
|
2023-09-16 10:42:53 -07:00
|
|
|
- "lib/snippets/drift_files/custom_queries.*"
|
2023-01-22 13:53:45 -08:00
|
|
|
drift_dev:modular:
|
|
|
|
enabled: true
|
|
|
|
options: *options
|
|
|
|
generate_for:
|
|
|
|
include: *modular
|
|
|
|
|
|
|
|
# Non-modular drift generation. Used for some "getting started" e2e examples.
|
|
|
|
drift_dev:drift_dev:
|
|
|
|
enabled: true
|
|
|
|
options: *options
|
|
|
|
generate_for:
|
|
|
|
exclude: *modular
|
2022-07-10 05:27:56 -07:00
|
|
|
json_serializable:
|
|
|
|
enabled: true
|
|
|
|
sources:
|
|
|
|
- lib/**
|
2022-08-15 10:55:06 -07:00
|
|
|
- test/generated/**
|
2022-07-10 05:27:56 -07:00
|
|
|
|
2023-01-22 13:53:45 -08:00
|
|
|
syntax_highlighting:
|
|
|
|
dependencies: [":codegen"]
|
2021-08-20 09:33:53 -07:00
|
|
|
builders:
|
2022-05-13 02:57:03 -07:00
|
|
|
":code_snippets":
|
2022-02-13 07:55:57 -08:00
|
|
|
enabled: true
|
|
|
|
generate_for:
|
2022-07-10 05:27:56 -07:00
|
|
|
include:
|
|
|
|
- "lib/snippets/**/*.dart"
|
2022-11-02 13:26:20 -07:00
|
|
|
- "lib/snippets/**/*.drift"
|
2022-07-10 05:27:56 -07:00
|
|
|
- "lib/snippets/*.dart"
|
|
|
|
exclude:
|
|
|
|
- "**/*.g.dart"
|
2021-08-20 09:33:53 -07:00
|
|
|
auto_apply_builders: false
|
|
|
|
sources:
|
|
|
|
- "$package$"
|
2022-02-13 07:55:57 -08:00
|
|
|
- "lib/snippets/**"
|
2022-02-14 13:13:00 -08:00
|
|
|
- "tool/snippets.dart"
|
2021-08-20 09:33:53 -07:00
|
|
|
|
2023-05-31 14:48:13 -07:00
|
|
|
worker:
|
|
|
|
dependencies: ['$default']
|
|
|
|
auto_apply_builders: false
|
|
|
|
sources:
|
2023-06-14 15:06:18 -07:00
|
|
|
- "web/drift_worker.dart"
|
2023-05-31 14:48:13 -07:00
|
|
|
builders:
|
|
|
|
build_web_compilers:entrypoint:
|
|
|
|
options:
|
|
|
|
compiler: dart2js
|
|
|
|
build_web_compilers:dart2js_archive_extractor:
|
|
|
|
enabled: false
|
|
|
|
|
|
|
|
dart2js_archives:
|
|
|
|
auto_apply_builders: false
|
|
|
|
dependencies: [":$default", ":worker"]
|
|
|
|
builders:
|
|
|
|
build_web_compilers:dart2js_archive_extractor:
|
|
|
|
enabled: true
|
|
|
|
|
2021-03-12 12:14:45 -08:00
|
|
|
$default:
|
2023-01-22 13:53:45 -08:00
|
|
|
dependencies: [":codegen", ":syntax_highlighting"]
|
2021-03-12 12:14:45 -08:00
|
|
|
builders:
|
2021-03-12 14:16:48 -08:00
|
|
|
built_site:
|
|
|
|
release_options:
|
|
|
|
environment: "preview"
|
2022-05-13 02:57:03 -07:00
|
|
|
build_web_compilers:entrypoint:
|
2023-05-31 14:48:13 -07:00
|
|
|
generate_for:
|
2023-09-17 09:10:49 -07:00
|
|
|
include:
|
|
|
|
- "web/**"
|
2023-05-31 14:48:13 -07:00
|
|
|
exclude:
|
2023-06-14 15:06:18 -07:00
|
|
|
- "web/drift_worker.dart"
|
2021-03-12 12:14:45 -08:00
|
|
|
release_options:
|
|
|
|
# Turn of null assertions for release builds, it looks like this
|
|
|
|
# makes generated code slightly smaller.
|
|
|
|
native_null_assertions: false
|
|
|
|
dart2js_args:
|
|
|
|
- "-O4"
|
|
|
|
- "--csp"
|
2022-07-10 05:27:56 -07:00
|
|
|
# These builders should run in the source_gen target
|
|
|
|
drift_dev:preparing_builder:
|
|
|
|
enabled: false
|
|
|
|
drift_dev:drift_dev:
|
|
|
|
enabled: false
|
|
|
|
source_gen:combining_builder:
|
|
|
|
enabled: false
|
|
|
|
json_serializable:
|
|
|
|
enabled: false
|
2023-05-31 14:48:13 -07:00
|
|
|
build_web_compilers:dart2js_archive_extractor:
|
|
|
|
enabled: false
|
2021-03-12 12:14:45 -08:00
|
|
|
sources:
|
2023-05-31 14:48:13 -07:00
|
|
|
include:
|
|
|
|
- "lib/**"
|
|
|
|
- "pages/**"
|
|
|
|
- "templates/**"
|
|
|
|
- "web/**"
|
|
|
|
- "$package$"
|
|
|
|
- "pubspec.yaml"
|
|
|
|
- "theme.yaml"
|
|
|
|
- "website.yaml"
|
2022-07-10 05:27:56 -07:00
|
|
|
|
|
|
|
# Snippets referencing public API members from this package will get dartdoc links
|
|
|
|
# embedded in them.
|
|
|
|
global_options:
|
|
|
|
":api_index":
|
|
|
|
options:
|
2024-02-07 13:29:09 -08:00
|
|
|
packages: ['drift', 'drift_dev', 'sqlite3', 'sqlite3_flutter_libs', 'sqlcipher_flutter_libs']
|
2022-10-25 13:15:09 -07:00
|
|
|
|
|
|
|
additional_public_assets:
|
|
|
|
- "pages/**"
|