Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
minitech
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
71 ms
·
841.
▲
by
minitech
10y ago
It's common knowledge and you can easily look it up. https://en.wiktionary.org/wiki/predicate Copied here nevertheless: > 2. (logic) A term of a statement, where the statement may be true or false depending on
842.
▲
by
minitech
10y ago
> Even 2 or 3 spaces sometimes work. What? Every number of spaces always works. Anyway, it's nice to separate style recommendations and syntax.
843.
▲
by
minitech
10y ago
Yep, the videos are hugely important. The first half of Go Terminal's is just creating aliases (which is easier to do without the fancy UI), and that's where I got bored and closed the page. This project actually showed some inter
844.
▲
by
minitech
10y ago
files.kde.org is also accessible over HTTPS (but use a package manager if possible).
845.
▲
by
minitech
10y ago
On that website, the styles are on :active (press and hold). It does need the SVGs to be inline with <svg>, though, which isn't great.
846.
▲
by
minitech
10y ago
You can't put arbitrary CSS in GitHub readmes.
847.
▲
by
minitech
10y ago
What is a "responsive icon"? Keep in mind that you can just switch the path to the SVG in CSS in the same way that you'd alter properties of a CSS image.
848.
▲
by
minitech
10y ago
Typo on the "its" here: > Right now Verve runs on it’s own Virtual Machine (VM)
849.
▲
by
minitech
10y ago
Note that “things like this” can sometimes be done just using sed: % sed -i -e "s/root/toor/" -e "/joey/d" /etc/passwd
850.
▲
by
minitech
10y ago
Any bank that's remotely sane with regards to website security (probably rather few of them) doesn't do this at all and uses standard forms of 2FA. This one doesn't even protect against keyloggers, because they can combine th
851.
▲
by
minitech
10y ago
It's a huge detriment to security. You can break sets of 5-7 characters at a time and combine them instead of having to break the entire password at once.
852.
▲
by
minitech
10y ago
Document ready is hardly the most fundamental “tool” for scripting, and it has always been easy to resolve in a cross-browser way: stick your scripts before </body>.
853.
▲
by
minitech
11y ago
> There are a lot of one liners that are much more composable in the fat-arrow syntax. The default returns takes a lot of it out, and makes it simpler the simpler it starts. They’re not more composable… they’re slightly shorter, and an
854.
▲
by
minitech
11y ago
I don’t find the arrow function version of (1) cleaner than the anonymous function version. Is it cleaner because you can fit it on one line? I don’t find the import version of (2) cleaner than the require() version. Having a boring old fun
855.
▲
by
minitech
11y ago
What if you download a binary and a dynamic library is missing? (This is what happens with GHC on Alpine. Binaries will expect glibc. Packages fix this problem, but they also fix the Python problems.) Another example: I recently wanted to r
856.
▲
by
minitech
11y ago
“simply running a binary”: - download letsencrypt-auto - ./letsencrypt-auto ”fiddling around with the source”: - download letsencrypt.tar.gz - extract letsencrypt.tar.gz - ./letsencrypt-auto (and there might
857.
▲
by
minitech
11y ago
Just sign new commits with the new key. Signing a commit also signs its history.
858.
▲
by
minitech
11y ago
No, just the header of the commit (i.e. just the SHA-1) is signed. The signature you used on the valid commit would work if tacked onto the malicious one.
859.
▲
by
minitech
11y ago
You make it sound a lot harder than it is. What it is: git commit -am '(what changed)' Effortless combination of history, backup, and publishing. There’s very little reason not to do it. Up to preference how often it’s done
860.
▲
by
minitech
11y ago
You can still model state pretty straightforwardly when everything’s immutable. This article shows that different designs have different applications more than anything, and, well, duh.
861.
▲
by
minitech
11y ago
No, because it can just sit in the background and wait until you type your passphrase at some point. As soon as you run malicious code, it’s all over; no workarounds. It would be nice if npm didn’t run arbitrary install scripts by default…
862.
▲
by
minitech
11y ago
The name of the function, though, isn’t `isPositiveSafeInteger`; it matches `Number.isInteger` instead. Or maybe you don’t just want safe integers, maybe you want `x >>> 0 === x`, or `x > 0 && (x | 0) === x`, or…. This i
863.
▲
by
minitech
11y ago
A module doesn’t solve that kind of type confusion, though. Static typing does. The next best thing in JavaScript is passing consistent types of values to your functions, so just write function isPositiveInteger(x) { return x >
864.
▲
by
minitech
11y ago
> What happens, however, when you decide to use multiple characters instead of a single character (to create a pattern for example)? Then you can’t use left-pad, because it doesn’t support that and you don’t maintain it. So you make your
865.
▲
by
minitech
11y ago
That’s also the whole point of using a function. (For what it’s worth, I changed it from this to show off ES6.) function repeat(s, times) { return new Array(times + 1).join(s); } function padLeft(s, width, padCharacter) {
866.
▲
by
minitech
11y ago
Hah, “indispensable”. It pads strings. Here, I wrote an alternative: function padLeft(s, width, padCharacter) { var d = width - s.length; return d <= 0 ? s : (padCharacter || " ").repeat(d)
867.
▲
by
minitech
11y ago
The point is that Slack is much easier to configure. Writing IRC notification scripts tests the limits of the “10-year-old” level of difficulty.
868.
▲
by
minitech
11y ago
> Follow the directions to set it up so changes on this Trello board are posted to #channel
869.
▲
by
minitech
11y ago
Surprisingly, not everyone is aware of everything that has ever been on the front page of HN.
870.
▲
by
minitech
11y ago
Ever used \b? This is like that, but for other patterns. Very useful in many situations, like tokenizing (because you have to match on things the last match already consumed).
More ›