You are not logged in.

#1 2007-12-28 23:59:06

stylopath
Member
Registered: 2007-07-26
Posts: 112

How to tell pacman to install files from a certain repo

Hi!
As the title implies, i have a certain repo and want to sync all installed packages with these one (for example want to replace kernel26 with my own one).

Since i don't touch the pkgbuilds (i just compile with custom cflags) the pkgver is always the same as in the official repos.
Now i don't know how to tell pacman to install all files from this repo.

A way how to set pkgver++ on all PKGBUILDS in /var/abs would also solve my problems.

I hope someone here can help me.

Offline

#2 2007-12-29 00:00:48

[vEX]
Member
From: Sweden
Registered: 2006-11-23
Posts: 450

Re: How to tell pacman to install files from a certain repo

If you put your repository over the core one in your pacman.conf I believe it would use the packages in your repository over those in core/extra if they have the same name.

IE:

[customrepo]
...

[core]
...

[extra]
...

Last edited by [vEX] (2007-12-29 00:01:24)


PC: Antec P182B | Asus P8Z77-V PRO | Intel i5 3570k | 16GB DDR3 | GeForce 450GTS | 4TB HDD | Pioneer BDR-207D | Asus Xonar DX | Altec Lansing CS21 | Eizo EV2736W-BK | Arch Linux x86_64
HTPC: Antec NSK2480 | ASUS M3A78-EM (AMD 780G) | AMD Athlon X3 425 | 8GB DDR2 | GeForce G210 | 2TB HDD | Arch Linux x86_64
Server: Raspberry Pi (model B) | 512MB RAM | 750GB HDD | Arch Linux ARM

Offline

#3 2007-12-29 00:55:52

stonecrest
Member
From: Boulder
Registered: 2005-01-22
Posts: 1,190

Re: How to tell pacman to install files from a certain repo

pacman -S repo/package works too


I am a gated community.

Offline

#4 2007-12-29 03:21:58

stylopath
Member
Registered: 2007-07-26
Posts: 112

Re: How to tell pacman to install files from a certain repo

pacman -S repo/package works too

But this works only for 1 package each time. I want pacman to replace all installed packages by the custom ones.

Sadly, vex' solution neither works though the pkgver's are equal and so pacman doesn't  upgrade the files by doing a "pacman -Syu".

Offline

#5 2007-12-29 03:36:44

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: How to tell pacman to install files from a certain repo

Use ....pacman -S repo/*


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#6 2007-12-29 04:31:05

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: How to tell pacman to install files from a certain repo

Perhaps use ...pacman -Syuf repo/*


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#7 2007-12-29 04:39:08

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: How to tell pacman to install files from a certain repo

Another possibility....

Generate a repo on flash drive with your desired packages.  When upgrading, use ...pacman -Syuw... and copy the upgrades to the flash repo.  Edit where necessary.

Then call ....pacman -Udf repo/* from the flash drive.

EDIT:  See also cachedir in man pacman and search google for more info.

Last edited by lilsirecho (2007-12-29 04:55:59)


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

#8 2007-12-29 08:01:44

gradgrind
Member
From: Germany
Registered: 2005-10-06
Posts: 921

Re: How to tell pacman to install files from a certain repo

Are you sure [vEX]'s method doesn't work? I'm pretty sure it should work. Is the package database in your repo ok? Have you cleared the 'wrong' packages out of the package cache?

Offline

#9 2007-12-29 15:28:29

stylopath
Member
Registered: 2007-07-26
Posts: 112

Re: How to tell pacman to install files from a certain repo

Vex's method makes pacman use my repo over the official ones, but with the pkgver of my package being similar to that of the installed package, pacman doesnt update.

Anyway, this shows me the way of all coming updates (first a makeworld -c  and then pacman -Syu uses my repo for updates then).

lilsirecho's ideas look good, but pacman -S repo/* again syncs all files in the repo, but i only want already installed packages to be synced. Now i'm off playing a bit with all these suggestions, thanks in advance!

Offline

#10 2007-12-29 15:33:52

stylopath
Member
Registered: 2007-07-26
Posts: 112

Re: How to tell pacman to install files from a certain repo

well, i don't think this all works how i expected it to. I should try another solution:

I need a simple bash script which edits all PKGBUILDs in a certain directory (recursive, of course).
In detail, it has to change pkgver to pkgver+1 - Then pacman should do updates automatically using the right repo.
Is perhaps someone around who might help me scripting this (i'm a noob when it comes to bash, especially manipulating files)?
I know that it's not really on topic anymore, but i don't want to open a new thread if that's not neccessary.

Thanks.

Offline

#11 2007-12-29 21:08:34

sinister99
Member
Registered: 2007-04-10
Posts: 136

Re: How to tell pacman to install files from a certain repo

I did something like this a while back, and wrote a script for it.  I think it went something like this:

There is an old thread in the user contributions forum with a script to put all the PKGBUILDs from installed packages in the same directory.  You could then build those packages with makepkg and install all those packages.  This way you would only be building packages that are installed.

Offline

#12 2007-12-29 21:58:33

lilsirecho
Veteran
Registered: 2003-10-24
Posts: 5,000

Re: How to tell pacman to install files from a certain repo

See my post in pacman forum concerning cachedir.....


Prediction...This year will be a very odd year!
Hard work does not kill people but why risk it: Charlie Mccarthy
A man is not complete until he is married..then..he is finished.
When ALL is lost, what can be found? Even bytes get lonely for a little bit!     X-ray confirms Iam spineless!

Offline

Board footer

Powered by FluxBB