Skip to content

Instantly share code, notes, and snippets.

@ink-ru
Last active November 24, 2020 10:42
Show Gist options
  • Save ink-ru/2ed85f2966695a309b2faaae477ce6c8 to your computer and use it in GitHub Desktop.
Save ink-ru/2ed85f2966695a309b2faaae477ce6c8 to your computer and use it in GitHub Desktop.
Create new repository in github, gitlab, bitbucket

You have an empty repository

To get started you will need to run these commands in your terminal.

New to Git? Learn the basic Git commands

Configure Git for the first time

  git config --global user.name "Васин Юрий Александрович"
  git config --global user.email "YAVasin@mail.ru"
  git config --global core.autocrlf false

Working with your repository

I just want to clone this repository

If you want to simply clone this empty repository then run this command in your terminal.

git clone https://sbtatlas.sigma.sbrf.ru/stash/scm/ivb/bx24.module.git

My code is ready to be pushed

If you already have code ready to be pushed to this repository then run this in your terminal.

cd existing-project
git init
git add --all
git commit -m "Initial Commit"
git remote add origin https://sbtatlas.sigma.sbrf.ru/stash/scm/ivb/bx24.module.git
git push -u origin master

My code is already tracked by Git

If your code is already tracked by Git then set this repository as your "origin" to push to.

cd existing-project
git remote set-url origin https://sbtatlas.sigma.sbrf.ru/stash/scm/ivb/bx24.module.git
git push -u origin --all
git push origin --tags

All done with the commands?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment