Initial release cleanup.
This commit is contained in:
parent
89b7769e1e
commit
334f34d84d
5 changed files with 47 additions and 13 deletions
10
.gitignore
vendored
10
.gitignore
vendored
|
@ -5,7 +5,13 @@
|
||||||
*.class
|
*.class
|
||||||
*.code-workspace
|
*.code-workspace
|
||||||
*.ctxt
|
*.ctxt
|
||||||
|
*.dart.js
|
||||||
|
*.info.json
|
||||||
*.iws
|
*.iws
|
||||||
|
*.js
|
||||||
|
*.js.deps
|
||||||
|
*.js.map
|
||||||
|
*.js_
|
||||||
*.log
|
*.log
|
||||||
*.nar
|
*.nar
|
||||||
*.rar
|
*.rar
|
||||||
|
@ -15,6 +21,9 @@
|
||||||
.DS_Store
|
.DS_Store
|
||||||
.classpath
|
.classpath
|
||||||
.dart_tool/
|
.dart_tool/
|
||||||
|
.env*
|
||||||
|
.flutter-plugins
|
||||||
|
.flutter-plugins-dependencies
|
||||||
.gradle
|
.gradle
|
||||||
.history
|
.history
|
||||||
.kobalt
|
.kobalt
|
||||||
|
@ -66,6 +75,7 @@ dependency-reduced-pom.xml
|
||||||
deploy/
|
deploy/
|
||||||
dist/
|
dist/
|
||||||
doc/
|
doc/
|
||||||
|
doc/api/
|
||||||
ehthumbs.db
|
ehthumbs.db
|
||||||
fabric.properties
|
fabric.properties
|
||||||
gen/
|
gen/
|
||||||
|
|
18
.pubignore
Normal file
18
.pubignore
Normal file
|
@ -0,0 +1,18 @@
|
||||||
|
*.dart.js
|
||||||
|
*.info.json
|
||||||
|
*.js
|
||||||
|
*.js.deps
|
||||||
|
*.js.map
|
||||||
|
*.js_
|
||||||
|
*.sh
|
||||||
|
.dart_tool/
|
||||||
|
.env*
|
||||||
|
.flutter-plugins
|
||||||
|
.flutter-plugins-dependencies
|
||||||
|
.packages
|
||||||
|
analysis_options.yaml
|
||||||
|
bin/dcat
|
||||||
|
bin/dcat.exe
|
||||||
|
build/
|
||||||
|
coverage
|
||||||
|
doc/api/
|
10
README.md
10
README.md
|
@ -50,6 +50,10 @@ dart compile exe bin/dcat.dart
|
||||||
```
|
```
|
||||||
|
|
||||||
## Library Usage
|
## Library Usage
|
||||||
|
```sh
|
||||||
|
dart pub add dcat
|
||||||
|
```
|
||||||
|
|
||||||
```dart
|
```dart
|
||||||
import 'package:dcat/dcat.dart';
|
import 'package:dcat/dcat.dart';
|
||||||
|
|
||||||
|
@ -88,10 +92,12 @@ A `CatResult` object is returned which contains the `exitCode` (`exitSuccess` or
|
||||||
final result =
|
final result =
|
||||||
await cat(['path/to/file'], stdout, showLineNumbers: true);
|
await cat(['path/to/file'], stdout, showLineNumbers: true);
|
||||||
if (result.exitCode == exitSuccess) { // or result.isSuccess
|
if (result.exitCode == exitSuccess) { // or result.isSuccess
|
||||||
...
|
// ...
|
||||||
} else {
|
} else {
|
||||||
for (final error in result.errors) {
|
for (final error in result.errors) {
|
||||||
stderr.writeln("Error with '${error.path}': ${error.message}");
|
stderr.writeln("Error with '${error.path}': ${error.message}");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
|
[View Full Example](https://github.com/ethauvin/dcat/blob/master/example/example.dart)
|
||||||
|
|
20
pubspec.lock
20
pubspec.lock
|
@ -7,14 +7,14 @@ packages:
|
||||||
name: _fe_analyzer_shared
|
name: _fe_analyzer_shared
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "29.0.0"
|
version: "34.0.0"
|
||||||
analyzer:
|
analyzer:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: analyzer
|
name: analyzer
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "2.6.0"
|
version: "3.2.0"
|
||||||
args:
|
args:
|
||||||
dependency: "direct main"
|
dependency: "direct main"
|
||||||
description:
|
description:
|
||||||
|
@ -70,7 +70,7 @@ packages:
|
||||||
name: coverage
|
name: coverage
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.0.3"
|
version: "1.1.0"
|
||||||
crypto:
|
crypto:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -189,7 +189,7 @@ packages:
|
||||||
name: path
|
name: path
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.8.0"
|
version: "1.8.1"
|
||||||
pool:
|
pool:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -252,7 +252,7 @@ packages:
|
||||||
name: source_span
|
name: source_span
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.8.1"
|
version: "1.8.2"
|
||||||
stack_trace:
|
stack_trace:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -287,21 +287,21 @@ packages:
|
||||||
name: test
|
name: test
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "1.19.0"
|
version: "1.20.1"
|
||||||
test_api:
|
test_api:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: test_api
|
name: test_api
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.4.6"
|
version: "0.4.9"
|
||||||
test_core:
|
test_core:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
name: test_core
|
name: test_core
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "0.4.6"
|
version: "0.4.11"
|
||||||
typed_data:
|
typed_data:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -315,7 +315,7 @@ packages:
|
||||||
name: vm_service
|
name: vm_service
|
||||||
url: "https://pub.dartlang.org"
|
url: "https://pub.dartlang.org"
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "7.3.0"
|
version: "8.1.0"
|
||||||
watcher:
|
watcher:
|
||||||
dependency: transitive
|
dependency: transitive
|
||||||
description:
|
description:
|
||||||
|
@ -345,4 +345,4 @@ packages:
|
||||||
source: hosted
|
source: hosted
|
||||||
version: "3.1.0"
|
version: "3.1.0"
|
||||||
sdks:
|
sdks:
|
||||||
dart: ">=2.14.3 <3.0.0"
|
dart: ">=2.15.1 <3.0.0"
|
||||||
|
|
|
@ -5,7 +5,7 @@ repository: https://github.com/ethauvin/dcat
|
||||||
issue_tracker: https://github.com/ethauvin/dcat/issues
|
issue_tracker: https://github.com/ethauvin/dcat/issues
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: '>=2.14.3 <3.0.0'
|
sdk: '>=2.15.1 <3.0.0'
|
||||||
|
|
||||||
dev_dependencies:
|
dev_dependencies:
|
||||||
lints: ^1.0.0
|
lints: ^1.0.0
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue