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

[qa] githooks can be used to check commit msg format #289

Closed
RahulPalve opened this issue Apr 4, 2021 · 1 comment
Closed

[qa] githooks can be used to check commit msg format #289

RahulPalve opened this issue Apr 4, 2021 · 1 comment

Comments

@RahulPalve
Copy link

Hey, we can use githooks to force commit msg format, so that commit is not done until its in correct specification/format.
I want to work on this, can we discuss about this.

githook will look like this in our case:
.githooks/.commit-msg

if [[ $commit_msg =~ ^\[(feature|file|module)\].*#[0-9]+; then
    exit 0
else
    echo "$error_msg"
    exit 1
fi

We can do this with all other modules, Please share your thoughts

@purhan
Copy link
Contributor

purhan commented Apr 4, 2021

@RahulPalve We already have this in openwisp-utils. Now we only want to add this in the documentation so that everyone starts using it. We already have an issue for it and contributions are welcome for that (openwisp/openwisp-docs#100).

@purhan purhan closed this as completed Apr 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants