7 つのさまざまなプロジェクトが含まれている Visual Studio 2008 ソリューションがあります。これらの「プロジェクト」のうち 3 つは Web サイト (プロジェクト ファイルのない種類のプロジェクト) です。
すべてのディレクトリからさまざまな Visual Sourcesafe ファイルをすべて削除し、SLN ファイル内の Scc 参照と存在するすべてのプロジェクト ファイルを削除しました。SUOファイルとすべてのUSERファイルも削除しました。Visual Studio は、2 つの Web サイトがまだソース管理下にあると認識しており、Scc エントリを SLN ファイルに追加し直しています。
VSがまだ古いソース管理についてどのように知っているか知っている人はいますか?
編集: 私が言及しなかったもう 1 つのことは、VSS フックを削除しようとしているファイルが VSS の既知の作業ディレクトリの外にコピーされていることです。Python スクリプトが実行され、ソリューションが VS で開かれる前にファイルが手動で編集されます。 2008 または VS 2005 (両方に問題がありました)。
これは、これらのファイルを除外し、手動で編集する必要があるファイルを知らせるために使用した Python スクリプトです。
import os, stat
from os.path import join
def main():
startDir = r"C:\Documents and Settings\user\Desktop\project"
manualEdits = []
for root, dirs, files in os.walk(startDir, topdown=False):
if '.svn' in dirs:
dirs.remove('.svn')
for name in files:
os.chmod(join(root,name), stat.S_IWRITE)
if name.endswith(".vssscc") or name.endswith(".scc") or name.endswith(".vspscc") or name.endswith(".suo") or name.endswith(".user"):
print "Deleting:", join(root, name)
os.remove(join(root,name))
if name.endswith("sln") or name.endswith("dbp") or name.endswith("vbproj") or name.endswith("csproj"):
manualEdits.append(join(root, name))
print "Manual Edits are needed for these files:"
for name in manualEdits:
print name
if __name__ == "__main__":
main()