pitt500 / SwiftAndTipsMacros

A list of Swift Macros to make your coding live on Apple ecosystem simpler and more productive.
MIT License
89 stars 7 forks source link

Installation Improvements #4

Open DandyLyons opened 10 months ago

DandyLyons commented 10 months ago

I'm not sure if you consider this Package to be released already but if you do, could you please add a git tag to your main branch so that:

  1. There can be version numbering for the releases
  2. It can be marked as a release on github
  3. I can suggest to swiftpackageindex.com that they add this package to their directory. See: https://swiftpackageindex.com/add-a-package
    • This way more people will see your package, plus they will automatically compile and host DocC documentation for you for free.

Also, in the README it would be helpful if you also included how to add the dependency to a particular target within a Package.swift file: for example:

// ...
dependencies: [
.target(
            name: "Models",
            dependencies: [

                    .product(name: "SwiftAndTipsMacros", package: "SwiftAndTipsMacros") // 👈🏼
            ]
        )
]

Also, Xcode 15 won't compile a Package.swift file if it depends on a macro unless you give permission to the macro. (I guess it's to protect you from macros running malicious code). But Xcode does a really bad job of showing that error, or showing the dialog box so that you can give permission. So if you have any tips for that, that would be helpful.

pitt500 commented 10 months ago

Hi @DandyLyons ,

First off, I'm sorry for my delay in replying to you. Second, thank you very much for your comments!

I've added some instructions about installation already https://github.com/pitt500/SwiftAndTipsMacros#installation, however, it is not versioned and definitely will be a great improvement.

I will try to update this as soon as possible, however, I have an urgent release in my full-time job, and my YouTube channel and side projects like this one have been affected, but I promise to take a look this month on this.

Regarding your question about Xcode 15 permissions, I noticed that and I don't have a clue yet on how to solve it. Looks like it's a "feature", but If I get something, I will let you know.

Regards, Pitt

DandyLyons commented 10 months ago

No rush. Thanks for the reply.

Also, this article might be helpful/interesting for you: Being a good citizen in the land of SwiftSyntax TL;DR;: Since SwiftSyntax is a gigantic dependency, here are tips on how to reduce build times.

pitt500 commented 10 months ago

No rush. Thanks for the reply.

Also, this article might be helpful/interesting for you: Being a good citizen in the land of SwiftSyntax TL;DR;: Since SwiftSyntax is a gigantic dependency, here are tips on how to reduce build times.

Thanks for sharing!