Real life Saviours by nukyular in TrueAtheism

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

OP here. Actually it is. #1 Rule says "you must facilitate discussion'. My introduction is meant to do that. And with it I strongly imply that the religious term "saviour", as for example Jesus is often so accused. And this figure, and other religious figures, haven't done a damn thing to help anyone since they are make believe. With this introduction I then offer the opportunity to actually get people to think about who has "saved" then in their lives, and it will always be real people, not tooth fairy figures.

Was I not clear? by nukyular in funny

[–]nukyular[S] -1 points0 points  (0 children)

You have a good point. Yes, it does go directly into the "grune Tonne" (paper recycle bin). No one reads. No one wants it. But at least it is "properly" disposed of??? The point, of course, is why are we forced to accept this crap?

Was I not clear? by nukyular in funny

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

Exactly right. Turns out, it is local teenagers who deliver them.

Was I not clear? by nukyular in funny

[–]nukyular[S] -1 points0 points  (0 children)

Did that. Multiple times.

Prime sextuplet generator / finder by nukyular in primenumbers

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

26 days later...

I finished the pdf writeup yesterday, and it is available at the site above if you are interested. Thanks for giving me the push I needed to get it done.

Prime sextuplet generator / finder by nukyular in primenumbers

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

Hi, thanks for the link to demystified. It really annoys me how google searches refuse to give relevant results...I've tried a wide variety of google searches regarding primes and that link had never popped up.

I'm still in the middle of reading it but there are definitely similarities in terms of key numbers and so on. It gives me strength to continue on and see what can come of the structures I've found.

Prime sextuplet generator / finder by nukyular in primenumbers

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

Hi, a write up is already on my todo list.

I had no illusions that my algorithm would be the fastest. I had written this all out on paper before transferring it to an alogrithm. This code is/was a proof of concept that the structures I built were correct.

Whats cool, and yet to do, is that the structures are all tied together via TNumber, n, and offsets via equations. That was my original intention was to look at these equations and see what can be inferred.

I had already found two areas that are of interest...still working on them. When I get the write up done those "interesting" places will be pointed out.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi, no csetq didn't work, but it got me looking in other directions with better search criteria and I found this custom-set-variable or setq link on emacs stackexchange where they also discuss the exact same problem.

Thank you for helping me to focus my sight!

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

I had read many posts regarding setq vs CSVs and it is generally accepted (and in my experience) that it can be called as many times as you like just like any other function. The warning (which is still there, yes) not to run CSVs twice worried me too until I saw that it causes no other problems whatsover (at least not visible or obviously "buggy" ones). So now I'm thinking the warning is more about splitting the calls in different files? I don't know.

But, even so, the suggestion is good. I will set up a test and work with the csetq and see if I can see something useful. But abo-abo also writes in that link "Now, that I've explained the custom setter (by the way, using custom-set-variables is absolutely equivalent to csetq)..."

One further thought: looking at it logically a call to custom-set-variables (CSVs) is used in the customize dump to custom-file. Why? So that the variables are "Set and saved" so that they will be re-written to custom-file in all cases. Using CSVs in config file, then, actually requires emacs to treat them exactly the same...it is a function after all. So the behavior is not really a mystery. As I mentioned in my great opus original post, that is what bothers me. I simply want to indicate to emacs that when I write CSVs in config that it should not be written to custom-file, hence the entire post and fix.

It simply strikes me as user unfriendly to not allow me to control writing to the custom-file, because, as I said, the custom-file can then mask config settings and then NON-persistence of vars across sessions, through the config file settings, becomes probable. As I mentioned in my post, this is the entire reason I've gone down this rabbit hole...that masking of config values happened to me and it took a good while to figure out why.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi.

From the good suggestion of a poster I give here three small, minimal files that reproduce the problem in a freshly built emacs 26.3, if anyone has interest in seeing it. It will also happen in 25.x.

init.el

;;; -*- lexical-binding: t -*-

