-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom Publishing Strategies #59
Comments
I think this is worth supporting (with some documented constraints aka "conventions")
|
I'm OK with a plugin system. Reviewing the code, I can already see that there are places that would be clearer if we were using one internally (for example, for npm vs pnpm). But if we make one I'm going to be picky and insist we do it properly, because nothing causes long-term pain like a half-thought-out plugin system. It's not the kind of thing you can just do as an MVP first and then make it better later. Once people are using it it's hard to change substantially.
If all this feels heavyweight, yeah, I don't disagree but that is the burden of evolvable extensibility. If people feel this isn't worth prioritizing I'm also OK with that decision. |
Thanks for your detailed response @ef4!
I don't disagree here, but for my curiosity, why would it need to be a peerDependency in the case of class extension but not an interface? Wouldn't a devDependancy work the same in either scenario? I'm also not clear what is meant by
Agreed. I was planning on converting the current implementation to work through a plugin like structure before working on the vscode strategy, admittedly I was only considering the final publish steps, but making tag creation/publishing a plugin too makes sense.
Agreed. My initial idea just had
Agreed. I was planning on using
Agreed. I think setting options would happen through the config file discussed later on. Though maybe a way for plugins to provide their own CLI arguments could be drafted. Do you have any thoughts yourself on how this might be achieved?
Agreed. I'd also suggest
I like the idea of hashing the config, I don't see a reason not to have that functionality immediately. We could check the hash and warn the user with an option to continue anyway or to generate a new As for prioritization, I wouldn't want to pull anyone away from more important work like embroider or core framework tasks to focus on something that is secondary and not needed for the projects currently using release-plan. So I'm totally willing to push ahead and work on this myself, I just might have questions or need some guidance as I work through things. |
I like what @ef4 is saying here (great post btw, I wonder if it could be a blog on how to write a good plugin architecture 😂 ), but I have 2 issues that I want to be clear about:
I would be very upset if this change meant that we forced a new config file on people that just want the "out of the box" implementation. Maybe we could take the vite approach and assume that if it's not there it uses the "default config" under the hood? Secondly I understand that it's worth putting some thought into the |
Agreed. I think an internal default config would be used if no
I'd be happy with that. I'd still probably work on the hashing functionality and bail out on any warning if a |
I'm not opposed to having a default config but I think in most projects that do that it becomes a gimmick and approximately 0% of real users actually use it without a config. Also embroider uses |
I think it's totally fine for the stable branch to introduce a config file so that it can override that function, we don't need to mess with ENV variables to avoid config files.
I strongly disagree with this. I've probably installed half of the current uses of release-plan and only 2 of them need to use any command line arguments at all. That's why I would like it to work with a default config 👍 |
So I was evaluating using this for releasing projects over at the @ember-tooling org. Most of what we need to publish are VSCode extensions though and right now npm is a baked in assumption of release plan.
One idea I came up with was having some way for a project to supply a custom publishing strategy by passing in a PublishStrategy class that would potentially look something like this.
I think this would work by running a command similar to this
Popular strategies could potentially be merged back upstream and named so you can do things like this
I'd like to take a stab at a proof of concept on this but creating this issue initially for feedback or other ideas.
Extra context https://github.com/orgs/ember-tooling/discussions/1
The text was updated successfully, but these errors were encountered: