aboutsummaryrefslogtreecommitdiff
path: root/lib/tools/list.nom
blob: 3493263609a96e8723a73e44c116761755b3fd28 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!/usr/bin/env nomsu
#
    A tool to list installed third party Nomsu packages
    
    Usage:
        nomsu -t list
    
use "filesystem"
use "commandline"
use "shell"

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

command line program with $args:
    $packages = (=sh "ls \$(NOMSU PACKAGEPATH)")
    say "Installed packages:"
    for $f in ($packages, lines):
        if ($f != ""):
            $f = ($f, with "%.nom$" -> "")
            say "  * \$f"