Я клонировал родительский репозиторий 'objc4
' от https://github.com/RandomDSdevel/objc4 к локальному пути '/Volumes/Development/Repositories/objc4
.' Этот родительский репозиторий содержит подмодуль «OBJC4-437.1-Runtime
», который я настроил для зеркалирования содержимого https://github.com/macmade/OBJC4-437.1-Runtime по локальному пути «/Volumes/Development/Repositories/objc4/runtime
». Я хотел бы объединить этот подмодуль в его родительский репозиторий и уже попытался сделать это, используя these instructions here. Я участвую в этой процедуре после первого «Предупреждения!». в тексте, где его автор направляет его, чтобы клонировать вторую копию репозитория, к которой ваш подмодуль указывает в тот же каталог, что и тот, в котором находится родительский репозиторий вашего подмодуля, и запускать сценарий, который он предоставляет. За некоторые дополнения, которые я сделал here, в раздел обсуждения сообщения в блоге, содержащий процедуру, к которой я обращался, я продолжаю получать ошибки из этого скрипта даже после обновления с OS X 10.9.5 «Mavericks» до OS X 10.10 .0 'Йосемити.' Я попытался снова безрезультатно после моей первой попытки, показанной в моем первом комментарии к его сообщению в блоге, и будет содержать достаточное количество результатов моих вторых двух попыток, чтобы дать представление о том, какие сообщения об ошибках я получаю ниже. Что я делаю неправильно? Я запускаю сценарий оболочки из неправильного каталога? Я не даю ему правильные пути к файлам?Ошибки Объединение подмодуля Git в его родительский репозиторий в OS X
Второй сценарий Run Покушение:
Bryces-HD-1-TB:runtime bryce$ /Users/bryce/Downloads/git-rewrite-to-subfolder
This script rewrites your entire history, moving the current repository root into a subdirectory. This can be useful if you want to merge a submodule into its parent repository.
For example, your main repository might contain a submodule at the path src/lib/, containing a file called "test.c". If you would merge the submodule into the parent repository without further modification, all the commits to "test.c" will have the path "/test.c", whereas the file now actually lives in "src/lib/test.c".
If you rewrite your history using this script, adding "src/lib/" to the path and the merging into the parent repository, all paths will be correct.
NOTE: This script might complete garble your repository, so PLEASE apply this only to a clone of the repository where it does not matter if the repo is destroyed.
Do you want to proceed? (y/n) y
Please provide the path which should be prepended to the current root. In the above example, that would be "src/lib". Please note that the path MUST NOT contain a trailing slash.
Please provide the desired path (e.g. 'src/lib'): /Volumes/Development/Repositories/objc4/runtime
100644 f14f44cb3b69631fac2463fad25cd3b40b4dbc5b 0 /Volumes/Development/Repositories/objc4/runtime/.gitignore
100644 5342bd2b09a64ea93e3587d5d3e9d97966871555 0 /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.h
100644 d1e5617d8b3ed55f1d32e65f8af75c3ab914dc26 0 /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.m
100644 4b4584b9e7bd196fb0c1906b3ebcb37af52eac31 0 /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-i386.s
100644 c3f7332252a2b17f5d6a7e06bbd370f68909ce9f 0 /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-ppc.s
⋮
100644 b48f5e3581a430edc7984d7a72f6044d2618746c 0 /Volumes/Development/Repositories/objc4/runtime/objc.h
100644 af2830174561fa3a8d4a19996190992a8fa0f850 0 /Volumes/Development/Repositories/objc4/runtime/objcrt.c
100644 b3995456f9ee5860970abf496f2a2de591bfb4d9 0 /Volumes/Development/Repositories/objc4/runtime/objcrt.h
100644 c6047bbdb38ed2cd9d2bb7fee2d653d063874070 0 /Volumes/Development/Repositories/objc4/runtime/runtime.h
Please take a look at the printed file list. Does it look correct? (y/n) y
Rewrite 50d5519c12723f5d9ec2170bc45c144b25a8107e (1/5)Ignoring path /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.m
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-i386.s
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-ppc.s
⋮
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objc.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objcrt.c
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objcrt.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/runtime.h
mv: /Volumes/Development/Repositories/objc4/runtime/.git-rewrite/t/../index.new: No such file or directory
index filter failed: git ls-files -s | sed "s// \/Volumes\/Development\/Repositories\/objc4\/runtime\//" | GIT_INDEX_FILE=${GIT_INDEX_FILE}.new git update-index --index-info && mv ${GIT_INDEX_FILE}.new ${GIT_INDEX_FILE}
Третий скрипт Run Покушение:
Bryces-HD-1-TB:runtime bryce$ /Users/bryce/Downloads/git-rewrite-to-subfolder
This script rewrites your entire history, moving the current repository root into a subdirectory. This can be useful if you want to merge a submodule into its parent repository.
For example, your main repository might contain a submodule at the path src/lib/, containing a file called "test.c". If you would merge the submodule into the parent repository without further modification, all the commits to "test.c" will have the path "/test.c", whereas the file now actually lives in "src/lib/test.c".
If you rewrite your history using this script, adding "src/lib/" to the path and the merging into the parent repository, all paths will be correct.
NOTE: This script might complete garble your repository, so PLEASE apply this only to a clone of the repository where it does not matter if the repo is destroyed.
Do you want to proceed? (y/n) y
Please provide the path which should be prepended to the current root. In the above example, that would be "src/lib". Please note that the path MUST NOT contain a trailing slash.
Please provide the desired path (e.g. 'src/lib'): /Volumes/Development/Repositories/objc4/runtime
100644 f14f44cb3b69631fac2463fad25cd3b40b4dbc5b 0 /Volumes/Development/Repositories/objc4/runtime/.gitignore
100644 5342bd2b09a64ea93e3587d5d3e9d97966871555 0 /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.h
100644 d1e5617d8b3ed55f1d32e65f8af75c3ab914dc26 0 /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.m
100644 4b4584b9e7bd196fb0c1906b3ebcb37af52eac31 0 /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-i386.s
100644 c3f7332252a2b17f5d6a7e06bbd370f68909ce9f 0 /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-ppc.s
⋮
100644 b48f5e3581a430edc7984d7a72f6044d2618746c 0 /Volumes/Development/Repositories/objc4/runtime/objc.h
100644 af2830174561fa3a8d4a19996190992a8fa0f850 0 /Volumes/Development/Repositories/objc4/runtime/objcrt.c
100644 b3995456f9ee5860970abf496f2a2de591bfb4d9 0 /Volumes/Development/Repositories/objc4/runtime/objcrt.h
100644 c6047bbdb38ed2cd9d2bb7fee2d653d063874070 0 /Volumes/Development/Repositories/objc4/runtime/runtime.h
Please take a look at the printed file list. Does it look correct? (y/n) y
Rewrite 50d5519c12723f5d9ec2170bc45c144b25a8107e (1/5)Ignoring path /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Accessors.subproj:/objc-accessors.m
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-i386.s
Ignoring path /Volumes/Development/Repositories/objc4/runtime/Auto.subproj/objc-auto-ppc.s
⋮
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objc.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objcrt.c
Ignoring path /Volumes/Development/Repositories/objc4/runtime/objcrt.h
Ignoring path /Volumes/Development/Repositories/objc4/runtime/runtime.h
mv: /Volumes/Development/Repositories/objc4/runtime/.git-rewrite/t/../index.new: No such file or directory
index filter failed: git ls-files -s | sed "s// \/Volumes\/Development\/Repositories\/objc4\/runtime\//" | GIT_INDEX_FILE=${GIT_INDEX_FILE}.new git update-index --index-info && mv ${GIT_INDEX_FILE}.new ${GIT_INDEX_FILE}
P. S .:
У меня снова возникли проблемы, хотя я следовал инструкциям, которые вы дали мне в своем ответе. Здесь, наряду с моим входом, является то, что ваш сценарий выбрасывалось у меня в плане подсказок и сообщений об ошибках:
Bryces-HD-1-TB:objc4 bryce$ /Users/bryce/Downloads/git-rewrite-to-subfolder
This script rewrites your entire history, moving the current repository root into a subdirectory. This can be useful if you want to merge a submodule into its parent repository.
For example, your main repository might contain a submodule at the path src/lib/, containing a file called "test.c".
If you would merge the submodule into the parent repository without further modification, all the commits to "test.c" will have the path "/test.c", whereas the file now actually lives in "src/lib/test.c".
If you rewrite your history using this script, adding "src/lib/" to the path and the merging into the parent repository, all paths will be correct.
NOTE: This script might complete garble your repository, so PLEASE apply this only to a clone of the repository where it does not matter if the repo is destroyed.
Do you want to proceed? (y/n) y
Please provide the path which should be prepended to the current root. In the above example, that would be "src/lib". Please note that the path MUST NOT contain a trailing slash.
Please provide the desired path (e.g. 'src/lib'): runtime
100644 7fe9c0cee579b7b5ccce3f903486557c01f58255 0 runtime/.gitmodules
160000 9569632f173948b503fa3e23187fbd3dbe124eb0 0 runtime/runtime
Please take a look at the printed file list. Does it look correct? (y/n) y
Rewrite 5119d79f8b4714e17fb23ea84fa7801ca71b896c (2/5)mv: /Volumes/Development/Repositories/objc4/.git-rewrite/t/../index.new: No such file or directory
index filter failed: git ls-files -s | sed "s// runtime\//" | GIT_INDEX_FILE=${GIT_INDEX_FILE}.new git update-index --index-info && mv ${GIT_INDEX_FILE}.new ${GIT_INDEX_FILE}
Ах, конечно! Как я мог быть таким глупым? – RandomDSdevel
@ x3r0: О, подождите; это не сработало, поэтому я добавлю детали сообщения об ошибке к моему первоначальному вопросу (хотя у меня заканчивается свободное пространство)! Возможно, мне нужно запустить скрипт из '' runtime' ' и кормить его '' '?? ' Или это может быть связано с тем, что вы создали этот скрипт для работы с версиями OS X и Git старше тех, которые у меня есть? На всякий случай, у меня есть OS X 10.10.0 «Yosemite» и Git 1.8.4. – RandomDSdevel
Похоже, вы используете его в родительском репозитории? Вы должны запустить эту команду внутри репозитория подмодулей. – fresskoma