[-] hallettj@beehaw.org 16 points 4 months ago

Oh is that where all the memes went? My instance isn't federated with lemmy.world so it just looked like the star trek energy vanished.

While I'm here... I finally finished season 4 of Discovery. That show has been getting much stronger as it goes on IMO. I especially enjoyed the last ~3 episodes! I also like the take on the "villains" of the late season (the two humanoid ones). It's a refreshing departure from unsympathetic, plain evil antagonists.

[-] hallettj@beehaw.org 28 points 5 months ago

Wayland replaces the older X protocol. It doesn't have to operate with older protocols. You might be thinking of XWayland which is a proxy that receives X API calls from apps written for X, and translates those to the Wayland API so that those apps can run under Wayland implementations. Window managers can optionally run XWayland, and many do. But as more apps are updated to work natively with Wayland, XWayland becomes less important, and might fade away someday.

PipeWire replaces PulseAudio (the most popular sound server before PipeWire). Systems running PipeWire often run pipewire-pulse which does basically the same thing that XWayland does - it translates from the PulseAudio API to the PipeWire API. It's a technically optional, but realistically necessary compatibility layer that may become less relevant over time if apps tend to update to work with PipeWire natively.

So no, both Wayland and PipeWire are capable of operating independently of other protocols.

[-] hallettj@beehaw.org 16 points 5 months ago

Oh this is just the thing for playing bard, and casting "vicious mockery" several times per combat

[-] hallettj@beehaw.org 23 points 5 months ago

The justification for invading Iraq was a claim that they were developing nuclear weapons. It was well known at the time that the evidence was flimsy, and that even if true it was a flimsy excuse for an invasion. The main piece of evidence was an intercepted shipment of aluminum tubes that were soon shown to have nothing to do with a nuclear program. (See https://en.m.wikipedia.org/wiki/Iraqi_aluminum_tubes). That one is not a conspiracy theory.

7
submitted 5 months ago by hallettj@beehaw.org to c/neovim@programming.dev

Posting just because I looked all over and didn't see an answer. This function expands its arguments to canonical, absolute file paths, and tests whether one is a string prefix of the other. It also works for checking whether a directory is inside of or is identical to another directory.

local is_file_in_directory = function(file_path, directory_path)
  local file = vim.fn.fnamemodify(file_path, ':p')
  local dir = vim.fn.fnamemodify(directory_path, ':p')
  return file ~= nil and dir ~= nil and
      -- is dir an initial substring of file?
      file:find(dir, 1, true) == 1
end

This came up because I'm setting up obsidian.nvim which looks like a handy way to get the best of both worlds between Obsidian and Neovim. I'm setting up some custom configuration to automatically change the selected Obsidian workspace when I cd into vault directory, and to set conceallevel = 1 only on files in a vault, and that requires checking whether the working directory or a file path is inside a given vault directory.

[-] hallettj@beehaw.org 18 points 6 months ago

Debian unstable is not really unstable, but it's also not as stable as Ubuntu. I'm told that when bugs appear they are fixed fast.

I ran Debian testing for years. That is a rolling release where package updates are a few weeks behind unstable. The delay gives unstable users time to hit bugs before they get into testing.

When I wanted certain packages to be really up-to-date I would pin those select packages to unstable or to experimental. But I never tried running full unstable myself so I didn't get the experience to know whether that would be less trouble overall.

[-] hallettj@beehaw.org 38 points 7 months ago

Wow, this is one of the most complicated Snopes analyses I've seen. But it seems like the statement is accurate with caveats. If the brightest component of Polaris is probably 50 million years old what was there before wasn't really Polaris. And then it doesn't make a difference whether sharks have been around for 450 million or 195 million years.

[-] hallettj@beehaw.org 15 points 8 months ago

Maybe a better case study would be figs since people actually eat those. From what I'm seeing in search results there is some difference of opinion, but maybe the prevailing opinion is that figs are fine for vegans because they are not intentionally exploitative or cruel to animals.

1
submitted 8 months ago by hallettj@beehaw.org to c/nixos@lemmy.ml

This is something that I struggle with. I know how to find top-level packages like git or cowsay. But what about utilities under nested paths? I always spend ages digging through the nixpkgs source code to try to find utilities to use in my nix expressions.

Today I want to use buildRustPackage. It's defined here, and is propagated here. But how do I access it given a pkgs variable? I have no idea!

https://search.nixos.org/packages is no help

nix search nixpkgs doesn't find it

I think I need to search by attribute name, not by derivation name. But I don't know how to do that.

[-] hallettj@beehaw.org 16 points 8 months ago

I think the takeaway from that episode is that many carbon offsets are scams, not necessarily all. So don't take corporate claims that they offset their emissions at face value, and consider carefully before you buy offsets.

Take a look at my other comment about Wren and Wendover Productions. (This John Oliver episode happens to include an excerpt from the Wendover piece I mentioned.)

1
submitted 8 months ago* (last edited 8 months ago) by hallettj@beehaw.org to c/nixos@lemmy.ml

It took me a while to figure this out. I use Home Manager to manage my Gnome settings by setting dconf.settings = { ... }. My settings are non-trivial (for example my paperwm module). So it's helpful for me to check the actual dconf settings that Home Manager produces.

To do that build your configuration with home-manager build, open result/activate, and find a line that looks like this:

$DRY_RUN_CMD $DCONF_DBUS_RUN_SESSION /nix/store/4ab7dx08wx640444m71axlqvbrvz73bv-dconf-0.40.0/bin/dconf load / 
  < /nix/store/0hdnvwx8d9sifd6ib8n2hhblyblq0ccp-hm-dconf.ini

The store path for hm-dconf.ini has the settings.

Edit: added a line break to the script line so you can see the relevant store path

[-] hallettj@beehaw.org 53 points 8 months ago* (last edited 8 months ago)

I'm finding this mess interesting: the MAGAs vote and debate like a third party, which kinda gives us a House with no majority party which is something we usually don't get to see in America. And we're getting the deadlocks that come from a chamber that isn't willing to form a coalition - or at least not a reliable one.

I just hope the next speaker candidate doesn't try for the same Republican-MAGA coalition. Although I'm prepared to be disappointed. Do you think there's any chance a Republican would offer to sideline the MAGAs to get support from Democrats?

Under this analysis the Democrats have a plurality. How does that tend to work out in governments with more than two parties?

1
submitted 9 months ago by hallettj@beehaw.org to c/nixos@lemmy.ml

I have a workaround so this isn't exactly a problem for me. I'm just curious about what is going on, and what best practices are.

I'm setting up Arion. I think it will be helpful for my development flow in a project where I have several services that need to run and communicate with each other. Docker-compose is a nice way to handle this, but you have to have a Docker image to run, and it's a pain to create a new image after each code change. OTOH Arion will run an arbitrary command, and creates Nix-friendly images automatically. Very promising!

The Nix expression for the service I'm developing is exported from a flake, while the arion executable reads its configuration from a Nix expression that is not a flake. There is an example configuration that recommends importing a flake using builtins.getFlake which you can see here: https://github.com/hercules-ci/arion/blob/main/examples/flake/arion-pkgs.nix

The problem is that builtins.getFlake is slow. It adds >20s to every arion command I run. That includes starting services, reading logs, removing stopped containers, etc.

The example config includes a fallback that loads the flake using flake-compat instead of builtins.getFlake. When I use flake-compat loading the flake is nearly instant.

So I'm using flake-compat, and that seems to be working. (Many thanks to the flake-compat author!) But I'm curious why builtins.getFlake is so slow.

5
submitted 9 months ago by hallettj@beehaw.org to c/neovim@programming.dev

I've had a problem making commits with fugitive for a long time, over a number of versions of Neovim. Has anyone seen this error before? I've searched a number of times but not found anything.

I use the cc binding in a fugitive window to open a split to write a commit message. Then I run :x to close the split and finish the commit. Most times - but not every time - I get this error message, the commit is not made, and the fugitive window becomes blank.

g`"                                                                                                                            
Error detected while processing BufEnter Autocommands for "fugitive://*//"..function 81_ReloadWinStatus[11]..81_Reloa
dStatusBuffer[6]..fugitive#BufReadStatus[364]..BufEnter Autocommands for "fugitive://*//"..function 81_ReloadWinStatus[11]
..81_ReloadStatusBuffer[6]..fugitive#BufReadStatus[292]..BufReadPost Autocommands for "*"..function fugitive#Resume[5]..<s>81_RunWait:                                                                                                                 
line   29:                                                                                                                     
E242: Can't split a window while closing another

I don't know what the deal is with the g`" line in messages. That might be a clue?

This does not happen when I make a commit without writing a message - for example when I use ce to amend the last commit without editing the commit message.

[-] hallettj@beehaw.org 25 points 9 months ago

I remember finding this Practical Engineering video on Roman concrete to be informative: https://youtu.be/qL0BB2PRY7k?si=5exDGyEK_LTfGNOy

Veritasium also has a chapter on ancient concrete in this video: https://youtu.be/rWVAzS5duAs?si=EJ8rPDTPHlq90kgW

My memory is fuzzy, but I think some of the details are:

  • We know how to make Roman concrete, but it's not necessarily the best choice, and it might be more expensive than is appropriate for a given project.
  • Ancient structures don't have rebar, so they don't degrade due to rust causing expansion. But rebar is so useful that it's often a worthwhile trade-off.

Definitely see the other comments here about survivorship bias, and higher demands on modern structures.

1
submitted 9 months ago by hallettj@beehaw.org to c/nixos@lemmy.ml

Instead of getting plugins through nixpkgs I prefer to use my neovim-specific plugin manager. (In my case that's lazy.nvim.) Mostly this works without problems - but some setup is required when a plugin needs to compile something. The plugin that has given me the most trouble is Treesitter which wants to compile grammars. Here is how I got that working.

tl;dr: Configure Treesitter to compile grammars with gcc instead of clang.

As has been reported in https://github.com/nvim-treesitter/nvim-treesitter/issues/1449 Treesitter will try to use clang to compile Treesitter grammars, and on NixOS for some reason clang is not able to locate necessary C++ libraries. The fix that works for me is to configure Treesitter to use gcc instead. Here is the relevant part of my plugin config:

return {
  'nvim-treesitter/nvim-treesitter',
  build = ':TSUpdate',
  config = function()
    -- Set compiler to get grammar installation working in NixOS. See
    -- https://github.com/nvim-treesitter/nvim-treesitter/issues/1449
    require('nvim-treesitter.install').compilers = { 'gcc' }
    require('nvim-treesitter.configs').setup {
      ensure_installed = 'all', -- "all", or list of languages
      ignore_install = { 't32' }, -- t32 is failing to download for me
    }
  end,
}

I still had a problem with the t32 grammar, but I don't need that one so I disable it.

Of course you need to make sure that gcc is available. You could put it in your user profile, but I prefer to make sure by using the extraPackages option from Home Manager's neovim module. Here's my full config:

programs.neovim = {
  enable = true;
  defaultEditor = true;
  withPython3 = true;
  extraPackages = with pkgs; [
    fd
    gh # for github integration
    ripgrep

    # needed to compile fzf-native for telescope-fzf-native.nvim
    gcc
    gnumake

    # language servers
    nil # Nix LSP
    lua-language-server

    nixpkgs-fmt # I have nil configured to call this for formatting
  ];
};
20
submitted 9 months ago by hallettj@beehaw.org to c/linux@lemmy.ml

I'm using a PaperWM which is a scrolling window manager extension for Gnome, and I love it! But it's an extensive extension which means it is sometimes brittle. I've thought it would be nice to find a window manager that is natively designed with a workflow that I like. There don't seem to be any actively-maintained scrolling window managers out there. But scrolling is kind of a special type of tiling - I was hoping that someone with tiling experience could give me some tips on how to configure Hyprland, Sway, or something else to customize it for my particular working style.

I've realized that generally what I want is to be able to look at 2 windows at a time. But often I want to keep one of those windows in view, while swapping out the second window. For example,

  • When programming I want to keep my editor in view while switching between a terminal or a browser as my second window.
  • When researching I have a browser window in view, and for my second window I'll switch between my notes app, my todo list, my password manager, a map, etc.

And there are some features I'd like,

  • When programming I'd like to be able to make my editor full screen sometimes, and be able to quickly switch back to editor-and-terminal side-by-side.
  • When there are more than 2 windows on my workspace I'd like the ones I'm not looking at to go away without having to think about moving them to a specific other workspace.
  • When I open a new window I'd like to automatically see that window next to the previous window I was looking at, ideally moving other windows out of the way instead of making my previous window smaller.

I know most of this could be done with two monitors. But I have one ultrawide instead. Besides, I'd like to be able to use a 3/4-1/4 or 2/3-1/3 split in some cases.

So what do you think? Do you have a workflow that you love that you'd like to share?

33
submitted 10 months ago by hallettj@beehaw.org to c/neovim@programming.dev
15

My family needs a second car. I'm thinking about a used Chevy Bolt or Nissan Leaf so I think the cost will be about $20,000.

What's a good source for financing? I was thinking about getting a loan from my bank, Chase. But I see there are also lenders that specialize in car loans, and there might be dealership options? My credit score is over 700.

1
submitted 10 months ago by hallettj@beehaw.org to c/nixos@lemmy.ml

I've been searching for a way to do this, but I haven't found anything. After I have refactored my Home Manager configuration is there a way I can test the changes in a shell before I switch?

From what I understand the next-best option is to switch, and then find and run the activate script of the previous generation to switch back.

10
submitted 10 months ago by hallettj@beehaw.org to c/chat@beehaw.org

It's a story as old as time. I moved into a new place with great fiber internet - but the modem is in the garage, my desktop PC is not, and the place is a rental so I have limited options for making modifications. The signal is not bad, but I'm getting dropouts.

Since the PC and router are fixed in place I thought maybe a directional antenna or two would help? 5GHz directional antennae are kinda scarce which makes me wonder if I'm on the wrong track. Does this new "beamforming" thing supersede directional antennae?

I have 802.11ax (a.k.a. Wi-Fi 6) on both sides of the connection. Maybe I could upgrade to Wi-Fi 6E and give 6GHz a go? Maybe that would be worse due to the intervening wall...

[-] hallettj@beehaw.org 16 points 11 months ago

I believe your last Linux experience in 2015 predates DXVK which has been transformative for Linux gaming. Wine used to have to implement its own DirectX replacement which necessarily lagged behind Microsoft's implementation, and IIUC didn't get the same level of hardware acceleration due to missing out on DirectX acceleration built into graphics cards.

Now DXVK acts as a compatibility bridge between DirectX and Vulkan. Vulkan is cross-platform, does generally the same stuff that DirectX does, and graphics cards have hardware acceleration for Vulkan calls the same way they do for DirectX calls. So game performance on Linux typically meets or exceeds performance on Windows, and you can play games using the latest DirectX version without waiting for some poor dev to reimplement it.

If you are using Steam with Proton, Lutris, or really any Wine gaming these days you are using DXVK. It's easy to take for granted. But I remember the night-and-day difference it made.

[-] hallettj@beehaw.org 21 points 11 months ago

Apple controls what may be installed on iphones with an iron fist. Did you know there is only one option for a web browser? Chrome, Firefox, and other apparent alternatives are actually re-skinned Safari. They don't want to allow real competition to their own browser. This is certainly not the only case where they use app store approval powers to block competition.

Plus Apple takes 15-30% of every transaction on iphones. That includes payments in the app store, and also in-app purchases. Sure they have to fund the store, but given that Apple has an absolute monopoly over iphone app distribution this seems predatory to me.

Apple is anticompetitive, and seems to have little regard for their responsibility as a platform provider to allow application diversity to flourish.

So Google has a similar app store approval process, and takes basically the same percentage from transactions. But they are much more generous in what they allow in their store in terms of competing apps. And most importantly, Google does not have a monopoly on Android app distribution. You don't need to do any jailbreaking to set up F-Droid, or to install apps from the web.

It's true that the vast majority of Android users use Google's app store. And I think that Google taking a cut of in-app purchases is also predatory. Apps should be able to not use Google Pay, and to not pay Google a cut. But the fact that there are other options puts a limit on how much Google can block competition, and gives some option for publishers to avoid that 15-30% cut.

16
submitted 11 months ago by hallettj@beehaw.org to c/houseplants@mander.xyz

We're moving across the country so my wife made the difficult choices of picking her favorite orchids, and carefully packed them in a duffel bag. She put them in sideways with a big piece of cardboard on top. Then they rode as checked luggage. They came out banged up, but I think in not-too-bad shape. The sphagnum moss did a good job of staying in the pots.

view more: next ›

hallettj

joined 1 year ago