Coder Social home page Coder Social logo

cpp-cli's Introduction

C++ CLI

CLI for C++ projects by Jeremy Junac

Prerequisites

The CLI only needs Python 2.7. But if you want to use all the functionalities, you will also need :

  • make
  • gcc/g++
  • gdb
  • VSCode

Installation

git clone https://github.com/Taken0711/cpp-cli.git

If you want to use the CLI from anywhere, you can put a link in your $PATH (assuming that ~/bin is in your $PATH):

ln -s ./cpp-cli.py ~/bin/cpp-cli

Usage

Generating a new project with Makefile and VSCode settings files

cpp-cli new <PROJECT-NAME>

This command generates a project containing :

  • A basic main with a cout.
  • Its Makefile.
  • The .json settings files for vscode (settings.json, launch.json, c_cpp_properties.json and tasks.json) to build, debug and launch your project, using make, gcc and gdb.

Generating Class

You can use the cpp-cli g class command to generate C++ classes:

cpp-cli g class <MyClass>

Note : the PATH must be your newly created project.

This command creates a basic cpp and a header file. The CLI will automatically add dependency in the Makefile.
You can also create several classes in one command:

cpp-cli g class MyFirstClass MySecondClass MyThirdClass

VSCode shortcuts

Building

Default is Ctrl+B.
Debugging and launching automatically launch the build task.

Debugging

Default is F5.
Automatically launches the build task.

Launching without debug

Default is Ctrl+F5.
Automatically launches the build task.

cpp-cli's People

Contributors

jjunac avatar joelcancela avatar

Watchers

 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.