File: vendor.guess

package info (click to toggle)
ocfs2-tools 1.8.6-1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 6,232 kB
  • sloc: ansic: 86,865; sh: 5,781; python: 2,380; makefile: 1,305
file content (34 lines) | stat: -rwxr-xr-x 551 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/sh

list_vendors()
{
    ls -1 vendor | while read -r line
    do
        if [ "$line" = "common" ]
        then
            continue
        fi
        if [ ! -d "vendor/$line" ]
        then
            continue
        fi
        echo $line
    done

    # Make common last
    if [ -d "vendor/common" ]
    then
        echo "common"
    fi
}

list_vendors | while read -r v
do
    if [ -x "vendor/${v}/vendor.guess" ]
    then
        if "vendor/${v}/vendor.guess" >/dev/null 2>&1
        then
            echo "$v"
        fi
    fi
done