hacknow-0.1.0 is not a library.
HackNow
Utility for automation of project directories and switching workspaces based on the GitHub directory structure - User/Project
This is a RIIR for fun of mraerino/hacknow.
Functionality
- Directory structure:
<projects-dir>/<user>/<repo> - Checks if a directory for the specified repo exists
- No: Clones github repo into new directory
- Yes: Does
git fetch --allfor this repo - Then changes into the project directory
Getting started
This is available on cargo:
`cargo install hacknow``
Shell function
If you want your shell to switch into the project directory, you need to create a small function inside your shell config (.bashrc, .zshrc or similar)
Choose a different alias if hn doesn't work for you.
Please note: On failure hacknow will echo just . to stdout, so it should be safe to call cd on it in every situation.
Usage
Options
-d|--dir <dir> Choose base directory for your projects (default: $HOME)
--ssh Use ssh protocol for git remote
Examples
Ideas / Roadmap
- Bash completion
- Execute scripts inside project directory (like
nvm,virtualenv,yarn install, IDE launch...)