Giter VIP home page Giter VIP logo

cocmd's Introduction

Rust CI Starter

A Rust template project that gets you:

  • A CLI skeletons for a CLI with subcommands or flat, or a library
  • CI and CD (releases) with lint, testing, and coverage with Codecov
  • Developer workflow based on xtask
  • A good base linting configuration, popular libraries (which you can remove), and insta for tests.

Getting started

Clone the project or use a tool like backpack to kickstart a new project:

$ brew tap rusty-ferris-club/tap && brew install backpack
$ bp new rusty-ferris-club/rust-starter my-project

Then take an approach of removing what you don't need:

`cocmd/` - a CLI with subcommands, based on clap
`cocmd_simpler/` - a CLI with a simple flat structure, based on clap
`cocmd_lib/` - a library-only starter project, with minimal dependencies

Once that's done you can update cargo.toml and remove crates from the workspace.

Run build to see that you're ready to start:

cargo build

Personalising

Find where cocmd is and replace it with the name of your project. $ rg cocmd, find . | grep cocmd. Find which variables you need to swap. $ rg __V_, $ rg __v_.

Update all snapshots:

$ cargo insta test

And then

$ cargo insta review

README.md

If you like, you can replace this file with a README from the sub-crates:

Workflow

Workflow for your future project is based on xtask.

Install the helper cargo tools with:

$ cargo xtask install

Build

$ cargo build

or, for full build suite with tests:

$ cargo xtask ci

Coverage

$ cargo xtask coverage [--dev]

Docs

$ cargo xtask docs

Release

Set up your release.yml, replace the project names and repo locations.

Then to release new versions:

  • Update cargo.toml version.
  • git tag v[your-new-version]
  • push the new tag

Your Github Action CI workflow should release a new version.

cocmd's People

Contributors

mzsrtgzr2 avatar knightpath avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.