[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnu-arch-users] Features command for arch
From: |
James Blackwell |
Subject: |
[Gnu-arch-users] Features command for arch |
Date: |
Sat, 28 Aug 2004 12:17:27 -0400 |
User-agent: |
Mutt/1.5.6+20040523i |
ddaa and I put our heads together not long ago, and we came up with a new
feature that would probably help programs like pyarch and aba. This new
command, called "tla features" would list features and feature version
numbers. One could also query either for a specific feature, or a specific
version of a feature. Please see the example output at the end of this
email.
How it will work:
There's the easy way to do this, and the hard way to do this. I'm inclined
to implement the easy way. The easy way is to in libarch implement a
handful of arch_features functions along these lines:
int arch_feature_query (t_uchar *featureid)
returns the feature # for the requested feature, 0 if feature does not
exist
rel_table arch_features_get
returns a rel_table of arch features, of which each entry contrains:
"feature_name:version"
The list of features and versions will be kept in a simple null terminated
array.
EXAMPLE OUTPUT:
$ tla features
tla-features-begin
file-id-escaping:1
archive-checksums:2
tla-features-end
(always a return code of 0)
$ tla features file-id-escaping
1
(with a return code of 0)
$ tla features archive-checksums
2
(return code of 0)
$ tla features archive-checksums 1
(return code of 0)
$ tla features archive-checksums 3
(return code of 1)
$ tla features nonexistant-feature
(return code of 1)
--
James Blackwell Try something fun: For the next 24 hours, give
Smile more! each person you meet a compliment!
GnuPG (ID 06357400) AAE4 8C76 58DA 5902 761D 247A 8A55 DA73 0635 7400
- [Gnu-arch-users] Features command for arch,
James Blackwell <=