1. 16

I work on a lot of Javascript projects. The fashion in Javascript is to use build tools like Gulp or Webpack that are written and configured in Javascript. I want to talk about the merits of Make (specifically GNU Make).

  1.  

  2. 7

    make is also something that every macOS, Linux, or BSD user has available to them. This is a reason why I believe and execute in practice that each project should have a Makefile, even if make compile literally just runs gradle build or cargo build or rake. Each Makefile should have a deps task that somehow installs any development environment dependencies, including pulling Docker containers if they’re used in the development of the project. Each should have a build task that executes any release build stuff but doesn’t run tests. Each should have a test task that executes those tasks.

    This is especially useful when your organization is not standardized on one language or toolset. By using something basic, something that everyone can understand and already has available, you reduce the barrier to entry for onboarding and encourage folks to share knowledge by encoding their knowledge into that Makefile when they learn a new task to be done in the process of development.

    1. 2

      While I absolutely agree with this sentiment, my shop is heavily influenced by Windows development practices. Make isn’t inherent in this environment. I have spent the last year trying to shoehorn my regular UNIX-like routines into the Windows environment (MSYS2 is a real gem and I highly recommend it to everyone on Windows), and now I feel comfortable enough to use these tools I’ve grown comfortable with. There is nothing stopping me from including a Makefile in any repository for any project, I just fear it would be only for my sake.

      1. 3

        The idea is largely “use something that everyone already has and probably knows”. If all Windows developers have a tool that they all have installed, even if that’s Visual Studio, then that’s the unifying, baseline tool that Make is elsewhere.

        1. 2

          Ah, I should have extrapolated more: our team is all over the map in terms of what we work on. The .NET developers do indeed use VS, but they are beginning to branch out into some Node.js development as well. They will no doubt begin to use task runners for these projects, which in turn could be a good time to introduce Make into the process (or some MS equivalent that can be run out of VS, I’m lost in this are because I don’t do this work).

          My side of the team is all PHP developers who don’t really have a build process for what we do, but this is changing as we begin our transition from Magento 1 to Magento 2. Unifying all of us across the team would be fantastic and I’m all for team cohesion at the process level, but there are just situations that may not always work out within a team.

          This is getting me to think more about process though and I’m going to start bringing this up at team meetings.

          1. 2

            If you have VS, you have nmake. In fact you have nmake even if you only have the command line SDK.