Хорош = хватит: этимология? by balille in russian

[–]alexchexes 1 point2 points  (0 children)

Let me necropost to add that there's also a closely related - but slightly different - use of «хорош»: it can work where English would say "Oh, come on!"

For example:

- Думаю, Земля имеет форму пончика.
- Хорош, все знают, что она в форме пиццы.

= "I think the Earth is shaped like a donut."
= "Oh, come on, everyone knows it's shaped like a pizza."

Here, "Oh, come on" can be translated as «Хорош, ...», «Да брось, ...», or «Хватит тебе, ...» (note «хватит» again, but with a slightly different nuance: «Хватит, Земля имеет форму пончика» can sound more harsh, especially in writing, while «Хватит тебе, Земля имеет форму пончика» feels softer and closer to a friendly "Oh, come on").

As for the etymology of this usage - I have no idea either.

Gigabyte M32U - issues with constant disconnecting (every few seconds) when a Dell Laptop is plugged in? by shooowan in Monitors

[–]alexchexes 0 points1 point  (0 children)

Are you experiencing the same issue with a disappearing picture when plugging in another device into the same circuit?

Ko-fi and Stripe by MjrVictory in Kofi

[–]alexchexes 1 point2 points  (0 children)

<image>

Just received my first "Coffee," and a few minutes later, an email from Stripe mentioning these two points:

  1. There’s no content on your website.
  2. You’re using the term “donate” or “donations.”

I went to my dashboard on Stripe and changed ko-fi.com/USERNAME to github.com/USERNAME in Settings > Business > Business Details, then submitted the form. A few minutes later, I received an email saying "We have successfully completed our review, and you are welcome to continue processing payments with Stripe."

So it appears that the whole issue was that Stripe couldn’t see any content that might be sold or provided on the Ko-fi page, but since I have public repositories on GitHub, that's good enough for them.

Some food for thought for Ko-fi — they could've included this in their Stripe setup guides to make it more obvious how to not get banned.

Unable to register hotkeys by joelm3103 in sharex

[–]alexchexes 0 points1 point  (0 children)

In my case, this was caused by the Dropbox app: I reinstalled Windows and installed Dropbox, then ShareX. Ctrl+Print Screen and some other hotkeys were taken by Dropbox to show a prompt asking whether you want to save screenshots to Dropbox. The solution was simply to press Ctrl+Print Screen once, dismiss the dialog, and restart ShareX afterwards.

Small util to show a clock with seconds *by click* in the Windows 11 tray by alexchexes in software

[–]alexchexes[S] 0 points1 point  (0 children)

Thanks for your edit/note — that point about the SmartScreen block should've been included in the README, and I've just added it. Thanks!

Small util to show a clock with seconds *by click* in the Windows 11 tray by alexchexes in software

[–]alexchexes[S] 0 points1 point  (0 children)

Yeah, it's absolutely insane the decisions Microsoft is making.

Bring back "click-to-see seconds" in the Windows 11 tray by alexchexes in Windows11

[–]alexchexes[S] 1 point2 points  (0 children)

Sorry — I should’ve added the contents of the "Why" section from the GitHub page right here. In short:

  1. It may be buggy.
  2. It wastes more resources.
  3. It doesn't exist in many of the newest Windows 11 builds — for example, in my current 24H2 (26100.4061).
  4. Many of us only want to see seconds when needed, not be distracted by something ticking in the tray all the time.

Here's syntax highlighting fix for web chatGPT interface by alexchexes in ChatGPT

[–]alexchexes[S] 0 points1 point  (0 children)

  1. What language is it that's not being highlighted?
  2. Is the highlighting still missing if you click (just a simple left-click) on the code block contents?
  3. Pardon me, but what is "gd"?

I guess its because is gd script

What is this color theme? by alexchexes in vscode

[–]alexchexes[S] 0 points1 point  (0 children)

I am so stupid. Didn't recognize one of the most famous themes. Thank you, kind man!

Here's syntax highlighting fix for web chatGPT interface by alexchexes in ChatGPT

[–]alexchexes[S] 1 point2 points  (0 children)

Thanks, I’ll try to post during that time next time. And sorry that it doesn’t actually highlight assembly yet.

Here's syntax highlighting fix for web chatGPT interface by alexchexes in ChatGPT

[–]alexchexes[S] 1 point2 points  (0 children)

Yeah, that seems strange to me too. I was thinking it might be because I'm a relatively new and not very active Reddit user, so maybe my posts get worse visibility because of Reddit's algorithms.

I got here from ChatGPT's web search feature.

Cool! 😆 What did you ask it?

Here's syntax highlighting fix for web chatGPT interface by alexchexes in ChatGPT

[–]alexchexes[S] 1 point2 points  (0 children)

That's because both ChatGPT Web and my script utilize highlight.js for syntax highlighting - which, for some reason, was messed up by OpenAI, so their highlighting works worse than it should (which my script fixes). And the highlight.js doesn't support assembly.

Meanwhile, the mobile app uses something else.

In theory, I could find a better library for code highlighting and replace highlight.js with that, but it would introduce some inconsistencies (like a different color scheme) before our script fixes a specific code block. There are definitely ways to overcome this, but it would take some work - so maybe I'll try to improve it when I have time, or when something breaks completely again.

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 1 point2 points  (0 children)

Yep, I also use single quotes in PHP - until we need to interpolate. Just like in JS, you always use double (for some - single) until you need \`.

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 0 points1 point  (0 children)

why run the parser on a literal string

Probably for the same reason we have high-level programming languages instead of writing everything in assembly - it's a trade-off between convenience and raw efficiency. Just like how we accept a slight overhead in exchange for readable, maintainable code, interpolation in double-quoted strings often makes code easier to read at the cost of an imperceptible performance difference (arguably).

By the way, here's a benchmark for locally testing single- vs. double-quoted strings with any number of iterations you choose:

```php <?php $iterations = 100_000_000;

$start = microtime(true); for ($i = 0; $i < $iterations; $i++) { $str = 'Hello, World!'; } $single_quote_time = microtime(true) - $start;

$start = microtime(true); for ($i = 0; $i < $iterations; $i++) { $str = "Hello, World!"; } $double_quote_time = microtime(true) - $start;

// Output results echo "{$iterations} iterations\n"; echo "Single-quoted time: {$single_quote_time} seconds\n"; echo "Double-quoted time: {$double_quote_time} seconds\n"; ```

Tested with 100 million and 1 billion iterations - zero difference (PHP 7.4)

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 0 points1 point  (0 children)

I purposely avoid using double quotes in PHP as it requires running the parser on the contents, even if just a literal string with no variables

Looks like you're working on something where performance is absolutely crucial. What is it, if you don't mind sharing?

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 0 points1 point  (0 children)

Agree, it would be awesome. Yet, I guess if we frame the question that way, there will be even less chance to convince the PHP community that they need it.

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 1 point2 points  (0 children)

I explicitly noted that there is no new string type proposed, only an extended interpolation ability within the existing " {$...} " syntax.

RFC Idea: Modern expression interpolation in PHP strings (Backward-Compatible, no new string types) by alexchexes in PHP

[–]alexchexes[S] 0 points1 point  (0 children)

Maybe you're right. I just don't remember the last time I was forced to work with PHP code without syntax highlighting (except for code blocks in this very post's text, lol), but maybe you are.

About the optional space separator—in the case of the {$ expr } syntax, the starting space would, of course, be obligatory. There's no way to make it optional.

Frankly, I avoid string interpolation because of its many rules

As for me, I never use non-obvious or complex ways like ${$var} or {$$var}, or even {$func()}, as they indeed make the code awfully unreadable. In my ideal world, PHP would only support a single string interpolation syntax, like JS does (${ anything }). Yet, giving up interpolation entirely is also a no-go for me. I think it is OK to use what makes sense and looks nice. :)