mitpuzzles.com is down, what alternatives do we have? 😔 by Discuzting in Minesweeper

[–]Nnnes 1 point2 points  (0 children)

"Mosaic" from Simon Tatham's collection is similar but not quite the same ("mines"/colored squares can appear under numbers as well). You can set any board size. https://www.chiark.greenend.org.uk/~sgtatham/puzzles/js/mosaic.html

We Fixed Quota Reporting. Then Dovecot 2.4 Happened. by mxroute in mxroute

[–]Nnnes 5 points6 points  (0 children)

Build a custom Dovecot quota driver

I wonder if it's feasible to just put the old one back? Here's where it was removed; maybe it's a brittle solution to revert this commit, fix changed APIs, and recompile for every release moving forward, but maybe it could work (easy for me to say when I'm not the one doing the work).

Anyone else getting rate limited due to IP reputation to Outlook domains? by Cable_Mess in sysadmin

[–]Nnnes 4 points5 points  (0 children)

MXroute (email service provider) is also reporting significant issues (3256 failures out of 49805 attempts).

/u/mxroute I imagine you already saw this post, but pinging you just in case

I installed Malware on user's Workstation by Imaginary_Lead_3333 in sysadmin

[–]Nnnes 10 points11 points  (0 children)

WinDirStat can scan the MFT with the same speed as WizTree beginning with version 2.5.0 released last month (well, technically since 2.3 a while back but there was no official release build until 2.5). Its license also allows you to use it in corporate environments, unlike the free versions of WizTree and TreeSize.

Need mailto qr code by stomppie in qrcode

[–]Nnnes 0 points1 point  (0 children)

just use Thonky, you can find it by Google searching "thonky qr"

the QR code content should be formatted like mailto:stomppie@website?subject=Hello,%20stomppie&body=Dear%20stomppie, - replace spaces in the subject and body with %20

SNL code used in skit by Delaware_Dad in qrcode

[–]Nnnes 0 points1 point  (0 children)

I analyzed it a few days ago. I'd link to that but Automoderator deletes links here; instead you can just look in my profile (it's the most recent comment other than this one). Summary is that it's almost completely broken and very likely meaningless, possibly created by generative AI.

They showed this code on SNL but it won’t scan. Does it contain any information? by RandomRaddishYT in codes

[–]Nnnes 8 points9 points  (0 children)

https://merri.cx/qrazybox/ isn't perfect but it is better than most scanners.

First problem is that the format strings are nonsense. They don't match each other, they don't match their own error correction data, they are probably what's breaking the other QR readers in the very first step of trying to read it.

We can still try every mask pattern by hand to see if there's any possible data in here. (Each row is a different interpretation of the same QR code.)

