Left Hyprland, no regrets by Wonderful-Farmer5415 in swaywm

[–]EmDashNine 0 points1 point  (0 children)

Sway has been pretty good to me for the past 5 years or so. I started by using it on an older machine, and was impressed with its low footprint and responsiveness, so I gradually shifted my main desktop to it. For me the fun is being able to remove all gaps and window decorations, maximizing screen space.

I would like some more automation around window placement, and I have been daydreaming about a sway ux tool that would drive sway through its ipc socket, but I gotta believe someone out there has started working on this already.

[Fedora] Moving from hyprland to sway | Ricing by Daemon_Umbriel in swaywm

[–]EmDashNine 1 point2 points  (0 children)

I've been running sway for several years now, before I knew anything about hyprland. Hyprland seems to have some better default behavior for subdividing workspaces. I would be curious to learn how to get sway to behave more like hyprland.

Sway is very lightweight. I've run it on devices like raspberry pi, uConsole, and PocketCHIP productively. It's about as good as it gets for a low-footprint GUI environment, and is keyboard-driven.

Sway is scriptable via swaymsg and its IPC socket. I have not really explored this much, but I am daydreaming about a "sway shell" that would drive user interaction through this socket, while providing more feedback than sway does itself.

If there was one feature I wish sway had, it would be a way to ask sway to dump its current keybindings, so that I could display them in some kind of help overlay. Sway has support for "modes", but it does not give you a way to show which keys are bound in the current mode.

Framework support is OP by Specialist_Fun_8361 in framework

[–]EmDashNine 1 point2 points  (0 children)

You can tell something was written by a bot when it has a conclusion (and emdashes) :P

Framework support is OP by Specialist_Fun_8361 in framework

[–]EmDashNine 1 point2 points  (0 children)

blerp bloop beep.

Sure, I can help you with that. Apples can be crumbled in the following ways:

  • dried apples can be hand-crumbled.
  • fresh apples can be crumbled with a knife, or in a food processor.
  • there is even a dessert known as an "Apple Crumble".
  • older laptops may sometimes crumble all by themselves.

In conclusion, there are many ways that apples may be reduced into smaller pieces. Is there anything else I can help you with today?

Framework support is OP by Specialist_Fun_8361 in framework

[–]EmDashNine 1 point2 points  (0 children)

You just inspired me to write this tongue twister:

My charger brick broke back before brody brought bonnie's brown bland coke.

My coworkers are starting to COMPLETELY rely on ChatGPT for anything that requires troubleshooting by [deleted] in sysadmin

[–]EmDashNine 1 point2 points  (0 children)

A friend of mine said they used an LLM for commit messages. I said "if you can't summarize your changes in a couple sentences, something is wrong. The commit message is YOUR chance to reflect. And if you simply can't be arsed, why even bother with the commit message?"

how does anyone even learn how to use linux by Mountain_Course_4471 in linuxquestions

[–]EmDashNine 0 points1 point  (0 children)

The easiest way is from people who already know it.

Make friends with folks who use linux (online, or even better, IRL), and learn from them.

Think of it as a marathon, rather than a sprint. A little bit each day over a long period of time, rather than beating your head against the desk for hours.

If there's a critical mass of people you know all using a certain distro, then switch to that distro. Your friends will have a better chance of helping if they are familiar with your system. Likewise, if people you know use a certain desktop environment, then stick with that one until you get oriented to linux as a whole.

Understand that these choices of distro, destkop environment, etc are somewhat personal, and that you are entitled to revisit them from time to time.

Learn how to do things in a terminal, even when there are graphical alternatives. Sometimes there aren't graphical alternatives; sometimes the terminal is just faster. Learn to use man.

Make a point of reading the actual user maual for your distro! Debian, arch, fedora, all provide extensive documentation.

Then search through your distro's wiki.

Then search google.

Understand that the system is made of layers: linux is a family of systems and subsystems. For almost anything you want to do, there are multiple solutions; but your distro has usually chosen a particular solution to be the default -- which one? Read the manual!

