[Other doc versions]
[Doc downloads (PDF, HTML, XML)]
新しいリポジトリを作成すると、既存のプロジェクトから Stash をインポートできます。これを行うには、最初にリポジトリをローカルのコンピューターへ複製してから、空の Stash リポジトリへプッシュします。
このページの内容
If you have code on your local machine that is not under source control, you can put it under source control and import it into Stash. To do this:
Initialise the project by running the following commands in the terminal:
git init git add --all git commit -m "Initial Commit"
Push your files to the repository by running the following commands in the terminal (change the URL accordingly):
git remote add origin https://username@stash.atlassian.com/scm/PROJECT/repo.git git push -u origin master
You can import your existing Git project into Stash. When you do this, Stash maintains your commit history.
Check out the repository from your existing Git host. Use the --mirror parameter to include all branches and tags:
git clone --mirror
Change the remote origin in your local repository to point to Stash (change the URL accordingly):
git remote set-url origin https://username@stash.atlassian.com/scm/PROJECT/repo.git
Then push all branches to Stash:
git push origin
既存のリポジトリを Stash でホストされるリポジトリへミラーリングできます。
Check out the repository from your existing Git host. Use the --mirror parameter to include all branches and tags:
git clone --mirror
Stash をローカルリポジトリの別のリモートとして追加:
git remote add stash https://username@stash.atlassian.com/scm/PROJECT/repo.git
Then push all branches and tags to Stash
git push --all stash git push --tags stash
git fetch origin,
and the git push
commands listed in step 3, the repository in Stash can be updated with changes from the upstream repository.