Error open temp unitylockfile permission denied

Unable to commit changes — Temp/Unitylockfile error #1039 Comments Prerequisites Be sure to run with tracing enabled to capture runtime details in the log file Include the log file in the PR. On Windows, the extension log file is at %LOCALAPPDATA%GitHubUnitygithub-unity.log On macOS, the extension log file is at /Library/Logs/GitHubUnity/github-unity.log On linux, the extension […]
Include the log file in the PR.

  • On Windows, the extension log file is at %LOCALAPPDATA%GitHubUnitygithub-unity.log
  • On macOS, the extension log file is at

/Library/Logs/GitHubUnity/github-unity.log
On linux, the extension log file is at

Description

Unable to commit changes.

Steps to Reproduce

  1. Select files to commit and add description
  2. click commit

Expected behavior:
I expect the changes to be commited

Actual behavior:
After processing, the list of files under changes does not change and nothing is actually commited.

Reproduces how often:
100%

Additional Information

Any additional information, configuration or data that might be necessary to reproduce the issue.

The text was updated successfully, but these errors were encountered:

This file is not locked by any external process, so it looks like Github Unity is getting in its own way (unless this is a standard Unity file?)

This is a standard Unity file, I don’t know why you’re getting this error, as the Temp folder should not be getting scanned, but I can’t tell what’s really going on without the full log :/

@jwvanderbeck If you’re still around, let me know!

Find Temp/UnityLockfile in the changed files on the left in Github Desktop.
Right-click -> ignore file

For anyone else having this problem, my solution was to change my .gitignore file to have a wild card before all the unity folders. My git directory was one folder above my unity project(so like «Gitfolder/UnityProject/Temp»), and as it looks like the .gitignore was expecting to be at the same level as the Temp folder(and other folders) it was not excluding the folders. Not sure if this will break anything, if not I would suggest GitHub change their default unity ignore file.

Uhm, also does someone know how to post their gitignore file? I tried code, which as you can see bellow didn’t work out well.

`# This .gitignore file should be placed at the root of your Unity project directory

TextMesh Pro files

Autogenerated Jetbrains Rider plugin

Visual Studio cache directory

Gradle cache directory

Autogenerated VS/MD/Consulo solution and project files

*ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.mdb
*.opendb
*.VC.db

*.pidb.meta
*.pdb.meta
*.mdb.meta

Unity3D generated file on crash reports

Builds

Crashlytics generated file

@78Star If you’ll note the comment at the very top of the file, it is intended to be placed in the root of your Unity project. If you choose to put it somewhere else then yeah it won’r work right an you will need to adjust accordingly. That isn’t GitHub’s responsibility really.

Hello.
I solved this problem with the instruction:
echo «Temp/*» >> .gitignore

For me, closing Unity just to add the objects and commit worked.

For me, closing Unity just to add the objects and commit worked.

Yes, this worked for me too 🙂

@vicentselfa HI, i know temp file are unnecessary but did it cause any unpredictable errors?

Don’t forget to change the .gitignore in the repository folder:

It should have something like this:
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Mm]emoryCaptures/

Remove the first slashes:
[Ll]ibrary/
[Tt]emp/
[Oo]bj/
[Bb]uild/
[Bb]uilds/
[Ll]ogs/
[Mm]emoryCaptures/

For anyone else having this problem, my solution was to change my .gitignore file to have a wild card before all the unity folders. My git directory was one folder above my unity project(so like «Gitfolder/UnityProject/Temp»), and as it looks like the .gitignore was expecting to be at the same level as the Temp folder(and other folders) it was not excluding the folders. Not sure if this will break anything, if not I would suggest GitHub change their default unity ignore file.

Uhm, also does someone know how to post their gitignore file? I tried code, which as you can see bellow didn’t work out well.

`# This .gitignore file should be placed at the root of your Unity project directory

@78Star Alexander. I’m liking your explanation of the issue. but I’m way confused by the labeling of the /[Aa]ssets/TextMeshPro/ The rest of the folders in your code have */[Ff]older name , but not the Assets stuff. Huh? Is that intentional or just a miss? This doesn’t make sense to me. thanks,

