cliff-jumper icon indicating copy to clipboard operation
cliff-jumper copied to clipboard

request: No GitHub-related checks

Open CHE1RON opened this issue 1 year ago • 5 comments

Is there an existing issue or pull request for this?

  • [X] I have searched the existing issues and pull requests

Feature description

Make the package run with "No GitHub" flag 😋

Currently, it does this first:

✔ Checking GitHub repository configuration...
✔ Checking GitHub releasing configuration...

.. but people not using GitHub (we're using cliff-jumper on a self-hosted GitLab) do not need (even barely noticeable, speedwise) checks like these.

Desired solution

A flag -ngh, --no-github flag, disabling all GitHub features

Alternatives considered

using package as-is

Additional context

No response

CHE1RON avatar Jul 17 '24 06:07 CHE1RON

Now that I think of it: would you be interested in being able to create GitLab releases with this (using @gitbeaker/rest package), if a contribution like that would be of interest ..

My initial proposal for a "No GitHub" flag still stands, though 😅

CHE1RON avatar Jul 17 '24 06:07 CHE1RON

It should be noted that this change will really only be cosmetic in the end because it's microsecond work to do the actual checks as it just checks user input, it doesn't make any API calls or such.

https://github.com/favware/cliff-jumper/blob/a4223cf60acbd02a195ee89773c005736fd18d81/src/lib/preflight-checks.ts#L70-L120

As for GitLab, I have never worked with a GitLab repository or its API. I suppose I can explore that option, but keep in mind that I won't be able to guarantee it's functionality as much as I will for GitHub i.e. when GitLab changes something because I won't be using it myself.

favna avatar Jul 17 '24 07:07 favna

We are currently using a bash script, GitLab's CLI tool glab & git-cliff for changelog/release notes & version bumps (calculating the next version using its newly added --bump flag). Using cliff-jumper would be much easier and as far as I can see, it includes everything we need. I would be happy to contribute & maintain the (compared to the current GitHub features much less elaborate) GitLab part.

CHE1RON avatar Jul 17 '24 08:07 CHE1RON

Sorry for taking absolutely forever for this, but I'm finally getting to this. I just contributed to git-cliff to add gitlab token and repository to the npm package: https://github.com/orhun/git-cliff/pull/843

favna avatar Sep 07 '24 09:09 favna

Sounds fantastic! 🤩

CHE1RON avatar Sep 07 '24 15:09 CHE1RON

For now I added it as simply not doing GitHub specific checks, and passing GitLab information to git-cliff. Releasing through @gitbreaker/rest could be added in the future but I would really appreciate a contribution from your side on that as I'm not familiar with that package or the GitLab API.

favna avatar Oct 19 '24 12:10 favna

I'll see what I can do!

CHE1RON avatar Oct 19 '24 18:10 CHE1RON