<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Michael W. Aziz on Medium]]></title>
        <description><![CDATA[Stories by Michael W. Aziz on Medium]]></description>
        <link>https://medium.com/@micazi?source=rss-01035b47471e------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*fZcK5TzatCx4Un3f</url>
            <title>Stories by Michael W. Aziz on Medium</title>
            <link>https://medium.com/@micazi?source=rss-01035b47471e------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 19:05:14 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@micazi/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[You’re Starting Your New Flutter Project Wrong — There’s an Easier Way]]></title>
            <link>https://towardsdev.com/youre-starting-your-new-flutter-project-wrong-there-s-an-easier-way-59900c79d327?source=rss-01035b47471e------2</link>
            <guid isPermaLink="false">https://medium.com/p/59900c79d327</guid>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[flutter-template]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[developer-tools]]></category>
            <category><![CDATA[dart]]></category>
            <dc:creator><![CDATA[Michael W. Aziz]]></dc:creator>
            <pubDate>Mon, 02 Dec 2024 18:59:42 GMT</pubDate>
            <atom:updated>2024-12-03T20:52:15.620Z</atom:updated>
            <content:encoded><![CDATA[<h3>You’re Starting Your New Flutter Project Wrong — There’s an Easier Way</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0k5cdpEjAz9D-xu-bH_QMA.jpeg" /><figcaption>Image by <a href="https://www.pexels.com/@thisisengineering/">ThisIsEngineering</a> via Pexels</figcaption></figure><p>Setting up a new Flutter project can be such a chore: creating folders, setting up boilerplate code, and copying files over and over again. It’s a cycle most developers dread, but many of us just accept it as part of the process.<br>What if I told you that there was an easier way?<br>Say hello to FlutterTemplify — the tool that lets you skip the boilerplate and start your Flutter projects with a custom, ready-to-use structure.<br>Below is a guide on how you could make the creation of your Flutter project a breeze, fast, and efficient so you can dedicate yourself to the actual work- building your application.</p><h3>The Problem with Traditional Project Setup</h3><p>Every time you run flutter create, you start with the same generic folder structure:</p><ul><li>An empty lib/ folder.</li><li>A default main.dart.</li><li>Platform folders for Android, iOS, web, etc.</li></ul><p>Then comes the manual labor:</p><ol><li>Setting up your project structure — whether it’s TDD, MVVM, or MVP — can be a tedious and time-consuming task.</li><li>Adding boilerplate files like api_helper.dart or constants.dart.</li><li>Copying code snippets you’ve used a hundred times before.</li></ol><p>This repetitive setup not only wastes time but also risks inconsistencies between projects.</p><p><strong>There’s a better way.</strong></p><h3>Introducing flutter_templify</h3><p><strong>flutter_templify</strong> is a CLI tool designed to automate Flutter project setup. It lets you:</p><ul><li>Define your project structure and boilerplate code in a simple YAML file.</li><li>Create folders, files, and import reusable templates instantly.</li><li>Start your project with a structure tailored to your development workflow.</li></ul><p>With flutter_templify, you can build your Flutter projects the smart way.</p><h3>How to Get Started with flutter_templify</h3><h3>Step 1: Install the Tool</h3><p>First, install flutter_templify globally on your system:</p><pre>dart pub global activate flutter_templify</pre><p>This command makes it available in your terminal.</p><h3>Step 2: Create Your Template</h3><p>To customize your project setup, create a template.yaml file. Here’s an example:</p><pre>name: &quot;awesome-template&quot;<br>description: &quot;A basic template for MVP Flutter apps&quot;<br>domain: micazi.dev<br>platforms:<br>  - ios<br>  - android<br>  - web<br>structure:<br>  - lib/:  <br>    - screens/:  <br>        - home_screen.dart: ./boilerplates/home_screen.dart<br>        - profile_screen.dart<br>    - models/:<br>    - widgets/:<br>  - assets/:<br>    - images/<br>    - fonts/:<br>        - Roboto-Regular.ttf: ./boilerplates/fonts/Roboto-Regular.ttf<br>  - pubspec.yaml: ./boilerplates/pubspec.yaml<br>  - README.md: ./boilerplates/readme.md</pre><ul><li><strong>Folder creation</strong>: Defines folders like screens/ and models/.</li><li><strong>Boilerplate files</strong>: Copies reusable files (e.g., home_screen.dart) into your project.</li><li><strong>Custom files</strong>: Creates empty files like profile_screen.dart.</li></ul><h3>Step 3: Add your template to the local repo</h3><pre>flutter_templify templates add -f path/to/template.env</pre><p>And you can see all your defined templates with: flutter_templify templates ls</p><h3>Step 4: Generate a New Project</h3><p>Run the following command to create a Flutter project using your template:</p><pre>flutter_templify create my_project -t template.yaml</pre><p>What happens next?</p><ol><li>A new Flutter project is created with flutter create.</li><li>The custom folders and files you defined are added automatically.</li><li>Any boilerplate code is copied into the correct locations.</li></ol><h3>Step 5: Start Coding</h3><p>Navigate to your new project folder:</p><pre>cd my_project</pre><p>You’ll find the exact structure you defined, with all boilerplate code in place. No manual setup, no wasted time — just a ready-to-code project!</p><h3>Why You’re Doing It Wrong (And How to Do It Right)</h3><p>If you’re manually setting up each new Flutter project, you’re wasting time that could be spent coding. Here’s why flutter_templify is the better way:</p><ul><li>Consistency: Every project follows the same structure.</li><li>Speed: Automate repetitive tasks and get started in minutes.</li><li>Scalability: Share templates with your team for unified workflows.</li></ul><p>With flutter_templify, starting a Flutter project is as easy as running a single command.</p><h3>Powered by darted_cli</h3><p>flutter_templify is built on top of the robust and flexible darted_cli framework. darted_cli makes it easy to create structured, feature-rich command-line interfaces in Dart with minimal effort.</p><p>Why darted_cli?</p><ul><li>Provides a strong foundation for parsing commands, arguments, and flags.</li><li>Simplifies CLI development with tools like interactive prompts, formatted console outputs, and custom error handling.</li><li>Focused on developer experience, ensuring easy scalability and customization.</li></ul><p>Explore <a href="https://pub.dev/packages/darted_cli">darted_cli</a> to learn how you can build your own powerful CLI tools with Dart!</p><h3>Get Started Today</h3><p>flutter_templify is free and open source. Install it now, create your first template, and transform the way you build Flutter apps.</p><p>Explore flutter_templify on <a href="https://pub.dev/packages/flutter_templify">pub.dev</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=59900c79d327" width="1" height="1" alt=""><hr><p><a href="https://towardsdev.com/youre-starting-your-new-flutter-project-wrong-there-s-an-easier-way-59900c79d327">You’re Starting Your New Flutter Project Wrong — There’s an Easier Way</a> was originally published in <a href="https://towardsdev.com/">Towards Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Here’s What I Built with darted_cli: Meet flutter_loc ]]></title>
            <link>https://towardsdev.com/heres-what-i-built-with-darted-cli-meet-flutter-loc-0cbb33c1138d?source=rss-01035b47471e------2</link>
            <guid isPermaLink="false">https://medium.com/p/0cbb33c1138d</guid>
            <category><![CDATA[developer-tools]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[dart]]></category>
            <category><![CDATA[localization]]></category>
            <dc:creator><![CDATA[Michael W. Aziz]]></dc:creator>
            <pubDate>Thu, 21 Nov 2024 14:26:11 GMT</pubDate>
            <atom:updated>2024-11-22T14:36:20.757Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1002/1*rNgGS0b-Qwr0XsX8Pb3NrQ.png" /></figure><p>As developers, we often face repetitive challenges. One of these is managing hardcoded strings in Flutter apps, especially when preparing for localization. That’s why I built <strong>flutter_loc</strong>, a command-line tool that identifies hardcoded strings in Flutter apps, extracts them for localization, and even replaces them with a structured localization approach.</p><p>But here’s the twist — <strong>I built </strong><strong>flutter_loc using my Dart CLI framework, </strong><strong>darted_cli</strong>. Let me show you how this powerful package made the process seamless.</p><h3>The Problem</h3><p>Localization can be tedious, especially in large projects. Hunting down hardcoded strings, exporting them to a file, and replacing them with localized versions is time-consuming and error-prone. Flutter’s localization tools are great, but preparing your codebase for them can feel overwhelming.</p><p>I wanted a tool that could:</p><ol><li><strong>Extract hardcoded strings</strong> from Dart files.</li><li><strong>Export the strings</strong> to a file for translation.</li><li><strong>Replace the hardcoded strings</strong> with localization-friendly ones.</li><li><strong>Generate JSON files</strong> for supported languages.</li></ol><p>That’s where flutter_loc comes in.</p><h3>Building flutter_loc with darted_cli</h3><p>At its core, flutter_loc uses darted_cli to define its commands, arguments, and flags. Here&#39;s how I leveraged darted_cli to make it happen:</p><h4>Commands Tree</h4><p>flutter_loc has two main commands:</p><ul><li><strong>extract</strong>: Scans Dart files for hardcoded strings and exports them to a file.</li><li><strong>replace</strong>: Replaces the hardcoded strings with localized ones and generates JSON files for translations.</li></ul><p>With darted_cli, defining this structure is straightforward:</p><pre>List&lt;DartedCommand&gt; commandsTree = [  <br>  DartedCommand(  <br>    name: &#39;extract&#39;,  <br>    helperDescription: &quot;Extract potential hardcoded strings.&quot;,  <br>    arguments: [  <br>      DartedArgument(name: &#39;directory&#39;, abbreviation: &#39;d&#39;, defaultValue: &#39;lib&#39;),  <br>    ],  <br>    callback: (args, flags) async =&gt; await extractCallback(args, flags),  <br>  ),  <br>  DartedCommand(  <br>    name: &#39;replace&#39;,  <br>    helperDescription: &quot;Replace hardcoded strings with localized versions.&quot;,  <br>    arguments: [  <br>      DartedArgument(name: &#39;path&#39;, abbreviation: &#39;p&#39;, defaultValue: &#39;flutter_loc.txt&#39;),  <br>      DartedArgument(name: &#39;languages&#39;, abbreviation: &#39;l&#39;, isMultiOption: true, optionsSeparator: &#39;,&#39;),  <br>      DartedArgument(name: &#39;main-language&#39;, abbreviation: &#39;m&#39;, defaultValue: &#39;en&#39;),  <br>    ],  <br>    flags: [  <br>      DartedFlag(name: &#39;generate-json&#39;, abbreviation: &#39;j&#39;, appliedByDefault: true),  <br>    ],  <br>    callback: (args, flags) async =&gt; await replaceCallback(args, flags),  <br>  ),  <br>];</pre><h4>Command Execution</h4><p>The extract command scans Dart files in the specified directory using regex to identify hardcoded strings. It exports these strings to a file in this format:</p><pre>##PATH  <br>(file_path.dart)  <br>#  <br>[line_number] &quot;hardcoded string&quot; =&gt; &#39;&#39;;<br>[line_number] &quot;hardcoded string2&quot; =&gt; &#39;&#39;;<br>#<br>#!PATH<br><br>##PATH<br>(file2_path.dart)<br>#<br>[line_number] &quot;hardcoded string3&quot; =&gt; &#39;&#39;;<br>#<br>#!PATH</pre><p>This is all handled in the extractCallback function:</p><pre>Future extractCallback(Map&lt;String, dynamic&gt;? args, Map&lt;String, bool&gt;? flags) async {  <br> // Define the directory to look in...<br>  Directory directory = Directory(args?[&#39;directory&#39;] ?? args?[&#39;d&#39;] ?? &#39;lib&#39;);<br><br>  // Change into that directory<br>  await IOHelper.directory.change(directory.path);<br><br>  // Get the new pwd<br>  String wd = IOHelper.directory.getCurrent();<br><br>  // Find all the hardcoded strings...<br>  Map&lt;String, List&lt;(int, String)&gt;&gt; finds = {};<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Searching files for hardcoded strings...&#39;,<br>    process: () =&gt; IOHelper.file.search(<br>      wd,<br>      RegExp(&#39;[&quot;\&#39;](.*?)[&quot;\&#39;]&#39;),<br>      excluded: [RegExp(&#39;commands_tree.dart&#39;), RegExp(&#39;flutter_loc.txt&#39;)],<br>    ).then((v) =&gt; finds = v),<br>  );<br><br>  // Refinements on the search results...<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Doing refinements on the extracted lines...&#39;,<br>    process: () async {<br>      return await Future.forEach(refinements, (r) async {<br>        finds = await r(finds);<br>      });<br>    },<br>  );<br><br>  // Combine the refined data into a string...<br>  String hardcodedStrings = finds.entries<br>          .map((map) =&gt;<br>              &quot;##PATH\n(${map.key})\n#\n${map.value.map((e) =&gt; &quot;[${e.$1}] ${RegExp(&#39;[&quot;\&#39;](.*?)[&quot;\&#39;]&#39;).hasMatch(e.$2) ? RegExp(&#39;[&quot;\&#39;](.*?)[&quot;\&#39;]&#39;).firstMatch(e.$2)?.group(0) : &#39;N/A&#39;} =&gt; &#39;&#39;;&quot;).toList().reduceIfNotEmpty((aa, bb) =&gt; &quot;$aa\n$bb&quot;) ?? []}&quot;)<br>          .toList()<br>          .reduceIfNotEmpty(<br>            (p1, p2) =&gt; &quot;$p1\n#\n#!PATH\n\n$p2&quot;,<br>          ) ??<br>      &#39;&#39;;<br><br>  // Export the refined data to an external file...<br>  File outputFile = File(&#39;flutter_loc.txt&#39;);<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Generating flutter_loc file...&#39;,<br>    process: () =&gt; outputFile.writeAsString(hardcodedStrings),<br>  );<br>}</pre><h4>Replacing Strings</h4><p>The replace command reads the extracted data, replaces hardcoded strings in the original files, and generates localization files (en.json, es.json, etc.).</p><pre>replaceCallback(Map&lt;String, dynamic&gt;? args, Map&lt;String, bool&gt;? flags) async {  <br>  // Read the flutter_loc file...<br>  File flutterLocFile = File(args?[&#39;path&#39;] ?? args?[&#39;p&#39;] ?? &#39;flutter_loc.txt&#39;);<br><br>  // Check file existance...<br>  if (!await flutterLocFile.exists()) {<br>    throw FileDoesntExist(path: args?[&#39;path&#39;] ?? args?[&#39;p&#39;] ?? &#39;flutter_loc.txt&#39;);<br>  }<br><br>  // Get the content of the file...<br>  String fileData = &#39;&#39;;<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Reading flutter_loc file...&#39;,<br>    process: () =&gt; flutterLocFile.readAsString().then((v) =&gt; fileData = v),<br>  );<br><br>  // Parse the file data to a map.<br>  Map&lt;String, List&lt;(int line, String hardString, String replacementString)&gt;&gt; parsedMap = {};<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Parsing file content...&#39;,<br>    process: () async =&gt; await parseFileContent(fileData).then((v) =&gt; parsedMap = v),<br>  );<br><br>  // Replace all the parsed data.<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Replacing the hard-coded strings with the provided replacements...&#39;,<br>    process: () async =&gt; await replaceFileContent(parsedMap),<br>  );<br><br>  // Get the desired language files.<br>  List&lt;String&gt; langs = (args?[&#39;languages&#39;] ?? args?[&#39;l&#39;])?.toString().split(&#39;,&#39;) ?? [&#39;en&#39;];<br>  String mainLang = (args?[&#39;main-language&#39;] ?? args?[&#39;m&#39;]) ?? &#39;en&#39;;<br><br>  // Generate the l10n files<br>  await ConsoleHelper.loadWithTask(<br>    task: &#39;Generating l10n files...&#39;,<br>    process: () async =&gt; await generateLangFiles(flutterLocFile.parent.path, parsedMap, langs, mainLang),<br>  );<br>}</pre><h3>The Result</h3><p>With flutter_loc, you can easily:</p><p><strong>1. Extract:</strong> Extract all hardcoded strings with flutter_loc extract -d lib.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Y4tJ5Lqkx6UdnvyxnC_ZSg.gif" /><figcaption>extracting hard-coded strings in a project directory</figcaption></figure><p><strong>2. Review &amp; Localize:</strong> Check all of the extracted hard-coded strings and supply the localization handlers for them.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_avPlUfNLjEyOz_B7y8a_A.png" /><figcaption>flutter_loc.txt file after extracting</figcaption></figure><p><strong>3. Replace &amp; Generate:</strong> Easily replace all of the reviewed strings and conveniently generate .json files for the interpretations!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DraSubxqxbJO_Gm2DgLLTw.gif" /><figcaption>generating the localization json files</figcaption></figure><p><strong>And just like that,</strong> you have your l10n files and your hard-coded strings are replaced!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eOCTUTkXMdTvHkhpVWMLEQ.png" /><figcaption>l10n json files</figcaption></figure><p>It’s simple, efficient, and ready to make your Flutter projects localization-friendly.</p><h3>Why darted_cli Was Perfect for This</h3><p>Building flutter_loc with darted_cli allowed me to focus on the functionality instead of boilerplate. Here’s how:</p><ol><li><strong>Command Parsing Made Easy</strong>: No manual parsing — just define commands, arguments, and flags, and darted_cli takes care of the rest.</li><li><strong>Task-Based Feedback</strong>: Progress messages (e.g., “Searching files for hardcoded strings…”) make the tool more user-friendly.</li><li><strong>Modular Structure</strong>: Commands and their logic are modular, making the codebase maintainable and extensible.</li></ol><h3>Try darted_cli for Your CLI Projects</h3><p>flutter_loc is just one example of what you can build with darted_cli. Whether you’re automating workflows or creating developer tools, darted_cli makes it easy to bring your ideas to life.</p><p>Check out darted_cli on <a href="https://pub.dev/packages/darted_cli">Pub</a>, and start building your next CLI tool today!</p><h3>Your Turn</h3><p>Have ideas for other developer tools? Try building them with darted_cli and see how far you can go. Share your creations—I’d love to see what you build! 🚀</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0cbb33c1138d" width="1" height="1" alt=""><hr><p><a href="https://towardsdev.com/heres-what-i-built-with-darted-cli-meet-flutter-loc-0cbb33c1138d">Here’s What I Built with darted_cli: Meet flutter_loc 🚀</a> was originally published in <a href="https://towardsdev.com/">Towards Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building darted_cli: Empowering Developers to Create Stellar CLI Tools in Dart]]></title>
            <link>https://towardsdev.com/building-darted-cli-empowering-developers-to-create-stellar-cli-tools-in-dart-f3b3195eca05?source=rss-01035b47471e------2</link>
            <guid isPermaLink="false">https://medium.com/p/f3b3195eca05</guid>
            <category><![CDATA[command-line]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[developer-tools]]></category>
            <category><![CDATA[dart]]></category>
            <category><![CDATA[open-source]]></category>
            <dc:creator><![CDATA[Michael W. Aziz]]></dc:creator>
            <pubDate>Sun, 17 Nov 2024 14:43:43 GMT</pubDate>
            <atom:updated>2024-11-22T14:36:31.515Z</atom:updated>
            <content:encoded><![CDATA[<p><strong>Ever found yourself tangled in the complexities of building command-line tools?</strong> Same here. That’s why I built <strong>darted_cli</strong>, a developer-first package designed to make building CLI tools in Dart not just manageable—but downright fun.</p><p>Whether you’re creating a simple utility tool or a sophisticated CLI interface, darted_cli is here to streamline the process. But before we dive into what it can do, let me take you behind the scenes of why I developed it in the first place.</p><h3>The “Aha!” Moment</h3><p>A few months ago, I was working on a Dart-based CLI for automating repetitive tasks. After dealing with clunky argument parsing, error-prone command validation, and formatting console outputs, I knew there had to be a better way.</p><p>So, I decided to roll up my sleeves and create something that would:</p><ol><li><strong>Simplify CLI Development</strong>: No boilerplate code — just focus on your commands and logic.</li><li><strong>Be Intuitive for Developers</strong>: It should feel natural to use, with developer-friendly error messages and customization.</li><li><strong>Empower Creativity</strong>: From ASCII art headers to customizable console responses, I wanted developers to have fun while building.</li></ol><p>And just like that, darted_cli was born. 🚀</p><figure><img alt="Executing your_awesome_package that was built using darted_cli" src="https://cdn-images-1.medium.com/max/1024/1*AmFSVgMqCab1E0631FrfuA.gif" /><figcaption>Executing <strong>your_awesome_package</strong></figcaption></figure><h3>What Makes darted_cli Special?</h3><p>Here’s what sets darted_cli apart from the rest:</p><h4>Command Tree Validation</h4><p>No more struggling with parent-child relationships in commands. darted_cli validates your command hierarchy automatically.</p><h4>Effortless Argument &amp; Flag Parsing</h4><p>Define your arguments, add default values, and handle flags with ease — even support for negations like --no-flag.</p><pre>dart run my_package create - name project_name -p android,ios --package --no-solo</pre><p>Results in:</p><pre>Command: create<br>Arguments: { name: project_name, platforms: [android, ios] }<br>Flags: { package: true, solo: false}</pre><h4>Built-In Customization</h4><p>Want to customize the --help or --version output? Go ahead. Want ASCII art? Add it. Interactive prompts? You bet.</p><pre>customHelpResponse: () =&gt; &#39;Custom response for the -h flag!&#39;<br>  .withColor(ConsoleColor.cyan),</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*46ZB5XkD_Mn945bJr7hD_w.gif" /><figcaption>Customizing the help/entry responses of <strong>your_awesome_package</strong> using <strong>darted_cli</strong></figcaption></figure><h4>Developer-Centric Helpers</h4><p>From handling file I/O to adding animated loaders, darted_cli provides all the tools you need to take your CLI game to the next level.</p><h3>How to Get Started with darted_cli</h3><h4>Step 1: Install the Package</h4><p>Add the latest version of darted_cli to your pubspec.yaml file and run:</p><pre>dart pub get</pre><h4>Step 2: Define Your Commands</h4><p>Set up your command tree with arguments, flags, and callbacks:</p><pre>final commandsTree = [<br>  DartedCommand(<br>    name: &#39;create&#39;,<br>    helperDescription: &#39;Creates a new project.&#39;,<br>    arguments: [<br>      DartedArgument(name: &#39;name&#39;, abbreviation: &#39;n&#39;, defaultValue: &#39;new_project&#39;),<br>    ],<br>    flags: [DartedFlag.help],<br>    callback: (arguments, flags) =&gt; ConsoleHelper.write(<br>      &#39;Creating project: ${arguments[&#39;name&#39;]}&#39;,<br>    ),<br>  ),<br>];</pre><h4>Step 3: Create Your Entry Point</h4><p>Add a dartedEntry in your main function:</p><pre>void main(List&lt;String&gt; input) async =&gt;<br>  await dartedEntry(<br>    input: input,<br>    commandsTree: commandsTree,<br>    customHelpResponse: () =&gt; &#39;Need help? Here it is!&#39;<br>        .withColor(ConsoleColor.green),<br>  );<br></pre><p>And boom, your CLI tool is ready to run.</p><pre>dart run my_awesome_package create --name &quot;awesome_cli&quot;</pre><h3>Behind the Scenes</h3><p>Creating darted_cli wasn’t all smooth sailing. There were a few challenges along the way:</p><ol><li><strong>Balancing Simplicity and Power</strong><br>I wanted darted_cli to be simple enough for beginners yet flexible enough for complex use cases. Finding this balance required extensive testing and feedback.</li><li><strong>Extensibility</strong><br>I wanted to ensure developers could extend the package to fit their needs without being locked into rigid structures.</li><li><strong>Interactive Developer Experience</strong><br>Adding features like ASCII art, interactive prompts, and colorful outputs was tricky — but ultimately rewarding.</li></ol><h3>Why Should You Use darted_cli?</h3><ul><li><strong>Save Time</strong>: Stop reinventing the wheel for every CLI tool.</li><li><strong>Focus on Logic</strong>: Forget boilerplate code — just define your commands and callbacks.</li><li><strong>Build with Confidence</strong>: The package handles validation, parsing, and more, so you can trust your tool to work.</li></ul><h3>Future Plans</h3><p>darted_cli is already feature-packed, but there’s always room for growth. Here’s what’s next:</p><ul><li>🚀 More animated loaders.</li><li>🛠️ Extended YAML support for configuration-heavy CLI tools.</li><li>🤝 Community-contributed commands and helpers.</li></ul><h3>Try darted_cli Today!</h3><p>Head over to the pub.dev page and give it a spin. I’d love to hear your thoughts, feedback, and suggestions for improvement.</p><p>Let’s build something awesome, one CLI tool at a time! 🚀</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*RuqdrhoZWbUOkjAsY9msnQ.jpeg" /><figcaption><strong>darted_cli</strong> written with ASCII art.</figcaption></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f3b3195eca05" width="1" height="1" alt=""><hr><p><a href="https://towardsdev.com/building-darted-cli-empowering-developers-to-create-stellar-cli-tools-in-dart-f3b3195eca05">Building darted_cli: Empowering Developers to Create Stellar CLI Tools in Dart</a> was originally published in <a href="https://towardsdev.com/">Towards Dev</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>