Merge branch 'fix/explorer/netbsd' into 'master'
Fix global explorers for NetBSD See merge request ungleich-public/cdist!917
This commit is contained in:
		
				commit
				
					
						a6cd767c8f
					
				
			
		
					 3 changed files with 4 additions and 3 deletions
				
			
		| 
						 | 
				
			
			@ -33,6 +33,7 @@ case "$os" in
 | 
			
		|||
    ;;
 | 
			
		||||
 | 
			
		||||
    "freebsd"|"netbsd")
 | 
			
		||||
        PATH=$(getconf PATH)
 | 
			
		||||
        sysctl -n hw.ncpu
 | 
			
		||||
    ;;
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -30,9 +30,8 @@ case $uname_s in
 | 
			
		|||
        sysctl -n hw.disknames | grep -Eo '[lsw]d[0-9]+'
 | 
			
		||||
    ;;
 | 
			
		||||
    NetBSD)
 | 
			
		||||
        PATH="${PATH}:/usr/local/sbin:/usr/sbin:/sbin"
 | 
			
		||||
        sysctl -n hw.disknames \
 | 
			
		||||
        | awk 'BEGIN { RS = " " } /^[lsw]d[0-9]+/'
 | 
			
		||||
        PATH=$(getconf PATH)
 | 
			
		||||
        sysctl -n hw.disknames | awk -v RS=' ' '/^[lsw]d[0-9]+/'
 | 
			
		||||
    ;;
 | 
			
		||||
    Linux)
 | 
			
		||||
        # list of major device numbers toexclude:
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -30,6 +30,7 @@ case "$os" in
 | 
			
		|||
    ;;
 | 
			
		||||
 | 
			
		||||
    *"bsd")
 | 
			
		||||
        PATH=$(getconf PATH)
 | 
			
		||||
        echo "$(sysctl -n hw.physmem) / 1048576" | bc
 | 
			
		||||
    ;;
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue