Gitlab to Github 미러링

Jsleemaster·2023년 3월 15일
0

Gitlab

목록 보기
1/1
post-thumbnail
  1. gitlab의 bare clone을 생성
    git clone --bare https://gitlab.com/example/old-repository.git
    cd old-repository.git
  2. mirror push
    git push --mirror https://github.com/example/new-repository.git

100MB이상 크기의 파일

  1. git lfs와 BFG Repo Cleaner 설치
  2. gitlab의 bare clone을 생성
    git clone --mirror <https://gitlab.com/exampleuser/old-repository.git>
    cd old-repository.git
  3. 해당 폴더에서 아래 명령어 실행 (해당 폴더에 bfs.jar 파일이 있어야 함)
    1. git lfs install
    2. git filter-branch --tree-filter 'git lfs track "*.{zip,jar}"' -- --all
    3. java -jar bfg-1.14.0.jar -b 100M
    4. git push --mirror https://github.com/example/new-repository.git
profile
문제 기록 블로그

0개의 댓글