Browsed by
Tag: Git

Git: warning: Not a git repository

Git: warning: Not a git repository

When you try to update/pull or get a diff for the Git repository, you can get a warning: It is because the new version of Git forbidden to run git commands in a directory that is not owned by the current user ( CVE-2022-24765 ) To fix, you need to change permission for the directory or set security options to git when running commands in CI/CD

Добавить существующий Git репозиторий в Bitbucket

Добавить существующий Git репозиторий в Bitbucket

git clone –mirror https://bitbucket.org/exampleuser/repository-to-mirror.git # Make a bare mirrored clone of the repository   cd repository-to-mirror.git git remote set-url –push origin https://github.com/exampleuser/mirrored # Set the push location to your mirror   git push –mirrorgit clone –mirror https://bitbucket.org/exampleuser/repository-to-mirror.git # Make a bare mirrored clone of the repository cd repository-to-mirror.git git remote set-url –push origin https://github.com/exampleuser/mirrored # Set the push location to your mirror git push –mirror

Git: запомнить пароль на день

Git: запомнить пароль на день

Чтобы в течении рабочего дня не воодить постоянно пароль при доступе в Git в версии 1.7.9 и выше появилась возможность кеширования введенных данных git config –global credential.helper cachegit config –global credential.helper cache это заставит держать данные авторизации в памяти По умолчанию 15минут. Но можно выставить свое время