local-repo [options]
Specifies the repo you want to work with. This can either be a path to a repo directory or database or a repo name if set up in the config. If it is a path to a directory, this directory can be empty but must exist.
If no option is specified, local-repo will print some general info about the repo.
Add packages to the repo. can point to a local or remote package file, PKGBUILD tarball, PKGBUILD file or directory containing a PKGBUILD file.
If points to a package file, local-repo just adds the package to the repo. If points to a PKGBUILD tarball|file|directory, local-repo tries to make a new package using makepkg and adds it to the repo. Supported tarball extensions are .tar, .tar.gz and .tar.bz2.
If points to a remote file local-repo tries to download the file before processing it. Supported protocols are HTTP(S) and FTP.
Add packages from the AUR. must be the name of a package, which is available in the AUR. If everything works fine, local-repo will download, make and add the packages to the repo.
Rebuild packages. must be the name of a packge, for which a stored PKGBUILD exists. If local-repo can find this stored PKGBUILD, it will try to rebuild the package.
NOTE: To make that feature work, you have to set the pkgbuild option in your config.
Run an integrity check. local-repo checks if all packages listed in the database have a valid checksum, if their signature files exists (if they are marked as signed) and if there are packages in the repo, which are not listed in the database.
Clear the cache. local-repo will remove the cache file. You should do this, when local-repo behaves strange.
The elephant never forgets.
Force an operation. By default you can not add a package, if it is already in the repo. If you want to up- or downgrade a package, you can use this option together with --add or --aur-add.
Use an alternative config file. By default local-repo tries to load ~/.config/local-repo. Using this option you can override this path.
Print a help message and exit.
Print some package info. is the name of a package, which is in the repo. local-repo will print everything it knows about it.
List all packages. local-repo will print name and version of every package listed in the database.
Remove packages. local-repo will remove all specified packages from the repo database and delete the package files (and signature files).
Restore the repo database. Removes the current database and creates a new one by adding all packages available in the repo.
Search the repo. local-repo finds all packages, which have in their names. The output will be like using --list.
Upgrade all AUR packages. local-repo collects some info from the AUR about all packages and will upgrade them, if there is a new version available.
Packages added to the no-aur-upgrade option in your config will be ignored.
Upgrade all VCS based packages, which are available in the AUR. local-repo upgrades all packages with a VCS suffix (-git, -cvs, -svn, -hg, -darcs, -bzr) using the latest PKGBUILD from the AUR.
If you just want to upgrade a VCS package without downloading the latest PKGBUILD, you should use --rebuild.
To configure local-repo, create the config file ~/.config/local-repo. Any other place is also possible using the --config switch. Maybe you want to copy the example from /usr/share/local-repo/config.example and edit it. The syntax is pretty common:
You can choose any free except of all. The [all] section is reserved for global options. is mandatory, anything else is optional. When you have finished, you can run local-repo reponame [options]. Available options are:
The absolute path to the repo. This is the replacement for the repo argument, so it can point to the repo directory or the repo database. (The database should be preferred, because of performance issues.)
The path to the cache file. This path can either be absolute or relative to path. Default is .cache.
The path to the log file. This path can either be absolute or relative to path. Default is .log.
Path to the PKGBUILD store. This path can either be absolute or relative to path. If this is set, local-repo will store all PKGBUILDs in this directory.
Path to the buidlog store. This path can either be absolute or relative to path. If this path is set, local-repo will store all log files produced by makepkg -L in this directory.
Sign packages. If set to yes, true, 1 or on, local-repo will run makepkg --sign, else makepkg --nosign to build the packages.
NOTE: You need to set up your gpg to use this feature.
Sign the database. If set to yes, true, 1 or on, local-repo will run repo-(add|remove) --verify --sign, to add|remove packages to|from the database.
NOTE: You need to set up your gpg to use this feature.
A space separated list of packages, which will be ignored, when using --aur-upgrade
Uninstall dependencies. If set to yes, true, 1 or on, local-repo uninstalls all previously installed dependencies after adding the package.
This list of supported options is still growing, so you may want to have a look at it from time to time. Here is one working example of a config file:
These commands will create a new repo and add vim-json and vim-largefile from the AUR to it.
This will download, make and add|upgrade a package.
This will upgrade bash-completion-git by rebuilding it.
Please report bugs at:
https://github.com/ushis/local-repo/issues
Please translate local-repo at:
https://www.transifex.net/projects/p/local-repo/
Get the code from GitHub
git clone git://github.com/ushis/local-repo.git local-repo
Get the PKGBUILD from the AUR
https://aur.archlinux.org/packages.php?ID=56876
Or just use local-repo
local-repo my-favorite-packages -A local-repo