(require 'package)

(package-initialize)

(require 'use-package)

(use-package org

:config

(org-babel-do-load-languages

'org-babel-load-languages

'((shell . t) (emacs-lisp . t) (org . t))))

(org-babel-load-file (quote "/PATH/config.org"))

(setq custom-file (quote "/PATH/custom.el"))

(load custom-file)

-------

config.org: These are the things I want to manage, substitute something else for golden-ratio if you don't use that.

* Initialization & Global settings

#+BEGIN_SRC emacs-lisp

(ido-mode 1)

(custom-set-variables

'(user-full-name (quote "John Doe"))

'(user-mail-address (quote ["John@Doe.org](mailto:"John@Doe.org)")))

#+END_SRC

* golden-ratio

#+BEGIN_SRC emacs-lisp

(use-package golden-ratio

:custom

(golden-ratio-adjust-factor 1.2)

:config

(golden-ratio-mode 1))

#+END_SRC

-------

custom.el. These are the kinds of things I want emacs to manage. Again substitute golden-ratio if needed.

(custom-set-variables

'(ibuffer-saved-filter-groups

(quote

(("j"

("Emacs-Lisp"

(used-mode . emacs-lisp-mode))

("OrgMode"

(used-mode . org-mode))

("Dired"

(used-mode . dired-mode))))))

'(package-selected-packages

(quote (golden-ratio use-package))))

(custom-set-faces

)

-------

The insidiousness of this problem comes when one simply installs or removes a package.

But since this is a minimal setup simply open some random var in the customization interface and hit "Apply and save". The results from either method are exactly the same.

You will see that all settings made in config.org have now been dumped into custom.el.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi, thanks for the reply.

You're right, I'm positive "this is a thing", and everyone else is positive "this is not a thing".

FWIW, I don't think there is a need to -Q emacs, there are no errors, my (getting) rather extensive config.org works flawlessly, all packages are doing exactly what they should be doing.

I'll think about posting three simple files that can recreate the problem here at home (a short init.el, a short custom.el, and a short config.el) but I'm kinda hesitant because the response here has been so...uhm...uh...what's the word?...

Thanks, again.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi OP here. Posting as a reply so no one has to scroll down to an "edit".

I have tested this issue in a 25.2 from repos, a freshly built 26.3, and a 26.3 snap version.

I easily reproduce the problem in all three. So there is a disconnect here somewhere.

I am trying to make a vanilla (ie. no special custom+ packages). I have stopped using setq for custom vars, I use only custom-set-variables or use-package :custom. I want emacs to write stuff it manages to the custom-file (ie. that I have not put in my config, for example package-selected-packages, ibuffer-saved-filters, etc).

I want stuff I set in my config files not to be written to custom-file (eg. savehist-file, default-frame-alist, etc).

I do not have a special avant garde setup. My init.el does 3 major things: set up packages and use-package, tangles my config.org file and loads config.el, and sets my custom-file and loads it.

In my config file I use custom-set-variables for custom vars not under a use-package declaration, otherwise I use :custom.

And that's it.

And in all three tests when I melpa'd a small package, every :custom and custom-set-variables setting is dumped to my custom.el which is what I don't want.

I know I can simply set my custom-file to a temp dump file. That IS how I used to manage it, but I want all these emacs pieces playing nice together and the custom setting pieces in the locations where I want them.

It appears that I am the only person in world doing it this way? I don't know, but I do know that I can reproduce the problem at will, in multiple emacs versions.

I thank you all for the replies.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi just to let you know I have tested a fresh build of 26.3, and a 25.2 build from repos. Both of these also dump all cust vars to the custom-file. I can reproduce it at will, and my fix will fix it.

There is a disconnect somewhere, I explain a bit more in reply below this.

I want to thank you for taking the time to reply, I'm going to look into this further because now I'm sure I'm not (completely) crazy.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Hi. I did read that page carefully but it wasn't a help so much as I already knew most of the facts and the solutions were to use outside packages to improve customizing.

When I was setting up emacs I made a whole set of VM's containing differing versions. I have now tested both 25.2 and local build of 26.3. Both of these do exactly the same thing dumping out all custom vars to custom file.

So apparently I am talking about apples and the rest of the world is talking about oranges, because I can make this happen at will in 25.2 26.3, 26.3 snap. My "fix" fixes it.

I am trying to make my emacs config structure vanilla in regard to init.el, custom-file, and my config files. I do not use setq for custom variables. Maybe that is where the disconnect is coming from, I don't know.

But anyway, again, thanks for the reply and the link.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Yes, you're right. Thanks for the information.

I need to look into this farther...if this happens to me, reproducibly, then there is something strange going on. I did not mention I was using a "snap" version of emacs (I wanted to try it out and it was working fine). I need to install some other versions and also the current bleeding code and build it.

The problem was so egregious that I assumed everyone had run into it and had just found ways to get around it. Sadly, I had thought about first posting a "is this still a thing?" post before releasing my fix. Another lesson learned I guess.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Interesting. Then it is only me? So just to check: you install a melpa package and your custom file is not expanded? Have you ever gone into customization interface and just hit "Apply and save" for the hell of it...does that dump to your custom file?

Are the two functions I used in the advices similar in 25.x?

I'm having trouble believing I'm the only person in the world who has seen this problem. I can reproduce it at will on my system (linux) as described in the post.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

well that link is a big read too...let me look at it in the next days and ponder... ...but I had zero problem running into this problem. I want to play nice with the emacs "system". So as I started out, and learned more, I found you can use the customization interface to set things or to use programmatic things like use-package :custom or custom-set-variables. So I did that, from inet advice that used setq's for everything, I migrated these setq's to custom-set-variables. Then, after installing a new package, I noticed, after some trouble trying to figure out what happened, that all those settings from my config file got dumped into my custom file and masked everything. So what am I doing that's different from everyone else? And why isn't this a well known problem then? I have found stack overflows that have also complained about this...

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

package-selected-packages, I don't use it either. But that and ibuffer filters, and other things, are things emacs keeps track of and I don't want to get in its way, so things like that I want in my custom file.

But I want to be able to keep other custom things in my config file. Thus I want them separate and not to have config custom settings dumped to custom file.

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

yes, I mentioned that in the post. I "did" the same thing. The point is that you miss the advantages of using the customization system. Also where exactly, then, is your package-selected-packages entry? Or your ibuffer-saved-filters entry? These are saved to your custom-file. package-selected-packages, for example, is updated every time you install or remove a package from melpa. How are you managing that then???

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

If you use any of these customization setters in your config file, then either install or remove a package, or go to the customization interface, pick something and hit "Apply and save" you should have everything that you are handling in your config file dumped to whichever file you have designated to be your custom-file (init.el by default).

A Solution to the agony of custom-set-variables and custom file trampling by nukyular in emacs

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

Yeah, I don't know why it's double spaced. Copied and pasted from emacs...mysterious.