2019-12-16 15:31:26 -06:00
|
|
|
#!/usr/bin/env python3
|
2008-07-18 11:29:53 +00:00
|
|
|
|
|
|
|
|
# The general algorithm this program follows goes like this:
|
|
|
|
|
# Run tar to extract control from control.tar.gz from the package.
|
|
|
|
|
# Insert the filename, size, and md5 lines before the description.
|
|
|
|
|
# Call it like this:
|
2008-07-28 10:29:45 +00:00
|
|
|
# find . -name \*.opk | xargs -n 1 makePackage > Packages
|
2016-05-27 16:26:42 -05:00
|
|
|
from __future__ import absolute_import
|
|
|
|
|
from __future__ import print_function
|
2008-07-18 11:29:53 +00:00
|
|
|
|
|
|
|
|
import sys
|
|
|
|
|
import opkg
|
|
|
|
|
|
|
|
|
|
fn = sys.argv[1]
|
|
|
|
|
pkg = opkg.Package(fn)
|
2012-03-29 14:45:24 +02:00
|
|
|
print(pkg)
|