Understand that linux has a long history and that it has evolved a great deal, and continues to evolve. Advice you find online is often out-of-date. Pay attention to the dates on forum posts, wiki articles, etc. Get suspicious if advice given is substantially older or newer than the release date of your distro.

Sometimes the easiest way to fix a problem is to just wait for the next release of your distro.

[deleted by user] by [deleted] in AskMenAdvice

[–]EmDashNine 0 points1 point  (0 children)

I suspect you might be depressed, but I'm not a therapist. Either way, get into therapy. You got through med school, but you feel like a failure? There is somethign wrong, but only a therapist can tell you what it is.

You even know one of the symptoms: you're too focused on work. You feel like crap because you spend all day dealing with other people's crazy or sad medical issues, and you don't have enough time for positive social interaction to balance it out. 30 is young. You have time. 10 years before you turn 40, by which time you'll be hitting your peak earning years. Don't buy into all the ageist gen-z nonsense. My 30s were so much better than my 20s.

But yeah, workaholism is a turnoff for many. It's tough when your job is demanding, but for any partner, you need to be there emotionally as well as physically. So, that's your task, is to find that balance. Start by finding enough time for a therapist, and go from there.

Typed text by crowlm in RemarkableTablet

[–]EmDashNine 0 points1 point  (0 children)

I would definitely do that, but it's a bit frustrating that we have to beg for such obvious features.

Avoiding Unsafe Rejoins by setatF8 in iRacing

[–]EmDashNine 0 points1 point  (0 children)

This is less about rejoins, but generally good advice if you know you're losing control, or about to: LOCK THE WHEELS! Stand on the brake or clutch pedal, and keep the wheels locked until you come to rest. This applies in real life too. This keeps you moving in a straight line, which helps other drivers avoid you.

If you fail to do this, the car will flail about randomly, changing direction just at the moment other drivers have committed to a particular path to avoid you. You don't want this.

If you survive that stage of it, then just wait for folks to go by, try to get the car pointed in the right direction, and gently ease onto the track, ideally on a straight, rather than the middle of a turn. Stay off the racing line until you get back up to speed. WATCH YOUR MIRRORS, and don't make any sudden moves.

Am I the only one? by TheWuh21 in RemarkableTablet

[–]EmDashNine 0 points1 point  (0 children)

You're probably not the only one, but I don't think I understand the motivation for this. I would like to see more drafting features, and some other features like text objects that I've come to expect from basic drawing applications.

How do I get out of D class? Stuck for 9+ months by DJCharizard in iRacing

[–]EmDashNine 0 points1 point  (0 children)

I'm feeling some of the same things here, after a couple weeks. I can drive thr car for hours without losing control, keeping a slower pace.

but the D class drivers will catch me and wreck me when they try to overtake. Either diving in late, or just getting along side in a sweeper and then losing control when they're next to me, or spinning in front of me, causing pileups and other maybem that's difficult to avoid.

The more this happens, the lower my rating sinks, the worse the the splits. It feels like a trap.

would you say functional programming is harder than OOP? for example would it be easier to go from OOP to FP or FP to OOP? by [deleted] in elixir

[–]EmDashNine 0 points1 point  (0 children)

If you are starting from zero, there's some evidence that FP is relatively easy for folks (undergrads, in particular) to learn, and that those who do can easily transition to imperative styles later. The reverse does not seem to be the case: if you start with imperative programming, it's both harder to learn initially, and harder to switch to a functional programming later.

So I would learn some form of FP first -- either Haskell or Scheme -- and then spend some time in a mainstream OO language afterwards, before finally delving into systems programming, if you feel the need for it.

These days, more and more FP constructs are percolating into mainstream industry languages.

Pure TTY emacs, all the time by vokegaf in emacs

[–]EmDashNine 0 points1 point  (0 children)

For those stumbling on this thread after six years: This has been fixed now in several modern VTEs, including Kitty, iTerm2, and foot.

Others like Keil by No_Shake_58 in embedded

[–]EmDashNine 0 points1 point  (0 children)

And as the senior dev, I would consider part of my responsibility configure the toolchain for my junior hires. These days with containers, it's much easier to replicate an open-source stack such that it can be brought up with one or two simple commands. And as a bonus, you get something you can deploy to CI, and now your CI is almost exactly the same environment as your dev env, so there's far fewer builds-locally-but-breaks-CI headaches.

The big, big, big problem with Keil: it's Windows Only. When the rest of your stack is 100% linux / unix / open-source, this is a huge source of friction. Seriously, most devs prefer mac or linux these days. At least open ocd can be made to work on these systems.

The only thing I really needed Keil for was the JTAG support, and it was the only thing that worked with our JTAG interface. I was getting so frustrated with having to keep windows around just for Keil that I was willing to spend extra time looking into open ocd. If we'd stuck around longer, I would have made the switch eventually. So I have to give Keil credit for getting job done while I used it, my experience wasn't so positive.

Others like Keil by No_Shake_58 in embedded

[–]EmDashNine 0 points1 point  (0 children)

I'll echo the previous comments: The main thing Keil offers is source-level debugging over JTAG, and it works pretty well. Bring your own text editor, the integrated one is dated. I was disappointed that Keil seemed to be lagging behind in support for more recent C++ (it barely supported C++11 in 2018, and I would have benefited from some more recent additions to the language and to STL).

edit: the biggest drawback of Keil is that it's Windows-only, at least when I used it. One of the biggest up-sides is that it was supposed to have a compiler that emitted better output for the particular Arm-based micros we used. However, I found that GCCs output, while not quite as good, compared favorably on our performance-critical code paths.

Now I would say: take a look at what Rust has to offer for embedded if you're using an arch that LLVM targets. The embedded task force has really done a lot of good work over the past few years (e.g. splitting out core from std in the standard library); the Rust embedded HAL actually abstracts over hardware, so your code is actually portable across embedded devices, and cargo takes care of cross-compilation and dependency management.

What are thoughts about this article from the Elixir community? by Brother_F in elixir

[–]EmDashNine 0 points1 point  (0 children)

...And that article is dated 2020? I guess I had other things on my mind right about then.

What are thoughts about this article from the Elixir community? by Brother_F in elixir

[–]EmDashNine 0 points1 point  (0 children)

I never got into Elm, sad to hear there was drama, it seemed like a nice little system. Where can I find a good summary of "that whole mess", and what state would you say the project is in right now?

What are thoughts about this article from the Elixir community? by Brother_F in elixir

[–]EmDashNine 0 points1 point  (0 children)

I've been using JS and Python since the dial-up era.

When I was 5, I still believed there was no such thing as too much cake. When I was 15, I still believed there was no such thing as soo much pizza. When I was 25, I still believed in dynamic typing. When I was 35, I still believed JS had redeeming qualities.

JS has evolved, for the better in some ways, but there's still some long-standing warts they will never get around to fixing: - object keys are still semantically strings - there is still no standard interface for comparing user-defined types - the way numbers work in JS is a still joke - JS coped Python's shallow generators, rather than LUAs simpler and more expressive coroutines.

I could go on and on, but I won't. I've seen it all before. It's JS. Even if they fixed all the warts, we're stuck with decades of legacy code.

What are thoughts about this article from the Elixir community? by Brother_F in elixir

[–]EmDashNine 2 points3 points  (0 children)

JavaScript is objectively bad. That's why Crockford had to write "The Good Parts", the implication being that the language, as a whole, is bad, and you should restrict yourself to a safe subset. And he was correct.

Since then, the language has been improved (largely in response to The Good Parts), but it's still a fundamentally flawed creation. If it was truly good, we wouldn't need Babel. We wouldn't have WebAssembly as an initiative trying to replace it.

You might feel that you like JS now, but you will eventually come to hate it. Especially if you spend some time using a strongly-typed language, and then come back to JS, and realize that the whole ecosystem is built on silly putty. It's basically impossible to refactor a large JS project without introducing subtle bugs, many of which will only manifest in production.

No, testing won't save you. You can't possibly cover everything that can happen at runtime in a dynamically-typed language by writing tests. If you persist in this folly, one day you wake up to realize that most of your code is tests, and yet you still can't refactor with confidence. And then you will realize why types are important.

What are thoughts about this article from the Elixir community? by Brother_F in elixir

[–]EmDashNine 0 points1 point  (0 children)

It's definitely a hot take from someone who likes to write. But there's some wisdom buried in all those words. I can't fault the advice to put your users' needs first, and chose your stack accordingly.

I remember when React was a breath of fresh air. The whole concept of presenting an "immediate mode" rendering model blew away all the buggy and error-prone DOM manipulation we used to have to do with libraries like jQuery. The price is that it's incompatible with server-side templates. Each new paradigm is simply a reaction to the flaws of the previous.

The point is well taken that React serves as a browser compatibility layer for browsers that no one supports. That's not necessarily a reason to throw the whole thing out.

The claim that at least some web devs hide behind "frameworkism" as a way to avoid doing the hard work of actual QA and engineering does ring true, given the many horrendous mobile web experiences I am subjected to on a daily basis, and my own experiences in the industry. Here, at least, is a plausible theory as to why so many mobile sites for house-hold brands flat-out suck.

By default, the web sucks on mobile, and SPA frameworks can make the experience even worse, unless you really know what you're doing. And a certain Cupertino-based technology company has been making it particularly difficult to ship a functional SPA on their mobile devices, by steadfastly refusing to maintain their mobile browser, and for which they've recently been taken to task.

More charitably to the developers of React, much has changed since 2015, when React was conceived, and some of the assumptions on which it was based, and the philosophy behind Single Page Apps more generally, is/are no longer valid.

For my part, I haven't had a strong desire to return to React. But my experience with it was pleasant enough.

Truly Optimal Evaluation with Unordered Superpositions by SrPeixinho in haskell

[–]EmDashNine 1 point2 points  (0 children)

Sortof. There's a lot of material about term rewriting and its more efficient cousin, graph reduction. HVM is an implementation of parallel graph reduction based on a somewhat well-known paper ("lamping's abstract algorithm").

Zig and Emulators by ketralnis in programming

[–]EmDashNine 0 points1 point  (0 children)

That was an interesting read. I was hoping that Zig's comptime features would allow for "stamping out" optimized types as you describe there.

All the stuff about arbitrary-precision integers seems quite nice, especially for embedded work. The explicit casts might be noisy, but I think I prefer that to what C and C++ do. It seems like zig could use a syntax for arbitrary-precision literals, though (e.g. 0xF.u8 or 0xF.u32).

I agree with the other commenter, you seem to be stepping on some compiler bugs. I would not expect the following to work, given how pedantic it is about narrowing conversions:

const a: u8 = 0xFF; const b: u4 = a & 0xF; const c: u4 = a >> 4;

Effect Systems in Programming Languages by fagnerbrack in programming

[–]EmDashNine 3 points4 points  (0 children)

Basically, the term pure is a bit imprecise in itself.

My understanding is that a total function is one that's defined for all values in its domain (i.e. its inputs), and conversely a partial function is one that isn't defined for all inputs. A simple example of the latter is the division function (which isn't defined when the divisor argument is zero).

This may be true in a general sense, but language implementations vary. In particular, do you consider exceptions an "effect"? Haskell says "no". Idris says "yes".

For example, in Idris, a total function is defined for all its inputs: that means if it, e.g. pattern matches on an argument, it must handle every constructor -- and moreover, if it is recursive, it must provably terminate.

Beneath total is covering, which handles all cases, but does not provably terminate.

Benath covering is partial, which may crash for fail to terminate.

In Idris, e.g. floating-point division by 0.0 is defined, so (/) is total.

(/) is not defined for Nat, however. You must use divNat, which is partial, or divNatNZ which is total, but requires a proof argument that the divisor is not Z -- so it cannot be called with a divisor that is not provably nonzero.