View difference between Paste ID: aqx483pn and JpCZCjdu
SHOW: | | - or go back to the newest paste.
1
#!/bin/bash
2
DIR="~/.cache/sessions/"
3
4
delete_sessions(){
5
	# Deletes whatever is in DIR
6
	rm -r -- "$DIR"
7
}
8
9
is_directory(){
10
	if [ -d "$DIR" ]; then
11-
		deletesessions
11+
		delete_sessions
12
	else
13
		echo "wtf man, it's not there?!"
14
	fi
15
}
16
17
promt_logout() {
18
	xfce4-session-logout
19
}
20
21
is_directory
22
promt_logout