From 8c6672728db4d8ec2d11d03ab6ce8055c5061b8a Mon Sep 17 00:00:00 2001 From: lroche <1540492+lroche@users.noreply.github.com> Date: Mon, 12 Mar 2018 15:43:53 +0100 Subject: [PATCH] project name is now optional --- README.md | 5 +++++ hg2git.sh | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/README.md b/README.md index 47dc68f..34cf45b 100644 --- a/README.md +++ b/README.md @@ -6,6 +6,11 @@ All mechanism of conversion is based on [fast-export](https://github.com/frej/fa # Launch conversion docker run -it -v ~/anyproject-hg:/work/projectname -v ~/project-result-git:/work/result lroche/hg2git projectname + +or if you don't want to specifiy projectname: + + docker run -it -v ~/anyproject-hg:/work/project -v ~/project-result-git:/work/result lroche/hg2git + the run uses two bound volumes, one for hg source, other for git target result. the name of project has no matter but it will be the same between /work/projectname and the argument of the command (here projectname) diff --git a/hg2git.sh b/hg2git.sh index 44a1980..3d96838 100644 --- a/hg2git.sh +++ b/hg2git.sh @@ -1,6 +1,10 @@ #!/bin/bash PROJECT_NAME=$1 +if [ $PROJECT_NAME -eq ""]; +then + PROJECT_NAME="project" +fi cd /work/result mkdir -p $PROJECT_NAME-git