-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add do not generate timestamp options
- Loading branch information
Showing
18 changed files
with
163 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
version: 2 | ||
enable-beta-ecosystems: true | ||
updates: | ||
- directory: "/" | ||
open-pull-requests-limit: 5 | ||
package-ecosystem: "pub" | ||
rebase-strategy: auto | ||
schedule: | ||
interval: "monthly" | ||
timezone: "UTC" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
{ | ||
"recommendations": [ | ||
"dart-code.dart-code" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "Example", | ||
"request": "launch", | ||
"type": "dart", | ||
"program": "tool/runner.dart", | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"[dart]": { | ||
"editor.selectionHighlight": false, | ||
"editor.suggest.snippetsPreventQuickSuggestions": false, | ||
"editor.suggestSelection": "first", | ||
"editor.tabCompletion": "onlySnippets", | ||
"editor.wordBasedSuggestions": false, | ||
"editor.rulers": [80], | ||
"editor.defaultFormatter": "Dart-Code.dart-code", | ||
"editor.formatOnPaste": true, | ||
"editor.formatOnSave": true, | ||
//"editor.formatOnType" : true, | ||
"editor.insertSpaces": true | ||
}, | ||
"dart.lineLength": 80, | ||
"dart.doNotFormat": ["**.g.dart", "**.mocks.dart"], | ||
"search.exclude": { | ||
".dart_tool": true, | ||
"coverage": true, | ||
"build": true | ||
}, | ||
"files.watcherExclude": { | ||
".dart_tool": true, | ||
"coverage": true, | ||
"build": true | ||
}, | ||
"debug.openDebug": "openOnDebugBreak", | ||
"explorer.fileNesting.enabled": true, | ||
"explorer.fileNesting.expand": false, | ||
"explorer.fileNesting.patterns": { | ||
"pubspec.yaml": ".packages, .metadata, .packages, pubspec.lock, *.yaml", | ||
".gitignore": ".gitattributes, .gitmodules, .gitmessage, .mailmap, .git-blame*, .dockerignore", | ||
"readme.*": "authors, backers.md, changelog*, citation*, code_of_conduct.md, codeowners, contributing.md, contributors, copying, credits, governance.md, history.md, license*, maintainers, readme*, security.md, sponsors.md", | ||
"*.dart": "$(capture).g.dart, $(capture).i.dart, $(capture).stub.dart, $(capture).web.dart, $(capture).html.dart, $(capture).js.dart, $(capture).io.dart, $(capture).base.dart" | ||
}, | ||
"files.associations": { | ||
"*.drift": "sql" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
{ | ||
"version": "2.0.0", | ||
"tasks": [ | ||
{ | ||
"label": "Dependencies", | ||
"type": "shell", | ||
"command": [ | ||
"dart pub get" | ||
], | ||
"group": { | ||
"kind": "none", | ||
"isDefault": true | ||
}, | ||
"problemMatcher": [] | ||
} | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
## 4.1.0-pre.1 - 2023-10-24 | ||
|
||
# Added | ||
|
||
- Disable timestamp generation option | ||
|
||
## 4.0.0 - 2023-07-03 | ||
|
||
### Changed | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,37 @@ | ||
import 'package:build/build.dart' show BuilderOptions; | ||
|
||
/// Builder config | ||
// @immutable | ||
/// @immutable | ||
/// @internal | ||
/// {@nodoc} | ||
class PubspecBuilderConfig { | ||
/// Generate timestamp in output file | ||
/// {@nodoc} | ||
final bool timestamp; | ||
|
||
/// Output path for generated file | ||
/// {@nodoc} | ||
final String output; | ||
|
||
/// {@nodoc} | ||
PubspecBuilderConfig.fromBuilderOptions(BuilderOptions options) | ||
: output = (options.config['output'] as String?) ?? | ||
'lib/src/constants/pubspec.yaml.g.dart'; | ||
: output = options.config['output']?.toString() ?? | ||
'lib/src/constants/pubspec.yaml.g.dart', | ||
timestamp = switch (options.config['timestamp']) { | ||
String value => switch (value.trim().toLowerCase()) { | ||
'false' || 'no' || 'n' || 'f' || '-' || '0' => false, | ||
_ => true, | ||
}, | ||
bool value => value, | ||
int value => value > 0, | ||
_ => true, | ||
}; | ||
|
||
@override | ||
String toString() => (StringBuffer() | ||
..write('Output path: ') | ||
..writeln(output)) | ||
..writeln(output) | ||
..write('Timestamp: ') | ||
..writeln(timestamp ? 'enabled' : 'disabled')) | ||
.toString(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters