mirror of
				https://github.com/mitchell/dotfiles.git
				synced 2025-11-03 21:25:26 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			36 lines
		
	
	
		
			831 B
		
	
	
	
		
			Fish
		
	
	
		
			Executable file
		
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
		
			831 B
		
	
	
	
		
			Fish
		
	
	
		
			Executable file
		
	
	
	
	
#!/usr/bin/env fish
 | 
						|
 | 
						|
function main
 | 
						|
    log 'Upgrading debian to unstable.' head
 | 
						|
 | 
						|
    echo '
 | 
						|
deb http://ftp.us.debian.org/debian unstable main contrib non-free
 | 
						|
deb-src http://ftp.us.debian.org/debian unstable main contrib non-free' | sudo tee /etc/apt/sources.list
 | 
						|
 | 
						|
    sudo apt-get update >/dev/null 2>&1
 | 
						|
    sudo apt-get dist-upgrade --yes
 | 
						|
 | 
						|
    log 'Done upgrading debian to unstable and rebooting.' tail
 | 
						|
 | 
						|
    sudo reboot
 | 
						|
end
 | 
						|
 | 
						|
function log -a message level
 | 
						|
    if test "$level" = head
 | 
						|
        echo "
 | 
						|
###########################################################################################
 | 
						|
#
 | 
						|
#--> $message"
 | 
						|
    else if test "$level" = tail
 | 
						|
        echo "#
 | 
						|
#--> $message
 | 
						|
#
 | 
						|
###########################################################################################
 | 
						|
"
 | 
						|
    else
 | 
						|
        echo -e "#\n#--> $message"
 | 
						|
    end
 | 
						|
end
 | 
						|
 | 
						|
main
 |