vweevers / hallmark

Markdown Style Guide, with linter and automatic fixer.
GNU General Public License v3.0
30 stars 3 forks source link

Hallmark with filesystem based remotes ? #126

Closed gl-yziquel closed 2 weeks ago

gl-yziquel commented 2 weeks ago

Hi.

I experienced the following error with a homebuilt hallmark. From source.

I get the following error:

Unable to parse git host URL "/storage/git/my-repo.git/".

I tend to store my git repositories in a storage space, to buffer my interactions with the remotes through that repository. And then, I clone that filesystem based repository to work on it locally.

When running hallmark on that repository, it seems to have a problem with filesystem based, local, git remotes.

Is this considered a problem for hallmark ? Or not ?

vweevers commented 2 weeks ago

It tries to guess the URL of your GitHub (or similar) repository based on the git remote. When that's not possible, like in your case, you can create a .hallmarkrc file containing:

{
  "repository": "OWNER/REPO"
}

E.g. for this repo it would be:

{
  "repository": "vweevers/hallmark"
}
gl-yziquel commented 2 weeks ago

Thank you.

A cli option to perform only markdown formatting and ignore the remotes would suit my workflow better. But, OK.

vweevers commented 2 weeks ago

It is used for formatting in the remark-github plugin and others. If you want less, you might prefer remark-cli.

gl-yziquel commented 2 weeks ago

Thank you !