17 lines
		
	
	
		
			297 B
		
	
	
	
		
			Bash
		
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			297 B
		
	
	
	
		
			Bash
		
	
	
	
#!/bin/bash
 | 
						|
 | 
						|
# Initialize an array
 | 
						|
lines=()
 | 
						|
 | 
						|
# Read each line into the array
 | 
						|
while IFS= read -r line; do
 | 
						|
    lines+=("$line")
 | 
						|
done <<< "$NAUTILUS_SCRIPT_SELECTED_FILE_PATHS"
 | 
						|
 | 
						|
# Get the length of the array
 | 
						|
length=${#lines[@]}
 | 
						|
 | 
						|
# Remove the last entry
 | 
						|
unset 'lines[length-1]'
 | 
						|
 | 
						|
pairdrop "${lines[@]}" |