clone

command module
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 2, 2024 License: MIT Imports: 7 Imported by: 0

README

clone 💾

[!Note] This is just a tiny convenience tool for when I'm cloning Gists and GitHub repos.

Installation

go install github.com/peterhellberg/clone@latest

Usage

clone -h

Usage of clone:
  -base string
    	The base directory to clone into (default "/home/peter/Code/GitHub")
  -name string
    	The name to use for the project, if blank use GitHub name

[!Tip] You can specify both the base directory where you keep your cloned repositories, as well as the name to use for the directory of the project being cloned.

clone -base=/tmp/repos -name=trooper git@github.com:peterhellberg/clone.git
Cloning into '/tmp/repos/peterhellberg/trooper'...
remote: Enumerating objects: 15, done.
remote: Counting objects: 100% (15/15), done.
remote: Compressing objects: 100% (11/11), done.
remote: Total 15 (delta 3), reused 15 (delta 3), pack-reused 0 (from 0)
Receiving objects: 100% (15/15), done.
Resolving deltas: 100% (3/3), done.

[!Important] You will get an error if there is already a directory

clone -name aisnake git@gist.github.com:124fb025981b9b167f942c39b87e6624.git
fatal: destination path '/home/peter/Code/GitHub/Gists/aisnake' already exists and is not an empty directory.
exit status 128

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL