News for hackers. Stuff that matters.
Re:Ask HN: What overlooked class of tools should a self-taug... by logicallee on Monday May 13, 2019 @05:05PM (#19903951)
>The big downside of Make, alas, is Windows compatibility.

Isn't the big problem that you have no idea what it's doing to your system? Also that you aren't expected to be able to undo it. You can read the makefiles, of course, but it seems simpler not to have to. (Just update the necessary packages yourself, to the latest version.)

Forgive me if this is naive of me.

Re:Ask HN: What overlooked class of tools should a self-taug... by theon144 on Monday May 13, 2019 @05:35PM (#19904218)
>Isn't the big problem that you have no idea what it's doing to your system?

As opposed to what exactly? Any other alternative, e.g. separate shell scripts, "npm run" scripts in package.json, running a Docker image, hell even cmake or other make-like tools - does stuff you don't know about without reading the files either.

Re:Ask HN: What overlooked class of tools should a self-taug... by aequitas on Monday May 13, 2019 @06:18PM (#19904560)
With Docker at least everything is contained in the container. Which makes isolating and resetting environments a breeze. Something I worry about often is contaminating my system's 'state'. Which always leads to broken builds or incomplete build systems because a missing dependency is not spotted on your system because it was installed by some other tool some other time.

I tend to write my Makefiles to create as much of a local dev environment as possible for every project. Using Python virtualenv/Pipenv/Poetry, Ruby vendored dirs, custom Gopath per project (using direnv), etc. Most tools support some sort of isolation/localisation, but it's often just not on by default.

Re:Ask HN: What overlooked class of tools should a self-taug... by jrumbut on Monday May 13, 2019 @09:46PM (#19906050)
I wish more tools did this, I almost always want a local, self-contained environment for everything. The few times I don't actively want I don't see much pain in having one. A couple minutes setup time, maybe?

I have seriously considered hiring someone to audit and prune all the random little libraries and tools I've installed over the years for that one-off time I had to process a weird file format or wanted to try something from HN.

Re:Ask HN: What overlooked class of tools should a self-taug... by pknopf on Tuesday May 14, 2019 @03:25PM (#19912988)
To keep my system clean, I use Darch.

https://godarch.com/

Every boot is a fresh install. Any one-off only becomes persisted unless I add it to my recipes.

https://github.com/pauldotknopf/darch-recipes

Re:Ask HN: What overlooked class of tools should a self-taug... by alephu5 on Monday May 13, 2019 @10:11PM (#19906200)
Maybe you'd like NixOS?
Re:Ask HN: What overlooked class of tools should a self-taug... by jrumbut on Tuesday May 14, 2019 @09:35AM (#19909290)
I'm fascinated by NixOS and am following it, just haven't had a lot of time to dive in yet.

It does sound like the right idea. This is hypocritical as someone who doesn't use it but I hope more people use it.

Re:Ask HN: What overlooked class of tools should a self-taug... by logicallee on Monday May 13, 2019 @07:15PM (#19905026)
(I was heavily downvoted). What I was thinking is: as opposed to just running your built-in package manager yourself, to upgrade your system to the latest version of all the packages it might require.
Re:Ask HN: What overlooked class of tools should a self-taug... by wtetzner on Monday May 13, 2019 @10:33PM (#19906312)
Makefiles are used for more than package management. In fact, it doesn't seem very common to use them for package management. Maybe I'm missing something?
Re:Ask HN: What overlooked class of tools should a self-taug... by PyroLagus on Tuesday May 14, 2019 @07:52PM (#19915013)
I think they were talking about projects that tell you to run `make install`, which I agree is less than ideal.
Re:Ask HN: What overlooked class of tools should a self-taug... by bch on Monday May 13, 2019 @05:13PM (#19904015)
If you write your own Makefiles you know what they do. They’re not that hard to grok and even hand-rolled Makefile use is (IMO) underrated.
Re:Ask HN: What overlooked class of tools should a self-taug... by dnautics on Monday May 13, 2019 @08:02PM (#19905369)
I always had trouble reading makefiles because the control flow is not very linear. At least with shell files basically everything is explicit.
Re:Ask HN: What overlooked class of tools should a self-taug... by sk5t on Monday May 13, 2019 @08:59PM (#19905755)
The dependency graph is one of the better reasons to use makefiles--think of the nonlinearity as a bonus!
Re:Ask HN: What overlooked class of tools should a self-taug... by aequitas on Tuesday May 14, 2019 @03:15AM (#19907452)
I often find the non linear way of working with Make an advantage. Since it allows you to break a big piece of procedural shell code with lots of control flow (if X is installed don't install again, etc) into small self contained functional pieces with clean input and output boundaries which can be run individually. It also greatly improves code reuse as every target/recipe can be considered a function.
Re:Ask HN: What overlooked class of tools should a self-taug... by dnautics on Tuesday May 14, 2019 @11:24AM (#19910424)
> Since it allows you to break a big piece of procedural shell code with lots of control flow (if X is installed don't install again, etc) into small self contained functional pieces with clean input and output boundaries which can be run individually

At that point, I use a scripting -not shell- language (which is not as implicit)

I don't program in c anymore, so my major workflow is all in one language; I write my server in the same language that do s the compilation, which is in the same language that does utilities like creating network tunnels to my lab nodes