An Interactive CLI Tool to Setup Your Project Trees
MIT License
mkproj
is a simple and effective command-line interface (CLI) tool designed to help developers quickly create, visualize, and manage their project structures. With an intuitive interactive mode and flexible commands, mkproj
provides a fast way to organize your project files and folders.
Interactive Mode | Interactive Mode output |
---|---|
mkproj
is available on Homebrew for macOS and can be installed from source for other platforms.
To install mkproj
on macOS using Homebrew, run:
brew tap jobehi/mkproj
brew install mkproj
For other platforms, you can download and build the binary from the source code repository.
mkproj [command] [options]
--root=<path>
: Specify the root directory for your project structure (default is the current directory).--file=<path>
: Provide a file that contains the project structure (used with create
).By default, mkproj
starts in interactive mode, where you can manually build your project structure:
Start in Interactive Mode:
mkproj
This launches mkproj
in an interactive environment where you can create and edit your project structure on the fly.
Create a Project Structure from a Text File:
mkproj create --file=structure.txt --root=./new_project
This command reads the project structure from structure.txt
and creates it in the specified root directory.
Display the Current Directory Tree:
mkproj tree --root=./my_project
Displays the directory structure of ./my_project
without showing hidden files.
Display the Directory Tree Including Hidden Files:
mkproj tree --root=./my_project --all
Displays the directory tree of ./my_project
, including hidden files.
The input structure can be created interactively or provided as a text file. You can use dashes (-
) for depth and suffix :file
to mark an entry as a file (for files with no extensions). For example:
project-root
- src
-- main.go
-- utils
--- helper.go
- README.md
- .gitignore:file
To set up mkproj
globally on macOS from the source code, follow these steps:
Clone the Repository:
git clone https://github.com/jobehi/mkproj.git
cd mkproj
Build the Binary:
Build the mkproj
binary using Go:
go build -o mkproj
Move the Binary to /usr/local/bin
:
Move the compiled binary to /usr/local/bin
to make it accessible globally:
sudo mv mkproj /usr/local/bin/
sudo chmod +x /usr/local/bin/mkproj
Verify Installation:
You can now use mkproj
from anywhere in your terminal:
mkproj help
Contributions are welcome! Please open an issue or a pull request on the GitHub repository to report bugs or suggest improvements. Refer to the Contributing Guidelines for more information.
mkproj
is released under the MIT License.