qgadrian

qgadrian

Git hooks - Add git hooks to Elixir projects

Hey guys, I just wanted to share a library that was being around for a while already, but I didn’t share properly until now so it can help more people :vulcan_salute:

It’s called git_hooks and the main features are:

  • Git hooks actions are configured in your project
  • Auto install the configured hooks (configurable)
  • The actions can be system commands or a script in your project

Any feedback or PRs are highly appreciated :heart:

Thank you and stay safe out there!

Most Liked

qgadrian

qgadrian

Hey @r-c!

Is this supposed to occur upon compilation?

Correct! (here it is where in the code).

It’s weird, I just tested it myself in a new project and it worked fine :confused: Since the auto-install will run every time the dependency is compiled, could it be possible that it was already compiled in your case?

Sorry for the late response mate :pray:

Mukulch15

Mukulch15

@qgadrian Hey thanks for the awesome library. I have some concerns regarding automatic installations as well. I placed some logs within the library code and found that the git hooks path that the code uses in case of mix git_hooks.install is different from the one that is generated when we use mix deps.compile.
I believe that when we use mix deps.compile it takes the git hook directory relative to the deps folder. Maybe I am wrong but just wanted to let you know.

qgadrian

qgadrian

Did you try the latest release? I recently added support for “other cases” but the regular, monolith, standard, elixir application.

If you tried it and still have problems, can you please open an issue on GitHub with more details? Then I will take a look and help you out with it :relaxed:

Mukulch15

Mukulch15

Thanks for taking the time to reply. Seems that the new release is not working as well. I will raise an issue on Github with more details.

Where Next?

Popular in Libraries Top

Qqwy
TypeCheck: Fast and flexible runtime type-checking for your Elixir projects. Core ideas Type- and function specifications are const...
336 13801 100
New
RobertDober
Earmark is a pure-Elixir Markdown converter. It is intended to be used as a library (just call Earmark.as_html), but can also be used as...
239 11851 134
New
hpopp
After just over two years in development, this latest version of Pigeon is what I finally consider done in regards to my original vision ...
New
treble37
Just looking for a little feedback on a tiny helper library I built - Sometimes I find the need to convert maps with atom keys to maps...
New
praveenperera
FastRSS Parse RSS feeds very quickly: This is rust NIF built using rustler Uses the RSS rust crate to do the actual RSS parsing Speed...
New
dbern
I’m excited to announce that TaxJar has developed and open-sourced DateTimeParser. We developed it because we found a need to parse user ...
New
danschultzer
None of the current solutions worked well for me, so I went ahead and built a user management system from scratch. This project took far...
548 27727 240
New
mbuhot
EctoJob A transactional job queue built with Ecto, PostgreSQL and GenStage Available on Hex.pm: ecto_job | Hex Docs: API Reference — ec...
New
woylie
Flop is an Elixir library that applies filtering, ordering and pagination parameters to your Ecto queries. offset-based pagination with...
New
Antrater
Hi everyone! I’m thrilled to announce a huge thing. We have been developing Elixir Moon Design System for quite a while. We are finally ...
New

Other popular topics Top

chrismccord
Phoenix 1.4.0 released Phoenix 1.4 is out! This release ships with exciting new features, most notably with HTTP2 support, improved deve...
688 30048 115
New
vonH
In asking this question I am more interested about the expressiveness of the language itself and less concerned about the availability of...
New
jerry
Good day to you all. I have been struggling to get a query involving like and ilike to work. Can anyone assist me on this, please? pro...
New
aalberti333
As the title describes, I’m trying to run Enum.map() over a list of key/value pairs, where the value is a map. My data looks like this: ...
New
grych
Hi folks, Few months ago I have announced the proof-of-concept of the library to manipulate the browsers DOM objects directly from Elixi...
639 49522 488
New
fireproofsocks
I’m working on defining a simple Ecto schema for a table (in PostGres), but I don’t see where I can define a column as NOT NULL. Conside...
New
chrismccord
This release brings a number of exciting features, including integration with the new Phoenix LiveDashboard and Phoenix LiveView. There h...
New
vac
Hi, I'm quite new in Elixir and I'm trying to format a string to a PEM format. I have the certificate value like MIIDBTCCAe2...... and ...
New
stefanluptak
Hello everybody, usually, I use a 29" ultra-wide monitor for VSCode which can easily accomodate explorer (files panel) + file with code ...
New
siddhant3030
Hi, I have to write a raw query for one of my project. But till now I have used ecto queries and don’t have much experience writing raw ...
New

Sub Categories:

We're in Beta

About us Mission Statement