Источник

Как отключить заблокированные файлы в 8.1 без ключа шифрования

Я удаляю свой проект единства, в котором есть папка .git, и прошу меня создать ключ шифрования. Я не знаю, почему он просит меня сделать это, теперь, когда я пытаюсь добавить файлы в git, он отказывается добавлять какие-либо вещи и предлагает эта ошибка

1 ответ

В общем, папка Temp — это одна из тех вещей, которые вы НЕ хотите контролировать версиями! Это следует игнорировать, как указано в первом комментарии! Используйте этот файл .gitignore в корневой папке вашего гит проект!

Также см. Очистка и миграция существующего проекта Unity на новый тот или иной компьютер, где я объяснил это немного подробнее, а также как скопировать ваш проект только с необходимыми файлами.

Как сказано, если такого файла еще нет, просто создайте его, в противном случае примените содержимое соответствующим образом.

В вашем конкретном случае здесь сама ошибка вызвана тем, что в настоящее время ваш проект открыт в Unity.

В этом случае есть, как следует из названия, файл LOCK, который гарантирует, что вы не сможете открыть один и тот же проект дважды во втором экземпляре Unity.

Этот файл заблокирован/принадлежит самому процессу редактора Unity и, следовательно, не может быть перезаписан/доступен git одновременно.

Теперь, если по какой-то причине после добавления файла .gitignore , упомянутого выше, эта проблема все еще сохраняется, вы можете закрыть Unity, вручную удалить папку Temp, выполнить слияние git и снова открыть Unity.

Источник

Начальная фиксация: «фатальный: не удалось создать ведущие каталоги . »

Я пытаюсь сделать первоначальную фиксацию в репозитории git на GitHub для проекта Unity. Я следил за этим руководством, чтобы понять, где Я. Примечание. По той или иной причине я не мог установить режим сериализации активов Unity на принудительный текст, поэтому я остановился на смешанном (который, я считаю, должен работать).

Когда я вызываю git clone —bare. , Я получаю сообщение об ошибке.

Обратите внимание, что я не являюсь создателем репозитория, а только соавтором (хотя я делаю первоначальную фиксацию).

Вот все, что есть в моем терминале (я использую Git Bash):

Я искал решения этой проблемы, но ничто из того, что я нашел, не имело той же причины, что и то, что я получаю. Помощь в этом очень ценится!

3 ответа

Похоже, у вас здесь две проблемы.

Во-первых, вам нужен файл .gitignore , который правильно ограничивает файлы, которые вы добавляете в Git. Это описано в руководстве, которое вы связали, но, похоже, вы не выполнили его правильно (поскольку ваш add включает файлы из папки Temp ). Глядя на свой список файлов, кажется, что вы случайно назвали этот файл .gitignore.txt . Удалите расширение файла, а затем попробуйте начать снова (повторно запустите git add ), и вы получите лучшие результаты.

Проблема с вашим clone заключается в том, что ваш второй аргумент (путь «.» ) неверен. Это не обязательно (по умолчанию в любом случае будет . ), и если вы действительно хотите указать его, он будет после репозитория, а не до него (см. документация Git для получения подробной информации — предшествует ).

Итак, я думаю, ваш клон должен быть просто таким:

Источник

Начальная команда: «фатальный: не удалось создать ведущие каталоги. «

Я пытаюсь сделать первоначальную фиксацию в git-репозитории GitHub для проекта Unity. Я последовал за этим руководством, чтобы добраться туда, где я. Примечание. По той или иной причине я не мог установить режим Serialization Asset Asset для форсирования текста, поэтому я остановился на Mixed (который, я считаю, должен работать).

Когда я вызываю git clone —bare. , Я получаю сообщение об ошибке.

Обратите внимание, что я не создатель репозитория и только участник (хотя я делаю начальную фиксацию).

Здесь все в моем терминале (я использую Git Bash):

Я искал решения для этого, но ничего, что я нашел, по-видимому, имеет ту же причину, что и то, что я получаю. Помощь по этому поводу очень ценится!

У меня также была эта проблема один раз на MacOS. Оказывается, SourceTree пытался клонировать мою папку /Developer/Projects. Получается системная папка. Я перешел на другую папку, и это сработало.

Похоже, у вас есть две проблемы.

Во-первых, вам нужен файл .gitignore который правильно ограничивает файлы, которые вы добавляете в Git. Это описано в учебном пособии, которое вы связали, но, похоже, вы не выполнили его правильно (поскольку ваше add содержит файлы из папки Temp ). Глядя на ваш список файлов, кажется, вы только что назвали этот файл .gitignore.txt случайно. Удалите расширение файла, а затем попробуйте начать снова (перезапустите git add ), и вы получите лучшие результаты.

Проблема с вашим clone заключается в том, что ваш второй аргумент (путь «.» ) Неверен. Не требуется (по умолчанию будет . В любом случае), и если вы хотите, чтобы указать его, он приходит после того, как хранилище, не ранее (см документации Git для деталей — предшествует ).

Итак, я думаю, что ваш клон должен вместо этого быть следующим:

У меня такая же ошибка. Просто закрой единство и ты готов идти

Источник

Ошибки добавления Git: не удалось открыть каталог: отказано в разрешении

Я использую Windows 10. Когда я набираю команду «git add». в моем Git Bash я продолжаю получать это сообщение, как показано ниже:

Каков ваш текущий рабочий каталог? C:Users ? Боюсь, вы давно используете команду Git по неверному пути .

@GenoChen Должно быть так %UserProfile%

@iBug Согласен. Эта папка, скорее всего, является домашним каталогом в Windows.

@GenoChen Большое спасибо за ваш ответ / c / Users / Mateo

@MateoChiyangi Вот и все. Почему вы выполняете команду Git на этом пути .

@GenoChen Какой путь мне использовать? Я новичок в Git

@MateoChiyangi Путь к вашему проекту кода. У вас может быть много проектов кода во многих отдельных папках.

Как начать новый проект в Git? Вот что я пытаюсь сделать: 1. Создайте текстовый файл с именем HelloWorld.md. Добавьте в документ строку «## This is a markdown file» (без кавычек) (без кавычек) 2. Нажмите на документ в репозиторий datasciencecoursera, который вы создали на Github 3. Отправьте ссылку на файл HelloWorld.md в репозиторий Github.

Вы запускаете подкоманду Git в неожиданном каталоге.

Большинство подкоманд Git зависят от пути. В большинстве случаев эта подкоманда обрабатывает текущий рабочий каталог как корень Git и выполняет операции Git внутри Git root.

Для регулярного использования мы рассматриваем корневой каталог для проекта кода как Git root. Проект с несколькими кодами приводит к созданию нескольких папок и нескольких соответствующих корней Git. Используйте текущий рабочий каталог, чтобы указать их.

Текущий рабочий каталог по умолчанию называется Домашним каталогом, то есть

или чаще всего /home/ или /root в * nix, или C:Users (не администратор), или C:WindowsSystem32 (администратор) в Windows> 7 или C:Documents and Settings в Windows cd ), все операции Git работают с вашим домашним каталогом. В некоторых ситуациях это может быть вредно. Маленькая катастрофа похожа на то, что вы встретили, большая катастрофа может быть чем-то вроде того, что вы случайно загрузили свой личный файл в GitHub или что-то подобное после того, как вы это поняли.

Большое спасибо за подробный ответ. Как мне убедиться, что я нахожусь в правильном каталоге?

В случае, если кто-то другой придет сюда при поиске этой ошибки, и они уже имеют определенно на правильном пути, эта проблема может быть вызвана несохраненными файлами в рабочем каталоге — попробуйте убедиться, что все файлы сохранены, и закройте любую открытую среду IDE.

«Попробуйте убедиться, что все файлы сохранены, и закройте все открытые IDE». — Это помогло. В моем инструменте сравнения текста был открыт файл. Спасибо!

Другие вопросы по теме

Похожие вопросы

Находите ответы на сложные технические вопросы по программированию, с которыми сталкиваются инженеры по всему миру в своей ежедневной практике на сайте RedDeveloper.

Источник

jwvanderbeck

Unable to commit changes — Temp/Unitylockfile error

Prerequisites

  • Be sure to run with tracing enabled to capture runtime details in the log file
  • Include the log file in the PR.
    • On Windows, the extension log file is at %LOCALAPPDATA%GitHubUnitygithub-unity.log
    • On macOS, the extension log file is at ~/Library/Logs/GitHubUnity/github-unity.log
    • On linux, the extension log file is at ~/.local/share/GitHubUnity/github-unity.log

Description

Unable to commit changes.

Steps to Reproduce

  1. Select files to commit and add description
  2. click commit

Expected behavior:
I expect the changes to be commited

Actual behavior:
After processing, the list of files under changes does not change and nothing is actually commited.

Reproduces how often:
100%

Additional Information

Any additional information, configuration or data that might be necessary to reproduce the issue.

GitHub.Unity.ProcessException: error: open("Temp/UnityLockfile"): Permission denied
error: unable to index file Temp/UnityLockfile

jwvanderbeck

This file is not locked by any external process, so it looks like Github Unity is getting in its own way (unless this is a standard Unity file?)

Imgur

shana

This is a standard Unity file, I don’t know why you’re getting this error, as the Temp folder should not be getting scanned, but I can’t tell what’s really going on without the full log :/

shana

BCG-Jackson

Find Temp/UnityLockfile in the changed files on the left in Github Desktop.
Right-click -> ignore file

XanNava

For anyone else having this problem, my solution was to change my .gitignore file to have a wild card before all the unity folders. My git directory was one folder above my unity project(so like «Gitfolder/UnityProject/Temp»), and as it looks like the .gitignore was expecting to be at the same level as the Temp folder(and other folders) it was not excluding the folders. Not sure if this will break anything, if not I would suggest GitHub change their default unity ignore file.

Uhm, also does someone know how to post their gitignore file? I tried code, which as you can see bellow didn’t work out well.

`# This .gitignore file should be placed at the root of your Unity project directory

Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore

*/[Ll]ibrary/
*/[Tt]emp/
*/[Oo]bj/
*/[Bb]uild/
*/[Bb]uilds/
*/[Ll]ogs/
*/[Mm]emoryCaptures/

Never ignore Asset meta data

!/[Aa]ssets/**/*.meta

Uncomment this line if you wish to ignore the asset store tools plugin

/[Aa]ssets/AssetStoreTools*

TextMesh Pro files

/[Aa]ssets/TextMeshPro/

Autogenerated Jetbrains Rider plugin

/[Aa]ssets/Plugins/Editor/JetBrains

Visual Studio cache directory

*/.vs/

Gradle cache directory

.gradle/

Autogenerated VS/MD/Consulo solution and project files

*ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.mdb
*.opendb
*.VC.db

Unity3D generated meta files

*.pidb.meta
*.pdb.meta
*.mdb.meta

Unity3D generated file on crash reports

*/sysinfo.txt

Builds

*.apk
*.unitypackage

Crashlytics generated file

crashlytics-build.properties

`

jwvanderbeck

@78Star If you’ll note the comment at the very top of the file, it is intended to be placed in the root of your Unity project. If you choose to put it somewhere else then yeah it won’r work right an you will need to adjust accordingly. That isn’t GitHub’s responsibility really.

vicentselfa

