Can you make custom package Functions/Rules in Xcode 13?

Viewed 30

I am creating a swift package in Xcode and I have a question about the rules you can use on files in your target directory. I am familiar with the generic package functions/rules like .process() and .copy() but I would like to know if it would be possible to create a custom function to run every time a certain type of file is encountered like this:

    .target(
        name: "MyLibrary",
        resources: [
            .process("text.txt"),
            .exampleFunction("exampleFile.swift")]
    ),
]
0 Answers
Related