Skip to content

Commit

Permalink
Renamed "clone" to "acquire-repository"
Browse files Browse the repository at this point in the history
This commit implement issue #129
Renamed  "clone" to "acquire-repository" and logic of the command
remain the saime
README file also renamed "clone" to "acquire-repository"
  • Loading branch information
alexbeatnik committed May 22, 2019
1 parent 255e5e3 commit fdcc90a
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Executes [git elegant push](#push) after [git elegant rebase](#rebase).
### init
Creates an empty Git repository or reinitialize an existing one. Then runs local repository configuration.

### clone
### acquire-repository
Clone a repository into a new directory. Then runs local repository configuration.

### add
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/main/git-elegant-commands
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ default() {
echo "push-after-rebase"
echo "rebase"
echo "init"
echo "clone"
echo "acquire-repository"
echo "add"
echo "clear-local"
echo "configure"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ load addons-cd
load addons-fake

setup() {
fake-pass git clone
fake-pass git acquire-repository
fake-pass git "clone https://github.com/extsoft/elegant-git.git"
fake-pass git "elegant configure --local"
}
Expand All @@ -15,12 +15,12 @@ teardown() {
clean-fake
}

@test "'clone': raise an error if cloneable URL isn't set" {
check git-elegant clone
@test "'acquire-repository': raise an error if cloneable URL isn't set" {
check git-elegant acquire-repository
[[ "${lines[0]}" =~ "Cloneable URL is not set" ]]
}

@test "'clone': clone the repo" {
check git-elegant clone https://github.com/extsoft/elegant-git.git
@test "'acquire-repository': clone the repo" {
check git-elegant acquire-repository https://github.com/extsoft/elegant-git.git
[ "$status" -eq 0 ]
}
2 changes: 1 addition & 1 deletion src/test/git-elegant-commands.bats
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ teardown() {
[ "${lines[3]}" = "push-after-rebase" ]
[ "${lines[4]}" = "rebase" ]
[ "${lines[5]}" = "init" ]
[ "${lines[6]}" = "clone" ]
[ "${lines[6]}" = "acquire-repository" ]
[ "${lines[7]}" = "add" ]
[ "${lines[8]}" = "clear-local" ]
[ "${lines[9]}" = "configure" ]
Expand Down

0 comments on commit fdcc90a

Please sign in to comment.