sorted by: new top controversial old
[-] 418teapot@lemmy.world 7 points 1 week ago* (last edited 1 week ago)

Best I can do is

"\ude41🙂".split("").reverse().join("")

returns "\ude42🙁"

[-] 418teapot@lemmy.world 15 points 1 month ago

Yeah good point. I suppose the problem is this function that operates on numbers allows numeric strings to be passed in in the first place. The only place where I would really expect numeric strings to exist is captured directly from user input which is where the parsing into a numeric data type should happen, not randomly in a library function.

[-] 418teapot@lemmy.world 17 points 1 month ago* (last edited 1 month ago)

On my machine at least man openssl shows that -k is for specifying the password you want to derive the key from, so in that case I think you are literally using the string /etc/ssl/private/etcBackup.key as the password. I think the flag you want is -kfile.

You can verify this by running the command in strace and seeing that there is no openat call for the file passed to -k.

Edit: metiulekm@sh.itjust.works beat me to it while I was writing out my answer :)

[-] 418teapot@lemmy.world 31 points 1 month ago* (last edited 1 month ago)

It's kind of insane how bad this whole is-number thing is. It's designed to tell you if a string is numeric, but I would argue if you're ever using that you have a fundamental design problem. I hate dynamic typing as much as anyone else, but if forced to use it I would at least try to have some resemblance of sanity by just normalizing it to an actual number first.

Just fucking do this...

const toRegexRange = (minStr, maxStr, options) => {
  const min = parseInt(minStr, 10);
  const max = parseInt(maxStr, 10);
  if (isNaN(min) || isNaN(max)) throw Error("bad input or whatever");
  // ...

Because of the insanity of keeping them strings and only attempting to validate them (poorly) up front you open yourself up to a suite of bugs. For example, it took me all of 5 minutes to find this bug:

toRegexRange('+1', '+2')
// returns "(?:+1|+2)" which is not valid regexp
[-] 418teapot@lemmy.world 1 points 1 month ago* (last edited 1 month ago)

Ah yeah I don't know how I would do that easily on a phone. Do those in my example above render for you? You should probably be able to just copy/paste them on a phone if they do.

[-] 418teapot@lemmy.world 6 points 1 month ago* (last edited 1 month ago)

I can't find a keyboard with them, or a copy/pastable line where they've been typed

Maybe use combining diacritical marks?

I'm using 0x326 (Combining Comma Below), but you may need the CGJ in there to render correctly in all contexts

e.g.

Foo!̦ Bar?̦

Edit: Combining grapheme joiner, not zero width joiner

[-] 418teapot@lemmy.world 1 points 7 months ago

Agreed, but my point is with a centralized network the lowest common denominator wins. There is no reason you can't have QoL features on an open network, and thusly let everyone have the features that they care most about.

Can you imagine what a shithole the internet would have been if email wasn't federated an open? There is absolutely no way that whatever centralized bullshit would have spawned instead would already be either long gone or enshittified to the point of being useless.

[-] 418teapot@lemmy.world 4 points 7 months ago

Good for you, you have a short list of requirements out of a chat service and discord perfectly fills your niche. But different people have different requirements for chat, and they don't align. And network effects force people who have differing requirements to use the service with the most users which sucks.

For instance here are things that I require from any chat service that I use that discord completely falls flat at:

  • Ability to run it on my linux machine without using an electron client (npm is a huge mess of supply chain attacks and I refuse to run any software that is likely to contain dependencies from it)
  • Ability to run it on my AOSP phone which does not have any google play services installed
  • Ability to write software to back up messages without fear of a company changing their API and breaking my backup system
[-] 418teapot@lemmy.world 4 points 10 months ago

Wtf does that even mean? Bigger cars are usually more durable in general.

This is pretty much what I expected from someone who likes large cars. The idea that their car does damage to the road doesn't even enter their mind. Note the immediate jump to "my property is more durable, fuck your/public property".

[-] 418teapot@lemmy.world 5 points 10 months ago

While I agree that first party systems suck, as someone with neither an iOS or Android device I personally prefer something work rather than a screen that says "connect iOS/Android".

[-] 418teapot@lemmy.world 1 points 10 months ago

Definitely agree, but your link is protected by cloudflare (yet another centralized service destroying the internet) and therefore I'm unable to get through because I have privacy.resistFingerprinting enabled on my browser so cloudflare is unable to determine I'm human I suppose.

I despire youtube and it's monopoly, and I think it get's an appropriate amount of hate on here and HN, but what confuses me to no end are the people who complain about youtube turn right around and constantly recommend cloudflare. Can someone explain what I am missing?

[-] 418teapot@lemmy.world 2 points 11 months ago

That's wild, I've never seen an upside down port.

I agree reversibility is better and am happy usb c will finally kill this meme.

view more: next ›

418teapot

joined 1 year ago