proj

Go to project on Github
This project is still in progress

Description

proj is a command line tool designed to make command line development more efficient. I live my life in the shell. proj is for everyone who, like me, believes that real development tools include only the shell, and maybe a nice editor like VSCode.

Commands

init

init initializes a new workspace. Subcommands are provided to initialize java and c++ projects specifically. New directories are created which are often used in projects, including folders for source code, tools, compiled binaries, external libraries, documentation, and so forth. It also creates a path modifier, allowing project tools to be used universally, and a language specific Makefile, which relies on the pre-generated tools in the tools directory to get work done.

This command also supplies the -g flag, allowing Github integration. proj local resources contain a Github OAuth token, allowing it to initialize a new repository remotely, as well as to locally. This integration will likely be done using Google's go-github library.

class

class creates and formats a new blank class file.

In c++ projects, this command creates a pair of files, a '.cpp' and a '.h'. In java and go projects, package names will be inferred and auto generated.

mv

This command moves files and directories while respecting references to that file/directory in other files. In java and go files, this includes respect to package names within files.

This move is also done with respect to git, so that files are 'moved' with respect to version control, instead of deleted and re-added. The real purpose for this is that I think the latter is messy, even though implementing the former method is a pain.

Other

This project, as well as its design, is still in progress. Other commands will be implemented as the need arises. To suggest new functionality, please make suggestions at the project issues page, or fork the project and make your own contribution!

Resources

~/.proj_config stores configurations for the proj tool, as well as resources needed for class generation. Later, command line integration may be added to enable config modification at execution time, but as is, configs can only be edited by modifying them directly withing the .proj_config folder.

This .proj_config resource file, contains sub-directories for each suported language. Each language defines a manifest.json, which declares which directories will be created, and which resource files will be copied upon initialization. The manifest references resource files based on their relative locaiton to the manifest.
Each Language also declares custom class file templates, which are used when executing the class command. They also define a messages.json which defines

Project Credits

Written in Go
Logging with the logrus package by sirupsen
Flags and subcommand management with the cobra package by spf13
Github integration planned to be done with go-github by Google