HNHacker News
TopNewBestAskShowJobs

andreineculau

261 karma · joined March 4, 2013

[ my public key: https://keybase.io/andreineculau; my proof: https://keybase.io/andreineculau/sigs/Lg7e62K1XpbsqjaVNMV2y9KBzhAmFdO6MXcOV29hLVU ]

http://ysoftware.se http://andreineculau.com

submissionscomments
andreineculau··on Show HN: Node.js node_modules file pruning
Usually I don't care about what language an executable is written in. After all, as a user I'm just interested in whether it executes or not.

But these small-software situations amaze me. Someone with a node_modules problem will have readily available sh, node and maybe python. So why golang? What could those not do, or golang can do better to such extent that it trumps availability? Similarly there's a price to pay in terms of people contributing with a fix: who is interested in pruning node_modules and will send in a golang PR?

In other words, if a dev would prefer Java (specifically chosen because it exacerbates the startup time), would it still pass as ok? Luckily golang can compile to binaries but that implies you give up availability on the other end, now being confined to someone compiling and publishing on a regular basis, as opposed to just pushing a fix commit to a git url.

None of the above would be of importance if this would be a personal-quality repo with a note: hey i did this at 2am out of frustration, i chose the tools that i knew best, use it at your own risk, opensourced to share knowledge and to access it from my own projects, not as a "productified" software.

EDIT: I would much prefer a commenter's solution in sh for the reasons above but also readibility: https://gist.github.com/gpittarelli/64d1e9b7c1a4af762ec467b1... :clap:

andreineculau··on Show HN: Quickfix, the best stupid idea for fixing problems in Node modules
Correct. The pnpm approach is more versatile. You can do anything to a dependency's package.json . I have recently used it to debug and then monkey patch "scripts" (property) invocations without even forking the dependency.
andreineculau··on Show HN: Quickfix, the best stupid idea for fixing problems in Node modules
Leaving aside the comedic factor, albeit problem-solving, if you want a sane alternative check out pnpm. It will not only make the installation of deps faster but it will also allow you to override a dependency on any n-level e.g. a dependency of a dependency.

A dependency published a patch version with a breaking change and the author is on vacation? No problem, you can lock it within your project to the previous version.

Did you fork a dependency and you want to use your version? You can do that too. In all of your dependency chain. You can even change the version specifier to a git url so no need to publish your fork to the npm registry.

I whole heatedly recommend anyone to have a look at pnpm. As a unix dev, there's so much in there that is well thought and kept simple this fast.

https://github.com/pnpm/pnpm/blob/master/README.md#hooks

andreineculau··on Show HN: Erlang REST framework
nothing "REST" about it. 100% HTTP

PS: if anyone is interested in a language-agnostic artifact like cowboy's or webmachine's, see https://github.com/for-GET/http-decision-diagram

andreineculau··on Twitter’s multi-million dollar US election pitch to RT
If only someone would hear you and just do it...
andreineculau··on The rise and fall of Ext JS
As a developer of some "popular" widgets, I owe a great deal to ExtJS because it taught me that encapsulation, especially in JavaScript, a scripted language with defacto accessible source code, is just absurd. A simple thing like that reminded me of functional programming and the rest is history.

Extending a dropdown component meant that i had to copy some closure just to change a number in a wrapped function, and then update the copy-paste with each extjs version that touched it. Why? Because the developer didn't know any better. Similarly now you have "private" fields in classes, etc because some group wants them, because other languages have them so ofc JavaScript needs it too. When all you have is a hammer...

ExtJS is very much rooted in me as a "not like this", as much as Douglas Crockford is preaching a "keep it simple, stupid, like this". I get pleasure just by hearing him give a talk and saying that while they kids are adding and adding to this pretty ok language, he only needs tail call optimizations, because keeping to the good parts is more than enough.

andreineculau··on It’s time to kill the web app
The article itself is click bait since the real meat is to be expected in the follow-up article.
andreineculau··on Golang: Don't be afraid of makefiles
Having a GOCMD may be useful, but not like this.

In bigger systems, you may alter the PATH in the CI env or part of the Makefile itself, or PATH differs from machine to machine, OS to OS, etc, or you want to say that GOCMD is either "gofork" or "go".

Regardless of the situation you'd want to use an absolute path to the executable so that if you run make in verbose mode you'd see "/usr/bin/go" or "/home/user/local/bin/go" or "/this/is/not/the/real/go" printed. Being super strict about this pattern will keep you sane.

andreineculau··on EditorConfig – file format for defining coding styles and text editor plugins
The companion would be eclint in order to lint as part of a git hook or CI test run

https://github.com/jedmao/eclint

andreineculau··on EditorConfig – file format for defining coding styles and text editor plugins
I haven't used prettier but eslint can also fix style
andreineculau··on On Password Managers
you would still need to use your master password to unlock the vault
andreineculau··on Gitter is open source
Start small: a CLI chat client, no auth (auth is the ability to push to the remote), install a fetch hook to notify user of unread chat msgs, done. At that point anyone can use it.
andreineculau··on Gitter is open source
Two others touched on the sudo part but the global flag is as bad. So they have a gulp file that works with gulp "v1". Gitter goes bust (inactive), next year gulp is bumped to "v2", you want to try out gitter, gulp fails, you have to digg why. Another scenario is when another project asks you do the same, install gulp globally, but it actually means gulp "v0". Now you can't run to projects side by side.

Global deps should be versioned, the same way you do not see a respectable npm module with "*" semver in its package.json.

Seeing things like this in 2017 from smth like gitter! now owned by gitlab! is just a big red warning "amateur work, please look away".

How can you have a Makefile, a Makefile! and still require gulp, and still require people to run "npm install"? How? Where's the bare minimum logic?

andreineculau··on Gitter is open source
> Whilst drinking your tea, make sure you have Gulp installed. You can do this with npm install -g gulp. You may need to use sudo for this.

How blind can you be not to understand how evil this request is to your users? And you request this because... because you don't want to `sed 's|gulp |node_modules/.bin/gulp|g' Makefile` ?

Similarly, too hard to check npm's version in Makefile, and run or not run `linklocal` yourselves?

andreineculau··on Why We Chose Typescript
You don't need years of trials. One thing that people forget is that types are a parallel ecosystem more times than not i.e. DefinitelyTyped. So you do not have that lock-step that is praised. So imagine wanting to use a brand new webextension api - stop, add it to types. Want to upgrade a dependency - stop, the types are not working/incorrect/incomplete e.g. https://github.com/DefinitelyTyped/DefinitelyTyped/issues/17...

AFAICS the Typescript types ecosystem is bigger simply because Typescript has been advertised to devs coming from a background of a statically typed lang, and they cannot imagine not using types, thus they drown in them.

Flow on the other hand appeals to those that want types primarily in their own codebase, and come from inferred/dynamically typed langs, where you gradually add static types starting with key sensitive parts in your codebase e.g. Erlang http://learnyousomeerlang.com/types-or-lack-thereof

andreineculau··on TC39, ECMAScript, and the Future of JavaScript
Oh please. Decorators will never beat plain old functions when it comes to flexibility.
andreineculau··on TC39, ECMAScript, and the Future of JavaScript
Based on Crockford, when tail recursion optimization lands, meaning soon. It's getting ridiculous now, with a super blurry line between language features and built-in utils
andreineculau··on Designing state machines
FWIW there is a standard to describing (finite) state machines despite the RFC being expired https://tools.ietf.org/html/draft-bortzmeyer-language-state-...

I have used an "improved" version of it https://github.com/andreineculau/cosmogol-abnf when working on https://github.com/for-GET/http-decision-diagram

andreineculau··on Police sent warrant to Facebook for information on Philando Castile’s girlfriend
The level of pjmedia is just deplorable. One article makes the point that the police officer had his life threatened by someone who TOLD HIM IN ADVANCE THAT HE HAS A FIREARM because that's what you do when you want to shoot, and mentions nothing about conflicting requests: reach for the license, don't reach for the gun. The other one is complete non-sense trying to cast shadow on the Black Lives Matter movement (while hypocritically implying that the color of the victim's skin doesn't matter) and on the victim BECAUSE HE HAD BEEN PULLED OVER BY THE POLICE MULTIPLE TIMES AND HAD A FINE DEBT OF $6000. All of this obviously means his life should have been taken.

The techdirt article has two elements (which are not challenged by pjmedia) that make this a pure kill and power war in contrast with the term public servant: one is the facebook warrant for which no reason is given, reason based on what the police knew already on the victim, and the other is the lack of logic in the officer's TESTIMONY connecting smoking marijuana to willing to kill (statistics actually show the opposite).

andreineculau··on Ask HN: AWS S3 media player?
I would mount the S3 bucket locally then let smth like nStream do its job e.g. https://github.com/s3fs-fuse/s3fs-fuse
andreineculau··on GitPitch – Markdown Presentations for Devs on GitHub and GitLab
I have been doing this for years with remark. Works on any git service, because it only needs a url to a markdown file.

See http://andreineculau.github.io/go-remark/?//andreineculau.gi... Source: https://github.com/andreineculau/go-remark

andreineculau··on Txt.fyi
if anyone is interested in a on-premise minimalistic pastebin-like service, I ended up writing https://github.com/andreineculau/tastebin
andreineculau··on Safari 10.1
Getting merged http://trac.webkit.org/changeset/210942
andreineculau··on Lesser known Git commands
same functionality, my alias is "rush"

$ git rush

andreineculau··on Ghost Browser
In 2016, a browser that needs not only an account registration, but a registration disguised as a "beta invite" (i.e. will send you download links to your email) is nothing but a bad joke and a waste of time.
andreineculau··on Ask HN: Is it advisable to develop a high-scale website using only AWS Lambda?
I am exactly there in terms of MVP and team. We had an AWS connoisseur who left just after I joined. Tiny micro nano services all the way except his know-how didn't rubb off that well with the rest if the team which is new to the web dev altogether. That's one thing. The other being the sea of reinvented lock-in technology that AWS is. While support is quick to reply, you will face many "huh?" moments that have little to do with arguments and more to so with unapologetic opinion, especially API gateway and its integration with Lambda. It's for reasons like the above that we're experimenting now with a more mono architecture, replacing API gateway with Beanstalk for now, nginx later, but still run Lambdas in the background.
andreineculau··on 5 tools to help developing and testing APIs
3 tools

1. curl: https://curl.haxx.se

2. Apiary: https://apiary.io

3. KATT: https://github.com/for-GET/katt -- slides with presentation notes of a talk at https://andreineculau.github.io/go-remark/?//andreineculau.g...

andreineculau··on What Software Engineers Earn Compared to the General Population
Hilarious but effective argument:) I'll start using it. Thanks!
andreineculau··on What Software Engineers Earn Compared to the General Population
Value and worthiness are two different things. If a CEO is valued at 12m/y and another one at 6m/y that does not mean one is worth twice as much, nor does he bring in twice more revenue. I hope one day you'll realize that one way or another everyone is worth more or less the same (eg societies need both good software devs, farmers, doctors, teachers, cleaners, carpenters etc) and we are only valued in very extreme ways.
andreineculau··on Bitbucket secrets
Here's the 7th. Every Bitbucket Server admin has a double-digit long list of watched issues. And to go on, plenty dive into Atlassian, because of the ecosystem, but the ecosystem is not at all symbiotic i.e. the products are built separately, implement same functionality, same UI concepts in totally different ways.

I know the link is not about the onpremise version but given the onpremise solutions' quality, bitbucket.org is well.. In the same bucket.

← PreviousPage 3 of 4Next →