Hello.
I solved this problem with the instruction:
echo «Temp/*» >> .gitignore

dnenov

For me, closing Unity just to add the objects and commit worked.

raunak111

For me, closing Unity just to add the objects and commit worked.

Yes, this worked for me too :)

Maghil

@vicentselfa HI, i know temp file are unnecessary but did it cause any unpredictable errors?

BridgingGames

Don’t forget to change the .gitignore in the repository folder:

It should have something like this:
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Mm]emoryCaptures/

Remove the first slashes:
[Ll]ibrary/
[Tt]emp/
[Oo]bj/
[Bb]uild/
[Bb]uilds/
[Ll]ogs/
[Mm]emoryCaptures/

zipzit

For anyone else having this problem, my solution was to change my .gitignore file to have a wild card before all the unity folders. My git directory was one folder above my unity project(so like «Gitfolder/UnityProject/Temp»), and as it looks like the .gitignore was expecting to be at the same level as the Temp folder(and other folders) it was not excluding the folders. Not sure if this will break anything, if not I would suggest GitHub change their default unity ignore file.

Uhm, also does someone know how to post their gitignore file? I tried code, which as you can see bellow didn’t work out well.

`# This .gitignore file should be placed at the root of your Unity project directory

@78Star Alexander. I’m liking your explanation of the issue… but I’m way confused by the labeling of the /[Aa]ssets/TextMeshPro/ The rest of the folders in your code have */[Ff]older name, but not the Assets stuff. Huh? Is that intentional or just a miss? This doesn’t make sense to me. thanks,

Tonyy18

For me it was about having the unity editor open while adding files to commit.
Closed the editor and it worked fine

Alifikrii

i can solve this problem by just close my unity project do commit again

jwvanderbeck

How are you using Github for Unity without having Unity running?

Clearly closing the editor and using normal Git or another Github tool will work. But this issue was about the Github for Unity tool which is a Git UI inside the Unity editor.

elvinsadiq

Hello. I solved this problem with the instruction: echo «Temp/*» >> .gitignore

Where did you write this?

shana

Hello. I solved this problem with the instruction: echo «Temp/*» >> .gitignore

Where did you write this?

@elvinsadiq In the root of your Unity project — the directory that has the Assets/ProjectSettings/Temp folders in it — edit the .gitignore file (or create one there if there isn’t one), and add the following line to it:

This will make sure your Temp folder is ignored by git.

AngelHdezRetana

I after closing unity, it let me do my commit as @dnenov suggested, thanks!

Я удаляю свой проект единства, в котором есть папка .git, и прошу меня создать ключ шифрования. Я не знаю, почему он просит меня сделать это, теперь, когда я пытаюсь добавить файлы в git, он отказывается добавлять какие-либо вещи и предлагает эта ошибка

The file will have its original line endings in your working directory
error: open("Temp/UnityLockfile"): Permission denied
error: unable to index file 'Temp/UnityLockfile'
fatal: adding files failed

Любое предложение

1 ответ

В общем, папка Temp — это одна из тех вещей, которые вы НЕ хотите контролировать версиями! Это следует игнорировать, как указано в первом комментарии! Используйте этот файл .gitignore в корневой папке вашего гит проект!

Также см. Очистка и миграция существующего проекта Unity на новый тот или иной компьютер, где я объяснил это немного подробнее, а также как скопировать ваш проект только с необходимыми файлами.

Как сказано, если такого файла еще нет, просто создайте его, в противном случае примените содержимое соответствующим образом.

Также обратитесь к Как заставить Git «забыть» о файле, который был отслежен, но теперь находится в .gitignore?.


В вашем конкретном случае здесь сама ошибка вызвана тем, что в настоящее время ваш проект открыт в Unity.

В этом случае есть, как следует из названия, файл LOCK, который гарантирует, что вы не сможете открыть один и тот же проект дважды во втором экземпляре Unity.

Этот файл заблокирован/принадлежит самому процессу редактора Unity и, следовательно, не может быть перезаписан/доступен git одновременно.

Теперь, если по какой-то причине после добавления файла .gitignore, упомянутого выше, эта проблема все еще сохраняется, вы можете закрыть Unity, вручную удалить папку Temp, выполнить слияние git и снова открыть Unity.


1

derHugo
28 Июл 2021 в 00:03

Понравилась статья? Поделить с друзьями:
  • Error open driver handle failure
  • Error ooce machine type and serial number are invalid
  • Error occurred in loading omnisharp from omnisharp path
  • Error occurred in install product workflow with error code 190 error message
  • Error only virtual member functions can be marked override