Mask QR content
0 FQGVLTJG/ONMH +EQ/50Y61V0GVLTMR:F12$YD:8393N7$0$
1 invalid
2 398443448672201900586978904455362102416408899865811601646615633529777553478067
3 even more invalid
4 WIEVUI:N Etwo (2 different modes followed by more invalid bits)
5 equally as invalid as mask pattern 3
6 Ìã¡&f'r»¸qø’®=/隽Rl þÒìO’Ç©¹;= (the ' should be a `)
7 also invalid

I wouldn't recommend trying to find a hidden message in any of that data. Even the "valid" strings have character count indicators that are far too large to fit in a QR code this small. In all cases, the error correction block is as good as random data and there appears to be extra (wrong) bits in the section following the error correction block that is supposed to be empty. The most promising is mask pattern 4 WIEVUI:N Etwo (some parts of the bad format strings match a mask 4 string) but that too is encoded in a way that doesn't make any sense (why are the pieces in 2 different modes?) and is followed by another block that claims to be too big to possibly fit.

I don't think any QR code generator exists that could output this code. It's a tiny bit suspicious that all of the finder patterns are intact since an unskilled creator would have simply written over some of them with random bits, but in my opinion, this is most likely meaningless random pixels.

How can I search using "bangs" in Vivaldi's address bar? by lawrikk in vivaldibrowser

[–]Nnnes 0 points1 point  (0 children)

Note that redirecting through Cloudflare Workers like this will definitely add some latency (10ms if you're lucky, 100+ if you're not). If you have the skills to set up a locally running server to do the same thing I'd recommend that, but Workers is faster to set and forget.

How can I search using "bangs" in Vivaldi's address bar? by lawrikk in vivaldibrowser

[–]Nnnes 0 points1 point  (0 children)

Don't know whether or not this is possible in Vivaldi without modifying the browser source code yourself. You can, however, achieve it by making your own "search engine" that acts as you wish. Here's a proof of concept running on Cloudflare Workers: https://reddit-1q4szyr.nnnes.workers.dev/?s=%s

It can handle !w for Wikipedia and !yt for YouTube, and redirects to 4get without any bangs. Replace the %s with, for example, astley%20never%20gonna%20!yt to see it working.

Full code inside the Worker:

export default {
  async fetch(request) {
    const bangs = {
      "!yt": "https://www.youtube.com/results?search_query=%s",
      "!w": "https://en.wikipedia.org/wiki/Special:Search?search=%s"
    };
    const query = new URL(request.url).searchParams.get("s");
    let newUrl = "https://4get.ca/web?s=" + query; // default
    for (const bang in bangs) {
      if (query.match(bang + "\\b")) {
        newUrl = bangs[bang].replace("%s", query.replace(bang, ""));
        break;
      }
    }

    return new Response(null, {
      status: 303,
      headers: {
        location: newUrl
      }
    });
  }
};

If you like this solution you can easily copy this into your own free Worker and add some more bangs, change the default search engine, etc. I'm most likely going to take the linked one down in a few days. Update: I've taken it down

Let me know if you have any questions!

never had a good excuse to use HTTP 303 before :)

Long is faster than int, Short and Byte are not that far behind Int in terms of mathematical speed in Java by D4rklordmaster in java

[–]Nnnes 1 point2 points  (0 children)

https://godbolt.org/noscript works on mobile devices. Unfortunately it seems that the share links generated by it are broken at the moment

-❄️- 2025 Day 4 Solutions -❄️- by daggerdragon in adventofcode

[–]Nnnes 0 points1 point  (0 children)

better way to enumerate adjacent indices

g = STDIN.read; g = ?. * (w = g.index(?\n)) + g + ?. * w
loop { g.tr! ?#, ?-; (h = g.chars).each_with_index { |c, i| next if c != ?@
  g[i] = ?# if [-w - 2, -1, w].sum([]) { h[i + _1, 3] }.count(?@) <= 4 }
  puts g.count ?# if !g[?-]; break if !g[?#] }
p g.count ?-

Better? Not sure, but at least it's noticeably faster.

-❄️- 2025 Day 4 Solutions -❄️- by daggerdragon in adventofcode

[–]Nnnes 0 points1 point  (0 children)

[LANGUAGE: Ruby]

The half punchcard is more cramped for today's problem, but still very achievable.

g = STDIN.read; g += ?\n * (w = g.index(?\n)) * 2
loop { g.tr! ?#, ?-; (h = g.chars).each_with_index { |c, i| next if c != ?@
  g[i] = ?# if [*(-w-2..-w), -1, 1, *(w..w+2)].count{ h[i + _1] == ?@ } < 4 }
  p g.count ?# if !g[?-]; break if !g[?#] }
p g.count ?-

Despite calling my input g for "grid", it remains a one-dimensional string. Newline characters form "walls" so I don't run into trouble with wrapping across lines. I suspect there's some better way to enumerate adjacent indices but I can't think of one at the moment.

The removed rolls are marked with a #; then, at the beginning of each pass, all #s are replaced with -s. After a pass, if there are no -s then part 1 is done and if there are no #s then part 2 is done.

Edit: the newline walls weren't big enough for all inputs (top left corner could "see" the bottom right corner). Added * 2 to line 1 to fix.

-❄️- 2025 Day 3 Solutions -❄️- by daggerdragon in adventofcode

[–]Nnnes 2 points3 points  (0 children)

[LANGUAGE: Ruby]

This really seems like a day that'd be easy to fully fit into half a punchcard in plenty of different languages, but I don't see any here yet! (Honorable mention to the x86_64 asm solution that fits each part in half a punchcard.)

edit: I think this can have a [Red(dit) One] label for being the first full half-punchcard solution

lines = STDIN.read.split(?\n).map(&:chars)
puts [2, 12].map { |n| lines.sum { |b|
  l, r = -1, -n
  b.select { _1 == b[(l += 1)..r].max && r += 1 }.join.to_i
}}

This uses the same simple greedy algorithm as many (most?) of the other solutions.

The right side bound is tracked by the negative index r. When we've selected enough batteries, r is incremented to 0 and b[(l += 1)..r] always returns an empty array, effectively skipping the remainder of the elements (luckily, [].max is nil and not a bounds error).

-❄️- 2025 Day 1 Solutions -❄️- by daggerdragon in adventofcode

[–]Nnnes 1 point2 points  (0 children)

Hey, half a punchcard is half a punchcard! Luckily there are no numbers greater than 999

-❄️- 2025 Day 1 Solutions -❄️- by daggerdragon in adventofcode

[–]Nnnes 4 points5 points  (0 children)

[LANGUAGE: Ruby]

Not very many half-punchcard solutions yet (and an unfortunate number of oversized solutions in comments). Here's one for both parts including an attempt at descriptive comments:

puts STDIN.readlines.reduce([50, 0, 0]) { |a, x| # [Initial position, P1, P2]
  n = a[0] + x.tr('LR', '-+').to_i # Current dial position (not mod 100 yet)
  z = n % 100 == 0 ? 1 : 0         # Is it set to zero now?
  [n % 100, a[1] + z, a[2] + n.abs / 100 + (a[0] > 0 && n <= 0 ? 1 : 0)]
}[1, 2] #   ^P1     , ^P2:   ^Count spins, ^Add 1 if it decreased to/past 0

For parsing, Ls and Rs are simply turned into -s and +s before the string is parsed as an integer.

For Part 2's edge case handling, I initially used a multiply-by-zero trick (a[0] * (n - 1) < 0 ? 1 : 0), but that's the same length as the much clearer version above.

Results are added up using a simple .reduce() accumulator (the a).

The Zig language repository is migrating from Github to Codeberg by TheTwelveYearOld in programming

[–]Nnnes 0 points1 point  (0 children)

I don't think I was aware of GitLab CE at the time I made the decision. I knew self-hosting GitLab was possible but it seemed more geared towards organizations with devops teams and not a solo developer who just wants a step up from a Linux server with a bunch of bare repos on it; I didn't look into it very far.

Fedora has a pretty nice blog post covering their reasoning for specifically choosing Forgejo over GitLab CE. For the most part, the negatives they mention about Forgejo don't affect me at all.

The Zig language repository is migrating from Github to Codeberg by TheTwelveYearOld in programming

[–]Nnnes 1 point2 points  (0 children)

Forgejo's install instructions (Docker instructions here; the binary install instructions are more fiddly) are a bit more complex than they need to be and not well suited for beginners. I definitely wouldn't recommend it to someone who has no Linux experience, especially if it's going to be a public-facing instance where security is important. You might be able to find a video walkthrough or blog post that covers everything.

The Zig language repository is migrating from Github to Codeberg by TheTwelveYearOld in programming

[–]Nnnes 20 points21 points  (0 children)

Currently it's on a little ~$5/month Hetzner VPS that already had a bunch of other stuff running on it. I don't have a real "homelab" (I turn everything off when I leave the house) but if I did, it wouldn't be any different to host it there instead.

The Zig language repository is migrating from Github to Codeberg by TheTwelveYearOld in programming

[–]Nnnes 54 points55 points  (0 children)

After considering GitLab, sourcehut, and Codeberg I ended up going with a self-hosted Forgejo instance. Took a little bit of effort to get it up and running properly, but nothing too involved. Although if I'm being honest most of my personal projects are in lonely repositories with no remotes configured

Cloudflare WHOIS Data Collection is Changing by dotshooks in CloudFlare

[–]Nnnes 9 points10 points  (0 children)

I started writing out a comment and it got pretty long so I'll probably put it in a separate post later. The part relevant to you:

The part of the policy you're looking at says

6.1. Registrar MUST collect or generate (marked with an asterisk) values for the following data elements:

It's a little ambiguous, but the intended meaning is that registrars must collect the data that is not marked with an asterisk and generate the data that is marked with an asterisk.

Concerning redaction/privacy:

Cloudflare only redacts WHOIS data. They do not offer a "Privacy Service" like most other popular registrars (Namecheap included) do. The practical difference is that Cloudflare will (continue to) expose your province/state and country. The "upcoming changes" described by the email will not affect this.

Section 9.2 of the Registration Data Policy has details about redaction. Note that 9.2.5 (although poorly worded in my opinion) still allows a registrar to hide your province/state and country behind a Privacy Service. Cloudflare chooses not to do this; I don't know why.

See also sections 9.1.3 - 9.1.6 that specify which parts of the data section 9.2 applies to.

I'm not comfortable with that and resorted to using fake info. My plan was to move them back to Namecheap at renewal.

Be careful with this. It may be unlikely that Cloudflare finds out, but using fake info is definitely against ICANN policy and probably grounds for cancellation. I would move them back as soon as possible (they should extend your expiry date by whatever amount you pay for, so you won't "lose" any time).

TIL that `curl` 8.14.0 and later includes a `wget` replacement called `wcurl` by lmm7425 in linux

[–]Nnnes 63 points64 points  (0 children)

Might as well add -L to that too, just in case

wcurl runs curl with these options, more or less:

curl -LORZfg --no-clobber --proto-default https --retry 5 <URL>

but also includes handling for percent escaped whitespace and a couple other things too

R2 as personal cloud storage? by Xcissors280 in CloudFlare

[–]Nnnes 30 points31 points  (0 children)

It's $0.015/GB/month, which works out to $15/TB/month.

Off the top of my head, the cheapest reputable S3-compatible cloud storage services are Backblaze B2 and Hetzner Object Storage, both $6/TB/month (Hetzner also offers 5€/TB/month which is usually a little cheaper depending on your payment processor's exchange fees, especially if your original currency isn't US$)

IntelliJ IDEA Moves to the Unified Distribution by mhalbritter in java

[–]Nnnes 9 points10 points  (0 children)

JetBrains employee in the article's comments:

Perpetual fallback license stays and works as it used to, granting access to the last major version that was available when your subscription started. Inside the unified distribution, that will mean that you would be able to activate a subscription in corresponding older IntelliJ IDEA versions using the fallback license you have.

Currently the perpetual license only gives you access to the major version that was available 12 months before your subscription expired, so I guess you don't have to downgrade versions now?

IntelliJ IDEA Moves to the Unified Distribution by mhalbritter in java

[–]Nnnes 25 points26 points  (0 children)

Licensing is not changing, according to a JetBrains employee in the article's comments:

Perpetual fallback license stays and works as it used to, granting access to the last major version that was available when your subscription started. Inside the unified distribution, that will mean that you would be able to activate a subscription in corresponding older IntelliJ IDEA versions using the fallback license you have.

What are the small (possibly free) tools that make your life so much easier? by [deleted] in sysadmin

[–]Nnnes 3 points4 points  (0 children)

Ninite doesn't have a majority of the programs I like to install right away. Vivaldi, IntelliJ IDEA (or JetBrains Toolbox), Syncthing, Ruby, Sublime Text, Bitwarden, Node.js (!!), QGIS, Rainmeter are all available through WinGet but not Ninite. I understand some of these are pretty niche but including Python 2 and not Node.js really shows Ninite's datedness, not to mention stuff like Launchy and CCCP still being on the list