Closed freddyholms closed 11 hours ago
I can't reproduce it on a non-containerized environment.
I'd suggest evaluating nyxt --eval "(xdg-download-dir)" --quit
in the containerized environment to check whether that folder is being exposed.
also happened to me, it does nothing when i try to download something
@KonstantinDjairo can you provide a concrete recipe? What URL was downloaded? How did you install Nyxt?
I've been experiencing this issue, although calling download-url or following a download link would open the list-downloads buffer and where it would be reported to have failed. I'm not running Nyxt in a container, just installed on my Arch Linux system via the official repositories.
I discovered that that there were two factors causing this issue for me.
First, even though I had defined XDG_DOWNLOAD_DIR="$HOME/download" in my $HOME/.config/user-dirs.dirs, Nyxt did not appear to respect that and would fail the downloads due to the expected directory being missing. Creating $HOME/Downloads, the XDG default, fixed the problem.
Second, to get Nyxt to respect my $HOME/.config/user-dirs.dirs, I had to install the xdg-user-dirs package. Doing so sent the downloads to $HOME/download as desired.
@zcal your issue seems to be different from the one reported in the top post.
The logic behind resolving the download folder is as below. Are you suggesting any changes to it?
(defun xdg-download-dir ()
"Get the directory for user downloads.
Tries hard to find the XDG directory or at least ~/Downloads one."
(let ((dir (ignore-errors (uiop:run-program '("xdg-user-dir" "DOWNLOAD")
:output '(:string :stripped t)))))
(when (or (null dir) (uiop:pathname-equal dir (user-homedir-pathname)))
(setf dir (uiop:getenv "XDG_DOWNLOAD_DIR")))
(unless dir
(setf dir (uiop:merge-pathnames* #p"Downloads/" (user-homedir-pathname))))
(uiop:ensure-pathname dir :ensure-directory t)))
Describe the bug When I call download-url on any buffer, nothing happens. Checking the downloads list all I see is that the download failed.
Precise recipe to reproduce the issue This is the Dockerfile I used to build nyxt
I run the container with
Information
ASDF version: 3.3.1 ASDF registries: (NYXT-SOURCE-REGISTRY ENVIRONMENT-SOURCE-REGISTRY) Critical dependencies: (/root/common-lisp/nyxt/_build/cl-cffi-gtk/gtk/cl-cffi-gtk.asd /root/common-lisp/nyxt/_build/cl-gobject-introspection/cl-gobject-introspection.asd /root/common-lisp/nyxt/_build/cl-webkit/webkit2/cl-webkit2.asd)