Skip to content
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

allow passing multiple arguments to dependency DSL calls #61

Merged
merged 4 commits into from
Dec 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ plugins {
id 'com.gradle.plugin-publish' version '1.2.0'
}

version = '2.8.6'
version = '2.8.7'
group = 'com.modrinth.minotaur'
archivesBaseName = 'Minotaur'
description = 'Modrinth plugin for publishing builds to the website!'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,19 +27,23 @@ protected NamedDependencyContainer(NamedDomainObjectContainer<NamedDependency> c
/**
* Creates an incompatible Dependency Container and applies the projectId property
*
* @param projectId the project id
* @param projectIds the project id(s)
*/
public void project(final String projectId) {
this.dependencyContainer.add(new NamedDependency(projectId, null, this.dependencyType));
public void project(final String... projectIds) {
for (String projectId : projectIds) {
this.dependencyContainer.add(new NamedDependency(projectId, null, this.dependencyType));
}
}

/**
* Creates a incompatible Dependency Container and applies the versionId property
*
* @param versionId the version id
* @param versionIds the version id(s)
*/
public void version(final String versionId) {
this.dependencyContainer.add(new NamedDependency(null, versionId, this.dependencyType));
public void version(final String... versionIds) {
for (String versionId : versionIds) {
this.dependencyContainer.add(new NamedDependency(null, versionId, this.dependencyType));
}
}

/**
Expand Down
Loading