Difference between revisions of "Pkgtxt2db"
From Salix OS
(change svn link to the new git one) |
(updated) |
||
Line 1: | Line 1: | ||
− | =Description= | + | = Description = |
+ | |||
Pkgtxt2db is a utility for Slackware and Slackware based operating system only. | Pkgtxt2db is a utility for Slackware and Slackware based operating system only. | ||
Line 7: | Line 8: | ||
*CSV | *CSV | ||
*JSON | *JSON | ||
+ | *SQLite | ||
+ | *XML | ||
− | + | = Download = | |
− | =Download= | + | |
Sources tarballs and Slackware packages can be found there: | Sources tarballs and Slackware packages can be found there: | ||
http://people.salixos.org/fredg/packages/Pkgtxt2db/ | http://people.salixos.org/fredg/packages/Pkgtxt2db/ | ||
Line 16: | Line 18: | ||
$ git clone ssh://git@github.com:fredg/pkgtxt2db.git | $ git clone ssh://git@github.com:fredg/pkgtxt2db.git | ||
− | = | + | |
+ | = Usage = | ||
+ | |||
pkgtxt2db [options] | pkgtxt2db [options] | ||
Options: | Options: | ||
− | + | -h, --help | |
− | + | Simple help | |
− | + | --version | |
− | + | Print pkgtxt2db version | |
+ | -u, --update | ||
+ | It will fetch and download a new PACKAGES.TXT from your choosen repository. | ||
+ | -t, --target | ||
+ | Choose between slackware or salix repositories. | ||
+ | --repo | ||
+ | Choose the arch repository, it can be i486 or x86_64 | ||
+ | -r, --release | ||
+ | Choose the slackware or salix release. It can be: current (if exist), 14.0, 13.37, ..., 13.0 | ||
+ | -e, --expa | ||
+ | Choose between the patches or extra Slackware repository | ||
+ | -c, --convert | ||
+ | Choose your database format, it can be: | ||
+ | - csv : Convert PACKAGES.TXT to a CSV database | ||
+ | - json : Convert PACKAGES.TXT to a JSON database | ||
+ | - sqlite: Convert PACKAGES.TXT to a SQLITE database | ||
+ | - xml : Convert PACKAGES.TXT to a XML database | ||
+ | -o, --output | ||
+ | Choose the name of the output file. If none is choosen, packages will be used. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
= Examples = | = Examples = | ||
− | + | Here are some usages examples. | |
− | It will convert PACKAGES.TXT from the | + | |
+ | pkgtxt2db -u -t slackware --repo x86_64 -r current -c json -o slack64.json | ||
+ | |||
+ | It will fetch and convert PACKAGES.TXT from the Slackware current x86_64 repository to a JSON database: slack64.json. | ||
+ | |||
+ | pkgtxt2db -c csv | ||
+ | |||
+ | It will convert the PACKAGES.TXT found in your directory to a CSV database (; separated): packages.csv. You can open it with libreoffice ;) | ||
− | |||
− | |||
Revision as of 08:21, 17 December 2012
Contents |
Description
Pkgtxt2db is a utility for Slackware and Slackware based operating system only.
It can be use to convert PACKAGES.TXT to various database formats:
Are supported for now:
- CSV
- JSON
- SQLite
- XML
Download
Sources tarballs and Slackware packages can be found there: http://people.salixos.org/fredg/packages/Pkgtxt2db/
The source code is also available through github. You can get it with:
$ git clone ssh://git@github.com:fredg/pkgtxt2db.git
Usage
pkgtxt2db [options]
Options:
-h, --help Simple help --version Print pkgtxt2db version -u, --update It will fetch and download a new PACKAGES.TXT from your choosen repository. -t, --target Choose between slackware or salix repositories. --repo Choose the arch repository, it can be i486 or x86_64 -r, --release Choose the slackware or salix release. It can be: current (if exist), 14.0, 13.37, ..., 13.0 -e, --expa Choose between the patches or extra Slackware repository -c, --convert Choose your database format, it can be: - csv : Convert PACKAGES.TXT to a CSV database - json : Convert PACKAGES.TXT to a JSON database - sqlite: Convert PACKAGES.TXT to a SQLITE database - xml : Convert PACKAGES.TXT to a XML database -o, --output Choose the name of the output file. If none is choosen, packages will be used.
Examples
Here are some usages examples.
pkgtxt2db -u -t slackware --repo x86_64 -r current -c json -o slack64.json
It will fetch and convert PACKAGES.TXT from the Slackware current x86_64 repository to a JSON database: slack64.json.
pkgtxt2db -c csv
It will convert the PACKAGES.TXT found in your directory to a CSV database (; separated): packages.csv. You can open it with libreoffice ;)