https://github.com/insign/dart_dpp
A better dart pub publish. Before publish, runs tests, fixes, lint, updates CHANGELOG, pubspec file and git commands.
https://github.com/insign/dart_dpp
dart
Last synced: 10 months ago
JSON representation
A better dart pub publish. Before publish, runs tests, fixes, lint, updates CHANGELOG, pubspec file and git commands.
- Host: GitHub
- URL: https://github.com/insign/dart_dpp
- Owner: insign
- License: bsd-3-clause
- Created: 2023-02-19T01:43:08.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-05-13T18:13:31.000Z (about 2 years ago)
- Last Synced: 2024-11-16T13:09:22.223Z (over 1 year ago)
- Topics: dart
- Language: Dart
- Homepage: https://pub.dev/packages/dpp
- Size: 33.2 KB
- Stars: 5
- Watchers: 1
- Forks: 0
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# dpp
A better dart pub publish, by running tests, fixes, lint, update CHANGELOG file and git commands.
## Installing globally as CLI
```dart
dart pub global activate dpp
```
> If you receive a "Warning" just follow the instructions and reopen the console. If you need more help visit [Running a script from your PATH](https://dart.dev/tools/pub/cmd/pub-global#running-a-script-from-your-path).
>
> If you don't want to change your precious PATH, [go horse](https://gohorseprocess.com.br/extreme-go-horse-xgh/), just run `dart pub global run dpp`
## Simple CLI usage
```bash
dpp <1.2.3|patch|minor|major> [optional commit/changelog message]
```
Examples:
```bash
dpp 1.0.1 Typo fix
```
```bash
dpp minor New great feature # version will be 1.1.0
```
```bash
dpp major Rewritten code from Rust to Dart # 2.0.0
```
Simple run `dpp` to see all flags available.
>ProTip: create an alias "pp" with your default flags. If my standard do not fits for you. E.g. put the following in you bashrc/zshrc: `alias pp="dpp --no-git --no-tests"`
## Using internaly in only one project
```bash
dart pub add dev:dpp # dev: means you will use only in development
```
```dart
void main() {
final pubPublisher = DartPubPublish(git: false);
// Publish a new version with default message
pubPublisher.run('1.2.1'); // default message: 'Update version number'
// Publish a new version with a changelog message
pubPublisher.run('minor', message: 'Added a new feature');
print('Package published!');
}
```
## LICENSE
[BSD 3-Clause License](./LICENSE)
## CONTRIBUTE
If you have an idea for a new feature or have found a bug, just do a pull request (PR).