Skip to content
This repository has been archived by the owner on May 31, 2018. It is now read-only.

Rework --cachedir with -Sc option #519

Closed
raingloom opened this issue Jun 19, 2016 · 5 comments
Closed

Rework --cachedir with -Sc option #519

raingloom opened this issue Jun 19, 2016 · 5 comments

Comments

@raingloom
Copy link

I was trying to use the first long enough to realize it is not where packages will be downloaded to with -Sw.

Does --cachedir influence PKGDEST? I get that PKGDEST is for locally built packages only.

@rmarquis rmarquis added this to the 4.6.x - maintenance milestone Jun 20, 2016
@rmarquis
Copy link
Owner

Actually, no. I don't think makepkg takes --cachedir into account. This might however make sense to support it as an override of PKGDEST for AUR packages. I'll check this out, thanks for the report.

@rmarquis rmarquis added the todo label Jun 20, 2016
@rmarquis
Copy link
Owner

rmarquis commented Jul 2, 2016

For the records:

CacheDir = path/to/cache/dir
           Overrides the default location of the package cache directory. A typical default is /var/cache/pacman/pkg/. Multiple cache directories can be specified, and they are tried in the order they are
           listed in the config file. If a file is not found in any cache directory, it will be downloaded to the first cache directory with write access.  NOTE: this is an absolute path, the root path is
           not automatically prepended.
--cachedir <dir>
           Specify an alternative package cache location (a typical default is /var/cache/pacman/pkg). Multiple cache directories can be specified, and they are tried in the order they are passed to pacman.
           NOTE: This is an absolute path, and the root path is not automatically prepended.

I'm still not sure if and how --cachedir should influence PKGDEST, but setting an additional path in CacheDir might actually be a much better idea than extending -Sc in pacaur code. See this relevant post and that one in the Arch forums.

@rmarquis
Copy link
Owner

The -Sc, -Scc functions now take CacheDir into account (b61c3ed).

What should be done:

  • remove the other hardcoded /var/cache/pacman/pkg/ in Prompt()
  • --cachedir should add the added cache in the CacheDir array (and also be passed to pacman)

pacconf would be great to use here, but I don't want to add yet another AUR dep. Maybe later if pacutils gets merged with pacman tools.

Still can't make my mind about the relationship with PKGDEST...

@rmarquis rmarquis modified the milestones: 4.6.x - maintenance, 5.0.x - later Oct 1, 2016
@rmarquis
Copy link
Owner

rmarquis commented Oct 1, 2016

PKGDEST should stay independent from --cachedir. This isn't even a pacaur option, but an option from makepkg. No clarification is even needed in the pacaur man page.

@rmarquis rmarquis modified the milestones: 5.0.x - later, 4.7.x - new features Oct 1, 2016
@rmarquis rmarquis changed the title Clarify the relation of PKGDEST and --cachedir Rework --cachedir with -Sc option Oct 1, 2016
@rmarquis
Copy link
Owner

This has been done in #569, which includes the removal of the CacheDir trick.
Closing now. The inclusion of pacconf improvement is tracked in #433.

@rmarquis rmarquis modified the milestones: 4.7.x - new features, 5.0.x - later Oct 17, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants