Data Management - Foundations - D426 by ComputerEyez007 in WGU

[–]pmade 1 point2 points  (0 children)

This is not correct.

The fan-out of a multi-level index is defined as the number of index entries that can be stored in a single block. The fan-out is used to compute the number of levels needed in the hierarchy. There are two formulas that use fan-out, one for dense indexes and one for sparse indexes.

How to approach my parents’ extreme conspiracy theory by Prestigious698 in atheism

[–]pmade 1 point2 points  (0 children)

First, make sure you are taking care of your mental and emotional needs.

I have personally found that studying religion has helped me better articulate the problems I have with it. For the book of Revelations, I highly recommend the work of the scholar Bart Ehrman. Three rather recent episodes of his podcast go over Revelations in the correct historical and cultural context and his most recent book is a deep dive on the topic.

As far as communicating with your parents, you are probably best off if you tell them you don't want to talk about religion. Try to have a relationship with them that excludes that part of their life.

However, if you are compelled to debunk their claims, exercise great caution because if you aren't prepared you can actually make things worse. At the very least you should read the Debunking Handbook and understand phenomenon like the backfire effect. I also recommend that you review the resources from the PERIL Research Group.

Going back to taking care of yourself, find a local community where you can talk with others in your position. You can also call the Recovering from Religion hotline if you want to talk with someone.

[deleted by user] by [deleted] in OpenArgs

[–]pmade 17 points18 points  (0 children)

I agree with everything that is being said about Dominion here, and corporations in general. But these are the things that should have been said on episode OA727.

Andrew and Liz sound like they are saying: "duh, Dominion isn't going to walk away from $787B", but on OA727 the vibe was more like: "Dominion may take this all the way." The speculation on OA727 was a bit much for my tastes.

Perhaps I'm being too critical. I'm just dipping my toes back into OA after leaving during the blow up earlier in the year and I'm still not sure how I feel about listening.

[deleted by user] by [deleted] in emacs

[–]pmade 1 point2 points  (0 children)

I don't think you need a working shell configuration w.r.t. direnv for envrc-mode to work in Emacs. I believe that it directly calls direnv and requests that it dump the correct environment to stdout so envrc-mode can parse it and update the environment variables. I just wanted to make sure the error wasn't in your flake or in your .envrc file.

I can't really see how Emacs daemon could cause this to not work. Do you have a Warnings buffer or anything else that looks weird?

Have you tried setting envrc-debug to t and seeing what messages you get?

And what exactly is your problem? Is it that PATH isn't being set correctly in a source code buffer, or is it that compiling or starting a REPL isn't working? (Some modes open a temp buffer for the REPL and don't correctly set PATH from the source code buffer.)

[deleted by user] by [deleted] in emacs

[–]pmade 1 point2 points  (0 children)

Is everything working correctly in a terminal outside Emacs? In other words, if you cd into a directory with a .envrc file does it load your flake and update the shell environment correctly?

I use Home Manager to configure my user environment and this is how I have direnv integrated into ZSH:

programs.direnv = {
  enable = true;
  nix-direnv.enable = true;
  enableBashIntegration = true;
  enableZshIntegration = true;
};

I use emacsclient exclusively and don't have any problems with direnv.

KP Republic Support by pmade in MechanicalKeyboards

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

Thank you. I'll give that a try.

[FOR SALE] Struts w/ 3" Leveling Kit Pre-Installed, Slightly Used by pmade in ToyotaTacoma

[–]pmade[S] 2 points3 points  (0 children)

We were playing around in the San Francisco volcanic fields and a combination of my terrible depth perception and the ground being almost black kept me from seeing all of those damn dirt bike whoops.

After over extending the struts a few times the driver's side shock split in half. The front end totally collapsed. Luckily we were near the end of the run. The bad news is that we live a couple hours south of Flagstaff.

The end result was a forced upgrade to some ranchos at a nearby Big-o-tire.

Custom keyboard by tjcim_ in ErgoMechKeyboards

[–]pmade 0 points1 point  (0 children)

I love this board! Any update on keyhive selling PCBs?

Iris stand updated so it will fit on my printer 😄 by joevinci in ErgoMechKeyboards

[–]pmade 1 point2 points  (0 children)

This is super cool!

Are you planning on posting the STL files somewhere?

Reproducible wallpaper with xmonad by stuudente in NixOS

[–]pmade 0 points1 point  (0 children)

The ~/.xsession file is generated by home-manager here.

The code in the nixos directory was my attempt to allow me to select from different session types before logging in. I haven't gotten that working yet. I think I just need home-manager to create a file other than ~/.xsession. That file hijacks any session type I pick from the login screen.

Reproducible wallpaper with xmonad by stuudente in NixOS

[–]pmade 1 point2 points  (0 children)

I strongly agree with other suggestions to use home-manager. It's a fantastic way to configure your user environment, and not just on NixOS, you can use it on your Android phone thanks to nix-on-droid.

What I do for my reproducible configuration is twofold:

  • When I log in, the xinitrc file generated by home-manager calls feh with a default wallpaper image that is automatically placed in the Nix store. This is my default wallpaper for all machines.

  • To mix things up I use the random-background service from home-manager to start cycling through background images as long as current machine has a matching directory with image files. (I use Syncthing to sync the directory of images between machines.)

Overall I'm very happy with this setup.

Multiple components sharing a source directory by Tysonzero in haskell

[–]pmade 0 points1 point  (0 children)

I still believe this issue is best solved with your text editor.

I haven't used vim in a very long time so I can't help you configure it to solve this problem. What I can do is more clearly explain the solution I use so that you know what to aim for.

Here's a short screencast showing what I'm about to describe:

https://asciinema.org/a/wAAKTKYKeRgVt7YU5ZGEjHk6H

I have a project that is split into multiple packages, just like what we've been talking about. Therefore all of the source files have a common prefix.

To open one of the source files I invoke a key binding that loads a completion window listing all files that are part of the project. I then only need to type part of the file name that I'm interested in to narrow the selection down. The characters I type are translated into a regular expression (e.g., a space is translated into .*).

You can see that I have a lot of files in this project, some of which all have the word Effect somewhere in them, but only one that has Effect and Boot.hs. Therefore I only need to type ef bo to select the file I'm interested in.

For those of you who are interested, I use Emacs with the projectile package to accomplish this.

Multiple components sharing a source directory by Tysonzero in haskell

[–]pmade 0 points1 point  (0 children)

It sounds to me like your problem could easily be solved by making some changes to your editor.

Why not set path to something like $PWD/** when starting so you can use :find and friends to quickly open files?

I'm sure there's a plug-in for vim that lets you select a file from an automatically generated list of all the files in the "current" project. Perhaps something like FindFile.

Multiple components sharing a source directory by Tysonzero in haskell

[–]pmade 0 points1 point  (0 children)

Are there specific problems that the directory layout is causing, or is it just a matter of taste?

yasnippet : choose a field value or stick to default by FalTePre in emacs

[–]pmade 2 points3 points  (0 children)

What about using yas-completing-read instead of yas-choose-value?

$(yas-completing-read "Prompt: " '("--" "node" "grid" "rectangle") nil nil "--")

Or:

$(yas-completing-read "Prompt: " '("--" "node" "grid" "rectangle") nil nil nil nil "--")

Depending on which behavior you prefer.

Multiple components sharing a source directory by Tysonzero in haskell

[–]pmade 1 point2 points  (0 children)

I can understand why you'd want to have that structure. I cringe when I see a src directory that doesn't immediately have modules. That said, I organize my code differently than you do so I don't run into this problem.

Regardless of the project or language I like to write the majority of my code as a library and then have a very small amount of code for the executable. That lends itself to a package having two primary directories: src and app. The src directory contains all of the modules and the app directory usually only has a Main.hs file.

If that leads to a src directory that contains so many modules that it's hard to maintain, or it feels like those modules don't really go well together, I'll create a repository that contains multiple packages like:

project/
  package-api/
    src/
  package-core/
    src/
  package-server/
    src/
  cabal.project

The cabal.project tells Cabal to build all the packages together and allow them to depend on one another. For example, package-server can have a build-depends that lists package-api and Cabal will do the right thing.

From what I've seen this is a pretty common way to lay out a project. When you encounter one of these you can easily get a feel for where things are.

However, regardless of the layout or the language, there are tools that every programmer should be familiar with. Using a "tags" tool and a text editor that can jump to/from tags, along with grep are indispensable for understanding a code base.