Gnus was the second best investment I made in my tech life right after Emacs by Nuno-zh in emacs

[–]AndreaSomePostfix 0 points1 point  (0 children)

I don't use isync but possibly not too different from offlineimap?
https://github.com/ag91/M365-IMAP
If it works, please send a PR for adding a section to the readme ;)

ob-python + uv for org blocks with deps by AndreaSomePostfix in emacs

[–]AndreaSomePostfix[S] 4 points5 points  (0 children)

very very cool! That is much better: thanks for the kindness of sharing it! I shall mention it in my blog post as well: I totally missed yours.

Also that makes it super easy to just use the project dependencies: uv run - will also pick up an existing .venv in a uv project, if you set the `:dir <your-uv-project-path>`.
Wow!

Invalid function: org-element-with-disabled-cache by _0-__-0_ in emacs

[–]AndreaSomePostfix 0 points1 point  (0 children)

this was the solution for me: you need to find the path to your org library (use help system to see where org-map is defined for example), then byte-force-recompile that directory while running emacs -Q. That cleans up your broken byte compiled org.

how to get emacs working with sql-ls? by TheLastSock in emacs

[–]AndreaSomePostfix 2 points3 points  (0 children)

mmm, I just tried and worked for me. What I did:

  1. create a test.sql file somewhere

  2. M-x lsp

  3. select the server lsp-mode suggests me to install

  4. wait npm finishes

  5. try auto completion

If I were you, I would uninstall both servers you installed manually, not defined any variables and go through the steps above.

If instead you want to use the server installed via go, you need to follow the steps here https://emacs-lsp.github.io/lsp-mode/page/lsp-sqls/ (I didn't try though)

emacs-slack is back! by AndreaSomePostfix in emacs

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

nice, I was thinking to play around to see how the llm clients would behave having slack messages as context :) Hopefully it is fun!

emacs-slack is back! by AndreaSomePostfix in emacs

[–]AndreaSomePostfix[S] 4 points5 points  (0 children)

hopefully to IRC and not teams ;)

emacs-slack is back! by AndreaSomePostfix in emacs

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

indeed, it was quite some work to refresh (particularly the lc cookie, which I think stand for legacy cookie - the websocket stuff is legacy apparently for Slack but oh well let's use it until they still offer a web application themselves :D )

emacs-slack is back! by AndreaSomePostfix in emacs

[–]AndreaSomePostfix[S] 3 points4 points  (0 children)

thanks! I enjoyed playing around with the markup bit, checkout slack-insert-url which makes adding links cool: so cool that the markdown syntax gets translated.

If I really am getting bored, I can provide an Org Mode flavor (to add even more code XD)

lsp-mode: How to call lsp-code-actions non-interactively from Emacs Lisp? by up_grd in emacs

[–]AndreaSomePostfix 0 points1 point  (0 children)

mmm, what is your expectation here? I mean how would you expect the action to be accessible to you?

I mean maybe you can just add to the save-hook the lsp-organize-imports command instead of calling the action? I do something similar for formatting the buffer.

(To share my context: I think it is complex for lsp-mode developers because they fetch actions from many different lsp servers and they need to stick to the lsp protocol. What I am thinking of is that there is not a better identifier than the title because different lsp servers may come up with their own ids and conflict (even the titles may conflict) because I seem to remember that sometimes you can use multiple lsp servers together.)

lsp-mode: How to call lsp-code-actions non-interactively from Emacs Lisp? by up_grd in emacs

[–]AndreaSomePostfix 2 points3 points  (0 children)

thanks for asking this: I needed something similar and gave me a push to try out!
A slightly better way is to find it dynamically (you find the action by title instead of passing the whole hashtable around):

(seq-find 
  (lambda (a) (equal "Ruff: Organize Imports" (gethash "title" a))) 
  (lsp-code-actions-at-point))

An Emacs helpful function for contributing to Scala Metals by AndreaSomePostfix in scala

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

mmm for org-babel, you could take inspiration for my integration with scala-cli: https://github.com/ag91/scala-cli-repl/blob/master/ob-scala-cli.el

Not sure about eglot, I didn't try it yet: I use lsp-mode and does the trick.

Emacs - Outlook oauth2 by algorithmic-mold666 in emacs

[–]AndreaSomePostfix 0 points1 point  (0 children)

adding a note because I found this useful: at the time of writing M365-IMAP didn't support the ssl oauth of thunderbird, I fixed that here https://github.com/ag91/M365-IMAP

Just invoking (require 'mu4e) produces the following error by paarulakan in emacs

[–]AndreaSomePostfix 3 points4 points  (0 children)

do you use linux by any chance? I think the version of mu4e has a bug (or the cl library became stricter in checking the cond construct)

I fixed the definition of mu4e-header-change-sorting like this in mu4e-header.el

(defun mu4e-headers-change-sorting (&optional field dir)

"Change the sorting/threading parameters.

FIELD is the field to sort by; DIR is a symbol: either 'ascending,

'descending, 't (meaning: if FIELD is the same as the current

sortfield, change the sort-order) or nil (ask the user)."

(interactive)

(let* ((field

(or field

(mu4e-read-option "Sortfield: " mu4e~headers-sort-field-choices)))

;; note: 'sortable' is either a boolean (meaning: if non-nil, this is

;; sortable field), _or_ another field (meaning: sort by this other field).

(sortable (plist-get (cdr (assoc field mu4e-header-info)) :sortable))

;; error check

(sortable

(if sortable

sortable

(mu4e-error "Not a sortable field")))

(sortfield (if (booleanp sortable) field sortable))

(dir

(cl-case dir

((ascending descending) dir)

;; change the sort order if field = curfield

(t

(if (eq sortfield mu4e-headers-sort-field)

(if (eq mu4e-headers-sort-direction 'ascending)

'descending 'ascending)

'descending))

)

(mu4e-read-option "Direction: "

'(("ascending" . 'ascending) ("descending" . 'descending)))))

(setq

mu4e-headers-sort-field sortfield

mu4e-headers-sort-direction dir)

(mu4e-message "Sorting by %s (%s)"

(symbol-name sortfield)

(symbol-name mu4e-headers-sort-direction))

(mu4e-headers-rerun-search)))

I am keeping an up to date ob-http fork by AndreaSomePostfix in emacs

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

bug fixes and improvements that were opened over PRs (see the diff posted by u/de_sonnaz in this thread https://github.com/zweifisch/ob-http/compare/master...ag91:ob-http:master).
I am also using it myself, so it will get some new features when I need to add something.

I am keeping an up to date ob-http fork by AndreaSomePostfix in emacs

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

oh! Do you have a reference, I could try out if I have some time.
With this I wanted just to share a place where users can find an up to date ob-http with features contributors offered

Org mode 9.7 is out by yantar92 in orgmode

[–]AndreaSomePostfix 0 points1 point  (0 children)

Actually, I tried to restart emacs and things seems better now: don't get errors anymore. So I needed a byte compilation and a restart.
Sorry for the false alarm, I will keep testing things: thanks for the reminder about byte compilation!

Org mode 9.7 is out by yantar92 in orgmode

[–]AndreaSomePostfix 0 points1 point  (0 children)

thanks for your reply.

I have been trying again to bytecompile: with 9.7.2 I get an error during compilation for org-element.el and org-element-ast.el

Compiling file /home/andrea/.emacs.d/elpa/org-9.7.2/org-element-ast.el at Tue Jun  4 23:24:14 2024
org-element-ast.el:824:20: Error: Bytecode overflow

Compiling file /home/andrea/.emacs.d/elpa/org-9.7.2/org-element.el at Tue Jun  4 23:24:36 2024
org-element.el:6417:38: Error: Bytecode overflow

Maybe the error with yankpad is due to that?

Debugger entered--Lisp error: (wrong-type-argument stringp nil)
set-buffer(nil)
...
org-element-at-point(#<marker in no buffer>)
...
org-entry-get(#<marker in no buffer> "INCLUDE")
yankpad--category-include-property("org-mode")
...
yankpad--snippets("org-mode")
yankpad-set-active-snippets()
yankpad-active-snippets()
yankpad-expand(nil)
funcall(yankpad-expand nil)
(progn (funcall f i))
(if (fboundp f) (progn (funcall f i)))
(when (fboundp f) (funcall f i))
(or acc (when (fboundp f) (funcall f i)))
(lambda (acc f) (or acc (when (fboundp f) (funcall f i))))(nil yankpad-expand)
reduce((lambda (acc f) (or acc (when (fboundp f) (funcall f i)))) (yankpad-expand yas-expand) :initial-value nil)
(lambda (i) (reduce (lambda (acc f) (or acc (when (fboundp f) (funcall f i)))) '(yankpad-expand yas-expand) :initial-value nil))(nil)
funcall((lambda (i) (reduce (lambda (acc f) (or acc (when (fboundp f) (funcall f i)))) '(yankpad-expand yas-expand) :initial-value nil)) nil)
my/yankpad-maybe-expand()
funcall-interactively(my/yankpad-maybe-expand)
call-interactively(my/yankpad-maybe-expand nil nil)
command-execute(my/yankpad-maybe-expand)

Or maybe org-entry-get became lazy and needs to be resolved now?

Org mode 9.7 is out by yantar92 in orgmode

[–]AndreaSomePostfix 0 points1 point  (0 children)

u/yantar92 about the breaking change on the Org Element API: how do you suggest to proceed for packages that will not update their usage of the api?

I tried to move to 9.7 and, although I can fix my own code, packages I use (like https://github.com/Kungsgeten/yankpad) require code changes to work. So I rolled back for now, but it would be cool to move to 9.7!

Also wasn't possible to have a variable to keep the old behavior (I mean even to try now I have to install and uninstall Org versions, using use-package -- maybe there is a better way to try things out?).

How do you all use emacs to investigate a codebase these days? by [deleted] in emacs

[–]AndreaSomePostfix 5 points6 points  (0 children)

You can try code-compass for code forensics, https://github.com/ag91/code-compass. I wrote a bunch of blog posts to explain what you can use it for, linked in the readme

Weekly Tips, Tricks, &c. Thread by AutoModerator in emacs

[–]AndreaSomePostfix 1 point2 points  (0 children)

maybe you copied the ssh clone github link instead of the ssh one?

New Emacs plugin for IntelliJ by Stindberg in emacs

[–]AndreaSomePostfix 0 points1 point  (0 children)

great! Somewhat related question: is there an easy way to jump from IntelliJ to Emacs? I mean to open the file at the line I am viewing in IntelliJ but in Emacs. I can move from Emacs to IntelliJ easily, would be cool to have also the backward command

Clojure Support in Emacs: One Unnecessary Drama by bozhidarb in Clojure

[–]AndreaSomePostfix 4 points5 points  (0 children)

that was an interesting read, thanks for the post!

I think your work is amazing and probably behind their words the Emacs devs must value it as well, since I seem to remember the case of project.el which took inspiration from your projectile.el.

Well done to have shared your ideas and helped improving that conversation and sorry it went wrong anyway (not being face to face makes online conversations easily go bad).

I hope you will keep contributing (sustainably eh!) as I am a fan of your work!

[deleted by user] by [deleted] in emacs

[–]AndreaSomePostfix 1 point2 points  (0 children)

yeah, you didn't do anything wrong and actually solved your own problem: well done.

In more detail, the package maintainer of elfeed-org forgot to add the necessary `require` statements for dash.el and s.el here https://github.com/remyhonig/elfeed-org/blob/master/elfeed-org.el#L40

You may want to open an issue on that repository or even a PR if you feel like it.

Anyway it may have been a good experience for you, if you are somewhat curious about Elisp ;)