Giter Site home page Giter Site logo

Comments (11)

jeffbowman avatar jeffbowman commented on August 20, 2024 1

consult has a ripgrep command (ie consult-ripgrep). That might be the closest analog to what you are used to.

See https://github.com/minad/consult#grep-and-find

from crafted-emacs.

japhir avatar japhir commented on August 20, 2024

After disabling the block and restarting my daemon so I can get some work done, I tried executing it line-by-line.

On the package-install-selected-packages line I get this now:

Debugger entered--Lisp error: (wrong-type-argument stringp nil)
  string-match("\\`https?:" nil nil t)
  package--with-response-buffer-1(nil #f(compiled-function () #<bytecode 0x41c0aef6f2f58b6>) :file "org-plus-contrib-20210929.tar" :async nil :error-function #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_80> :noerror nil)
  package-install-from-archive(#s(package-desc :name org-plus-contrib :version (20210929) :summary "Outline-based notes management and organizer" :reqs nil :kind tar :archive "org" :dir nil :extras nil :signed nil))
  package-download-transaction((#s(package-desc :name org-plus-contrib :version (20210929) :summary "Outline-based notes management and organizer" :reqs nil :kind tar :archive "org" :dir nil :extras nil :signed nil)))
  package-install(org-plus-contrib dont-select)
  #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_71>(org-plus-contrib)
  package-install-selected-packages(:noconfirm)
  elisp--eval-last-sexp(nil)
  eval-last-sexp(nil)
  funcall-interactively(eval-last-sexp nil)
  command-execute(eval-last-sexp)

whereas before I got a message that all packages were installed already.
Executing the final line gets me the error message from my first message.

from crafted-emacs.

jeffbowman avatar jeffbowman commented on August 20, 2024

It appears you might have a deprecated ELPA listed in your package archives, see here: https://orgmode.org/elpa.html. The error seems to indicate you are trying to install org-plus-contrib which doesn't exist for Org versions after 9.5.

from crafted-emacs.

jeffbowman avatar jeffbowman commented on August 20, 2024

Could you try the same in the currently released version of Emacs? Emacs 29 hasn't been released yet, much less Emacs 30. I do my best to support currently released versions of Emacs, but as development versions are moving targets and bugs creep into the code base then get fixed, there is too much churn to accurately decide if a problem is in Crafted Emacs or in Emacs itself.

from crafted-emacs.

japhir avatar japhir commented on August 20, 2024

I've now switched to GNU Emacs 29.0.91 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) of 2023-05-28

but when I try within my existing config, I get the same errors.

I've also tried it in an emacs -q session and got the below:

Debugger entered--Lisp error: (error "Loading file /home/japhir/crafted-emacs/modules/cr...")
  require(crafted-completion-config)
  (progn (require 'crafted-completion-config))
  elisp--eval-last-sexp(nil)
  eval-last-sexp(nil)
  funcall-interactively(eval-last-sexp nil)
  command-execute(eval-last-sexp)

the org-plus-contrib issue is weird, should have been solved a long time ago when I first ran into that issue.

from crafted-emacs.

jeffbowman avatar jeffbowman commented on August 20, 2024

Emacs 29 still hasn't been released, could you please try with Emacs 28.x?

Hard to tell what the error is since the path is elided, no idea what is being loaded. We can see there is a (require 'crafted-completion-config) there, and if that is not loading correctly, the most likely cause would be a load-path problem. You should investigate the value of that variable and make sure it has the appropriate paths to be able to find the crafted-completion-config.el file.

If you are loading the crafted-init-config file early enough in your init.el file, that should set the load path up for you to be able to use the Crafted Emacs modules. If that is what is happening but the absolute path to that file is incorrect, then it will not load and you will not get the updated load-path set to be able to use Crafted Emacs modules.

The example file has a line like this: (load "~/crafted-emacs/modules/crafted-init-config"). However, if you did not clone the repository to your home folder (ie if ~/crafted-emacs/ does not exist) then you can't expect things to work. On the other hand, if the path ~/crafted-emacs/ does exist then the load command should succeed. You might try setting debug-on-error to t (possibly in your early-init.el file or at the very top of your init.el file before anything else gets loaded), and restart emacs.

For error messages which include the ..., you can move the point there and press RET to expand the error. That is helpful if when pasting here as then I can read the entire error message.

from crafted-emacs.

japhir avatar japhir commented on August 20, 2024

I'm using emacs 29 because I've compiled it myself using native compilation, to make things smooth/faster. I don't think this should be the reason for the problem.

"/home/japhir/crafted-emacs/modules/" is part of my load-path, and that's where I've insalled crafted-emacs.
I've now switched to the craftedv2beta branch (from alpha).

Running the example code line-by-line in an already running emacsclient daemon might help here?

  (load "~/crafted-emacs/modules/crafted-init-config")

  (setq custom-file (expand-file-name "custom.el" user-emacs-directory))
  (when (and custom-file
             (file-exists-p custom-file))
    (load custom-file nil :nomessage))

  (require 'crafted-completion-packages)  ; must come first to install
                                          ; the packages

  (package-install-selected-packages :noconfirm) ; install the packages
                                          ; from the bundle
                                          ; mentioned above.

  (require 'crafted-completion-config)

It gives the following messages:

Loading /home/japhir/crafted-emacs/modules/crafted-init-config.el (source)...done
t
"/home/japhir/.emacs.d/custom.el"
nil
crafted-completion-packages

then on the install line it errors out with:

Packages that are not available: 31 (the rest is already installed), maybe you need to M-x package-refresh-contents
#("Packages that are not available: 31 (the rest is already installed), maybe you need to M-x package-refresh-contents" 87 115 (face help-key-binding font-lock-face help-key-binding))

so that the require line returns this error (now expanded the ..., thanks!)

Debugger entered--Lisp error: (error "Loading file /home/japhir/crafted-emacs/modules/crafted-completion-config.el failed to provide feature ‘crafted-completion-config’")
  require(crafted-completion-config)
  elisp--eval-last-sexp(nil)
  eval-last-sexp(nil)
  funcall-interactively(eval-last-sexp nil)
  command-execute(eval-last-sexp)

Now I've gone through the list of packages in crafted-completion-packages.el to try and install them one by one manually. On corfu-terminal I run into an issue that it doesn't exist, but in my M-x list-packages overview I do see corfu-terminal installed... (as well as all the other packages in crafted-completion-packages.el).

from crafted-emacs.

jeffbowman avatar jeffbowman commented on August 20, 2024

I'm using emacs 29 because I've compiled it myself using native compilation, to make things smooth/faster. I don't think this should be the reason for the problem.

Use whatever you wish, of course! I'm only supporting Crafted Emacs on released versions of Emacs. I'll try to help where I can, but no guarantees.

"/home/japhir/crafted-emacs/modules/" is part of my load-path, and that's where I've insalled crafted-emacs.
I've now switched to the craftedv2beta branch (from alpha).

Woo!

Debugger entered--Lisp error: (error "Loading file /home/japhir/crafted-emacs/modules/crafted-completion-config.el failed to provide feature ‘crafted-completion-config’")
require(crafted-completion-config)
elisp--eval-last-sexp(nil)
eval-last-sexp(nil)
funcall-interactively(eval-last-sexp nil)
command-execute(eval-last-sexp)

Also Woo! This is the most helpful part, I have missed a provide in that file. I'll fix it shortly, thanks for expanding the error message - super helpful!!

from crafted-emacs.

jeffbowman avatar jeffbowman commented on August 20, 2024

If you could pull from the craftedv2beta branch and try again. If that resolves your issue, you can close this issue.

Thanks for the report.

from crafted-emacs.

japhir avatar japhir commented on August 20, 2024

Yes, that worked :)

from crafted-emacs.

japhir avatar japhir commented on August 20, 2024

Quick question that may not be worth opening a new issue for:

I loved counsel-rg to quickly call ripgrep on the current directory to search for stuff. Does the completion framework have a similar alternative?

from crafted-emacs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.