forked from Mirror/pmbootstrap
pmbootstrap init: Show pkgdesc for each postmarketos-ui package (#763)
This way we could give the user a rough idea what will be installed, and also use this to display a short warning about long compile times (e.g. until the plasma mobile stuff is upstreamed).
This commit is contained in:
parent
34ac1c1538
commit
92e55ae1cd
6 changed files with 18 additions and 13 deletions
|
@ -1,7 +1,7 @@
|
|||
pkgname=postmarketos-ui-hildon
|
||||
pkgver=1
|
||||
pkgrel=1
|
||||
pkgdesc="Lightweight desktop, optimized for single-touch touchscreen devices"
|
||||
pkgrel=2
|
||||
pkgdesc="(X11) Lightweight GTK+2 UI (optimized for single-touch touchscreens)"
|
||||
url="https://github.com/postmarketOS"
|
||||
arch="noarch"
|
||||
license="GPL3+"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
pkgname=postmarketos-ui-weston
|
||||
pkgver=3
|
||||
pkgver=4
|
||||
pkgrel=1
|
||||
pkgdesc="Meta package for weston"
|
||||
pkgdesc="(Wayland) Reference compositor (demo, not a phone interface)"
|
||||
url="https://github.com/postmarketOS"
|
||||
arch="noarch"
|
||||
license="GPL3+"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
pkgname=postmarketos-ui-xfce4
|
||||
pkgver=0.0
|
||||
pkgrel=2
|
||||
pkgdesc="Meta package for xfce4"
|
||||
pkgrel=3
|
||||
pkgdesc="(X11) Lightweight GTK+3 desktop (stylus recommended)"
|
||||
url="https://github.com/postmarketOS/xfce4-phone"
|
||||
arch="noarch"
|
||||
license="GPL3"
|
||||
|
|
|
@ -172,6 +172,7 @@ apkbuild_attributes = {
|
|||
"makedepends": {"array": True},
|
||||
"options": {"array": True},
|
||||
"pkgname": {"array": False},
|
||||
"pkgdesc": {"array": False},
|
||||
"pkgrel": {"array": False},
|
||||
"pkgver": {"array": False},
|
||||
"subpackages": {"array": True},
|
||||
|
|
|
@ -60,7 +60,9 @@ def ask_for_work_path(args):
|
|||
def ask_for_ui(args):
|
||||
ui_list = pmb.helpers.ui.list(args)
|
||||
logging.info("Available user interfaces (" +
|
||||
str(len(ui_list) - 1) + "): " + ", ".join(ui_list))
|
||||
str(len(ui_list) - 1) + "): ")
|
||||
for ui, description in ui_list.items():
|
||||
logging.info("* " + ui + ": " + description)
|
||||
while True:
|
||||
ret = pmb.helpers.cli.ask(args, "User interface", None, args.ui, True)
|
||||
if ret in ui_list:
|
||||
|
|
|
@ -18,16 +18,18 @@ along with pmbootstrap. If not, see <http://www.gnu.org/licenses/>.
|
|||
"""
|
||||
import os
|
||||
import glob
|
||||
import pmb.parse
|
||||
|
||||
|
||||
def list(args):
|
||||
"""
|
||||
Get all UIs, for which aports are available
|
||||
:returns: ["postmarketos-ui-one", "postmarketos-ui-two", ..., "none"]
|
||||
Get all UIs, for which aports are available with their description.
|
||||
|
||||
:returns: {"none": "No graphical...", "weston": "Wayland reference..."}
|
||||
"""
|
||||
ret = []
|
||||
for path in glob.glob(args.aports + "/main/postmarketos-ui-*"):
|
||||
ret = {"none": "No graphical environment"}
|
||||
for path in sorted(glob.glob(args.aports + "/main/postmarketos-ui-*")):
|
||||
apkbuild = pmb.parse.apkbuild(args, path + "/APKBUILD")
|
||||
ui = os.path.basename(path).split("-", 2)[2]
|
||||
ret.append(ui)
|
||||
ret.append('none')
|
||||
ret[ui] = apkbuild["pkgdesc"]
|
||||
return ret
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue