mirror of
				https://github.com/labwc/labwc.git
				synced 2025-11-03 09:01:51 -05:00 
			
		
		
		
	Add list-themes.sh
This commit is contained in:
		
							parent
							
								
									8a42bc9184
								
							
						
					
					
						commit
						d4bd99888e
					
				
					 1 changed files with 19 additions and 0 deletions
				
			
		
							
								
								
									
										19
									
								
								tools/theme/list-themes.sh
									
										
									
									
									
										Executable file
									
								
							
							
						
						
									
										19
									
								
								tools/theme/list-themes.sh
									
										
									
									
									
										Executable file
									
								
							| 
						 | 
				
			
			@ -0,0 +1,19 @@
 | 
			
		|||
#!/bin/sh
 | 
			
		||||
#
 | 
			
		||||
# List available openbox themes
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
printf '%b\n' "#icons\ttheme name"
 | 
			
		||||
printf '%b\n' "-------------------"
 | 
			
		||||
 | 
			
		||||
for d in $HOME/.themes/* /usr/share/themes/*; do
 | 
			
		||||
	if [ -d "$d/openbox-3" ]; then
 | 
			
		||||
		icon_count=0
 | 
			
		||||
		for f in $d/openbox-3/*; do
 | 
			
		||||
			case $f in
 | 
			
		||||
				*xbm) : $(( icon_count++ )) ;;
 | 
			
		||||
			esac
 | 
			
		||||
		done
 | 
			
		||||
		printf '%b\n' "$icon_count\t$(basename $d)"
 | 
			
		||||
	fi
 | 
			
		||||
done
 | 
			
		||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue