Hacker News new | past | comments | ask | show | jobs | submit | notpushkin's comments login

It also usually sours I think? You can still use that for pancakes or something... not sure because I’m too lazy and throw it away myself.

Aurora Store also runs a bunch of their own throwaway Google accounts you can use (the “anonymous” option on the sign-in screen). Usually works great, though sometimes takes a few tries to get a working account.

Many apps do require passing the integrity check, though, but microG is getting better on that front (and IIRC you don’t need a Google account for that).


Absolutely unrelated, but there’s a Haskell-like syntax for Python: https://web.archive.org/web/20241205024857/https://pyos.gith...

  f = x -> raise if
    x :: int  => IndexError x
    otherwise => ValueError x
Complete with pipelines, of course:

  "> {}: {}".format "Author" "stop using stale memes"
    |> print

not too far from that there's https://coconut-lang.org/

Wow, this is so awesome! A shame it didn’t progress.

I’m wondering how’s it going with the whole dual-licensing schtik.

Containers part I can understand. Why not spin up a tiny Docker Swarm (or k3s/k0s) cluster instead of straight out going to Google though?

Because those other things require more maintenance effort to run.

Getting creative is often just a pain in the ass. Doing the standard things, walking the well-trod path, is generally easier to do, even if it may not be the cheapest or most hardware/software-efficient thing to do.


I still love Sentry, but it’s so enormous now that it isn’t practical to self-host for smaller businesses. A “small” alternative is always great to see!

I’m not sure how I feel about the license though (Polyform Shield, basically use-but-don’t-compete). It’s a totally valid choice – I just wish it would convert to FOSS at some point. (I understand the concern as I’ve had to make a similar decision when releasing https://lunni.dev/. I went with AGPL, but I’m still overthinking it :-)


You can start by looking at https://kagi.com/stats?stat=leaderboard and adjusting domains that make sense to you. E.g. I have all Pinterest lowered, as well as w3schools.com as I prefer developer.mozilla.org (which I raised instead).

For bangs I’m pretty sure the default ones might be enough – just use them! Some of my go-to bangs are !gh, !gm for Google Maps (Kagi Maps are sometimes not as good in Asia), !yt, !mdn, and !amo for addons.mozilla.org.

I also have this redirect rule:

  ^(https://www\.nytimes\.com.*$)|https://archive.ph/2025/$1
So that if an NYT article comes up in the results I can get a version without paywall directly. You can set it up in https://kagi.com/settings?p=redirects.

I just stumbled across cooked.wiki recently. It allows you to convert any bullshit online recipe to a no-frills ingredient list and instructions. I've only tested it a couple times and I know I'll rarely remember to use the shortcut (https://cooked.wiki/<recipe-url>). But setting it up as a redirect rule from search results might be the thing that pushes usability over the top.

If it is what I think it is, it’s extremely neat. Parsing both HTML and templating syntax at the same time is way more robust than doing just the templating and hoping for the best.

I was thinking about something like this, but with some blend of Jinja2 / Twig / Nunjucks [1] syntax and Svelte/JSX-like use of variables in element attributes:

  {% for para in page.body %}
    <p class={{ para.class }} {{ **para.attrs }}>
      {{ para.text }}
    </p>
  {% endfor %}
---

[1]: the irony is not lost on me that I’m mentioning Python, PHP and JS template engines in a Ruby discussion :-) Liquid is the closest equivalent I think, but there was some crucial piece missing last time I had to use it, though I can’t remember what exactly.


I've been working with FastHTML and I have to say, I rather enjoy HTML-markup-as-objects.

It works pretty seamlessly and you get something like this:

    @app.post('/part/add')
    def create_part(part_number: str, name: str, description: str):
        p = Part(part_number=part_number, name=name, description=description)
        p.save()
        return (p,
            Input(placeholder="part number", id="part_number", hx_swap_oob='true'),
            Input(placeholder="description", id="description", hx_swap_oob='true'),
            Input(placeholder="name", id="name", hx_swap_oob='true'))
Note, I'm not using FastHTML's built-in database interface. I prefer a little less implicit than the strict FastHTML style.

Phoenix (Elixir) has a very elegant version of that, without the need for the extra indent:

  <p :for={para <- paras} class={para.class} {para.attrs}>
    {para.text}
  </p>
With :for being a list comprehension.

I was afraid at first this is the only option (which makes it difficult to generalize this to loops with body consisting of anything but a single element). But as an optional shorthand it is indeed pretty neat! (Personally though, I still like explicit “layering” of a separate `for` block a bit more.)

Interesting! I actually find the in-lined forms far more explicit. For me, the use of `<%=` blocks tends to muddle the structure of the underlying HTML, so I avoid them where possible (not always the case though, as you rightly note).

This is something you could do with tree-sitter https://tree-sitter.github.io/tree-sitter/

I'm not seeing any ERB here. Whatever blend you came up with could be done in ERB which just combines Ruby with HTML.

Template engines like liquid are good for simpler use cases where you'd want your end users to write templates (who aren't programmers)


Yeah, that’s intentional — I think having a clear separation between templates and code is a good thing. Regardless, you can use most of Python syntax in Jinja2 (and in my interpretation too, of course).

And no, it’s not only good for simple use cases. Template inheritnace alone is a killer feature for bigger projects: https://jinja.palletsprojects.com/en/stable/templates/#templ...


I’m not sure it’s targeted towards those not familiar with Ruby... though yeah, at least mentioning it’s a templating engine would make it a lot easier to grasp.

(ERB is, I think, “embedded Ruby”, and it functions basically like old school PHP: you just insert pieces of Ruby code wrapped by <% .. %> or <%= .. %>: https://github.com/ruby/erb#recognized-tags)


ERB is also the default templating language of Rails. I wish Django would use an embedded Python instead of the mutilated tool it uses in its own templates. Not only it's yet another language to learn, but it's also underpowered and it forces developers to define custom tags and filters where a call to a method of a plain Python object would be enough. Apparently they are afraid that people embed logic in the templates but I've seen db calls inside the Python code of the custom tags. There is no perfect defense.


endfor, so it's not 100% real Python but I see that handling structure with indentation inside an HTML file could be a problem. Sometimes it's a problem even inside a Python file. I often have to undo and start again after moving code around. "Was that line inside the if or outside it?"

Would be a nice touch if Squiggle supported the `a~b` syntax :^)

Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: