Xcode how to exclude FOLDERS from compilation?

前端 未结 4 1649
走了就别回头了
走了就别回头了 2021-02-19 11:30

I saw this and answers in stackO, but didn\'t find how to exclude folders.

I have 3 folders with a lot of .h , .m and .mm and i need to exclude them temporary, but not

4条回答
  •  北荒
    北荒 (楼主)
    2021-02-19 12:17

    Can't comment, but wanted to note that, unless I'm doing something wrong, when using the EXCLUDED_SOURCE_FILE_NAMES build setting as explained in the other answered, excluding a folder using something like */Folder/* won't exclude anything within sub-folders of Folder, but only files within it directly. If you had another folder, eg. /Folder/Subfolder/, you'd have to include */Folder/Subfolder/* as well in order to exclude any files within it. At least this is the case in Xcode 10.3.

    Example:

    [Folder]
        item.txt
        [Subfolder]
            image.png
        info.plist
    

    */Folder/* would exclude item.txt and info.plist, but not image.png.

    */Folder/Subfolder/* would exclude image.png.

提交回复
热议问题