パッケージ、リポジトリ、アプリカテゴリを検索

パッケージ詳細v2.16.0

cli_pkg

Dart CLI パッケージをリリースするための Grinder タスク。

macOSWindowsLinux
30日間ダウンロード
7.6万
いいね数
23
Pub ポイント
110

パッケージをインストール

flutter pub add cli_pkg

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

cli_pkg は、コマンドラインインターフェース(CLI)パッケージのリリースプロセスを簡素化することを目的としたDartパッケージです。バージョン管理、テスト、リリースノートの生成など、一般的な公開ワークフローを自動化するGrinderタスクを提供しています。sass-lang.comによって開発され、GitHubにホストされており、macOS、Windows、Linuxをサポートしており、クロスプラットフォームのCLIツールを維持している開発者にとって理想的です。FlutterおよびDartエコシステムとシームレスに統合され、パッケージリリース時の手作業を削減します。

用途

  • CLIパッケージリリースの自動化
  • CLI プロジェクトでのバージョン管理
  • リリースノートの生成
  • クロスプラットフォーム CLI 開発
  • CI/CDパイプラインの最適化

主な機能

  • 事前定義された Grinder タスク
  • バージョンアップの自動化
  • リリースノートの生成
  • クロスプラットフォーム対応
  • Dart pub との統合

適している対象

  • Dart CLI ツールのメンテナス
  • オープンソースパッケージ公開者
  • CI/CDパイプライン統合ツール
  • Grinder を使用する開発者
  • 頻繁なリリースを管理するチーム

注意事項

  • グラインダーのセットアップが必要です
  • CLI パッケージワークフローに限定
  • リリースワークフローにGitHubに依存
  • 非CLIパッケージには適していません
  • カスタムリリースロジック用に手動設定が必要

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

Dart CLI Packager

This package provides a set of Grinder tasks that make it easy to release a Dart command-line application on many different release channels, to Dart users and non-Dart users alike. It also integrates with Travis CI to make it easy to automatically deploy packages.

To use this package, import package:cli_pkg/cli_pkg.dart and call pkg.addAllTasks() before calling grind():

import 'package:cli_pkg/cli_pkg.dart' as pkg;
import 'package:grinder/grinder.dart';

void main(List<String> args) {
  pkg.addAllTasks();
  grind(args);
}

The following sets of tasks are provided, each of which can also be enabled individually:

It's strongly recommended that this package be imported with the prefix pkg.

Configuration

This package is highly configurable, using ConfigVariable fields defined at the top level of the library. By default, it infers as much configuration as possible from the package's pubspec, but almost all properties can be overridden in the main() method:

import 'package:cli_pkg/cli_pkg.dart' as pkg;
import 'package:grinder/grinder.dart';

void main(List<String> args) {
  pkg.name.value = "bot-name";
  pkg.humanName.value = "My App";

  pkg.addAllTasks();
  grind(args);
}

ConfigVariables whose values are expensive to compute or that might fail under some circumstances can also be set to callback functions, which are called lazily when the variables are used by the Grinder tasks:

import 'package:cli_pkg/cli_pkg.dart' as pkg;
import 'package:grinder/grinder.dart';

void main(List<String> args) {
  pkg.githubReleaseNotes.fn = () => File.read("RELNOTES.md");

  pkg.addAllTasks();
  grind(args);
}

Each task describes exactly which configuration variables it uses. Configuration that just applies to one set of tasks is always prefixed with a corresponding name. For example, pkg.jsFlags applies to JavaScript compilation.

カテゴリー

依存関係

依存関係一覧 25 件

ソースリポジトリ

このパッケージを使用しているプロジェクト