Skip to content

Instantly share code, notes, and snippets.

@kafeltz
Created August 23, 2019 14:03
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kafeltz/cc1ccb82bc0301f6ef7f72cf01221cb1 to your computer and use it in GitHub Desktop.
Save kafeltz/cc1ccb82bc0301f6ef7f72cf01221cb1 to your computer and use it in GitHub Desktop.
Procedimento pra migrar do Mercurial pro Git
Criar o dockerfile abaixo
-----------------------------------------------------------
FROM ubuntu:latest
RUN apt-get update \
&& apt-get install -y \
&& apt-get install ssh -y \
&& apt-get install mercurial -y \
&& apt-get install git -y
WORKDIR /usr/src/app
RUN git clone https://github.com/frej/fast-export.git \
# https://github.com/frej/fast-export/issues/132
&& cd fast-export \
&& git checkout tags/v180317
-----------------------------------------------------------
Criar um repo novo no bitbucket com git antes de fazer qualquer procedimento.
Estar no mesmo diretório do Dockerfile:
$ docker build -t linux .
$ docker run -it linux /bin/bash
Dentro do container:
$ mkdir repo-temporario
$ cd repo-temporario
$ git init
$ python ../fast-export/hg-fast-export.py -r ../app/pagueveloz/
$ git checkout HEAD
$ git remote add origin git@bitbucket.org:bludata/pagueveloz-git.git
$ git push --all
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment