Skip to content
This repository was archived by the owner on Mar 1, 2026. It is now read-only.
This repository was archived by the owner on Mar 1, 2026. It is now read-only.

Proposal - use normalized group/project names #45

Description

@michalstutzmann

@azolotko thanks for the great work here! The plugin works like a charm (also the latest fix works with SBT 1.7.x).

I would like to propose a little usability improvement. Maybe we don't have to always use group/project IDs but just the normalized GitLab project/group names.

What if we added the following settings:

val gitlabGroupId = settingKey[Option[GitlabGroupId]](
  "GitLab group ID"
)

val gitlabNormalizedGroupName = settingKey[String](
  "GitLab normalized group name"
)

val gitlabNormalizedProjectName = settingKey[String](
  "GitLab normalized project name"
)

And then in the project settings provide some defaults:

gitlabNormalizedGroupName := organizationName.value, // TODO: should be also normalized here
gitlabNormalizedProjectName := normalizedName.value

This part then could be default as well:

gitlabRepositories ++= Seq(
  GitlabProjectRepository(gitlabDomain.value, gitlabProjectId.value.getOrElse(GitlabProjectId(gitlabNormalizedProjectName.value))),
  GitlabGroupRepository(gitlabDomain.value, gitlabGroupId.value.getOrElse(GitlabGroupId(gitlabNormalizedGroupName.value)))
),

User input would reduce to this in non-default case:

gitlabNormalizedGroupName := "group-xxx",
gitlabNormalizedProjectName := "project-xxx"

Have tested that on my side, can provide a PR if you like it.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions