diff options
| -rw-r--r-- | shell/_zshrc | 55 | 
1 files changed, 1 insertions, 54 deletions
| diff --git a/shell/_zshrc b/shell/_zshrc index 0594d08..7539c9e 100644 --- a/shell/_zshrc +++ b/shell/_zshrc @@ -91,7 +91,7 @@ function noproxy {  	dconf write /system/proxy/ftp/port "$base_proxy_port"  	proxy_update -	} +}  # restart/reload applications for proxy settings to take effect  function proxy_update { @@ -99,59 +99,6 @@ function proxy_update {  	dropbox-cli start  } -# set lid closing action to sleep -function set_closing_sleep { -	get_closing_action -	if [ $? -eq 0 ]; then -		head -n -2 /etc/systemd/logind.conf | sudo tee /etc/systemd/logind.conf > /dev/null -		echo "Closing action set to sleep if lid is closed." -		sudo systemctl restart systemd-logind.service -	else -		echo "Already set to sleep if lid is closed." -fi -} - -# set lid closing action to nothing -function set_closing_nothing { -	get_closing_action -	if [ $? -eq 1 ]; then -		cat <<'EOF' | sudo tee -a /etc/systemd/logind.conf > /dev/null -#custom -HandleLidSwitch=ignore -EOF -	echo "Closing action set to _not_ sleep if lid is closed." -	sudo systemctl restart systemd-logind.service -	else -		echo "Already set to _not_ sleep if lid is closed." -	fi -} - -# 0 is nothing, 1 is sleep -function get_closing_action { -	grep -q '#custom' /etc/systemd/logind.conf -	return $? -} - -function toggle_laptop_closing_action { -	get_closing_action -	if [ $? -eq 1 ]; then -		set_closing_nothing -	else -		set_closing_sleep -	fi -} - -function update_and_sleep { -	get_closing_action -	save=$? -	set_closing_nothing -	yaourt -Syu --noconfirm - -	[ $save -eq 1 ] && set_closing_sleep - -	systemctl suspend -} -  function 256color_test {  	( x=`tput op` y=`printf %$((${COLUMNS}-6))s`;  	for i in {0..256}; | 
