Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Jun 26th, 2005, 9:18 AM   #1
SaturN
Programmer
 
Join Date: Apr 2005
Location: Uk
Posts: 68
Rep Power: 4 SaturN is on a distinguished road
Wink My ex g/f has prying eyes, and likes to read my chat logs, So....

hehe, my girlfriend is obsessed, and likes to read all my msn chat logs, and it's hard to find the time to delete them without her watching.. So I thought i would let something else do my dirty work, and stop her watching me, so they all get removed in double click time!!!
Ain't sure if this would help anyone else, I think it's just me with the physco!!!
import os
path = "WHERE YOUR CHAT LOGS ARE STORED END WITH \\"
rem = []
for file in os.listdir(path):
	if file.endswith(".xml"): #My chat logs are xml files, if your's are different  
									  #change the ending ending here
		try:
			rem = []
			rem.append(path)
			rem.append(file)
			rem = "".join(rem)
			os.remove(rem)
		except:
			IOError

hope some one is in need for it as much as me!!! LOL
__________________
while me is alive:
	make(life,simple)
SaturN is offline   Reply With Quote
Old Jun 26th, 2005, 10:20 AM   #2
stevengs
Professional Programmer
 
stevengs's Avatar
 
Join Date: May 2005
Location: Bad Nauheim, Germany
Posts: 436
Rep Power: 4 stevengs is on a distinguished road
Quote:
Originally Posted by SaturN
...just me with the physco!!!...
do you have something to hide from your fizz-co ( haha )? Busy chatting up other fizz-cos online with yours peeking over you shoulder?

I am the fizz-co in my relationship.. so send this file to my wife
__________________
-Steven
"Is this a piece of your brain?" - Basil Fawlty
stevengs is offline   Reply With Quote
Old Jun 26th, 2005, 10:37 AM   #3
tempest
Programming Guru
 
tempest's Avatar
 
Join Date: Oct 2004
Posts: 1,041
Rep Power: 6 tempest is on a distinguished road
Send a message via ICQ to tempest Send a message via AIM to tempest Send a message via Yahoo to tempest
Why is your ex-gf able to get to your computer to see your chat logs?
__________________

tempest is offline   Reply With Quote
Old Jun 26th, 2005, 11:00 AM   #4
Ooble
I eat cake for breakfast.
 
Ooble's Avatar
 
Join Date: Jul 2004
Location: In my box.
Posts: 4,434
Rep Power: 9 Ooble is on a distinguished road
Why not just not save the logs?
__________________
Me :: You :: Them
Ooble is offline   Reply With Quote
Old Jun 26th, 2005, 12:19 PM   #5
Cerulean
Professional Programmer
 
Cerulean's Avatar
 
Join Date: Apr 2005
Location: London, England
Posts: 459
Rep Power: 4 Cerulean is on a distinguished road
I'm curious as to your method of string concatenation. What inspired the concatenation via a list?
The best way to concatenate string representations of paths is via os.path.join. The function is kind enough to decide whether or not it needs to add a slash in the joined string, so os.path.join("/home/foo", "file.txt") and os.path.join("/home/foo/", "file.txt") both give you "/home/foo/file.txt".
Cerulean is offline   Reply With Quote
Old Jun 26th, 2005, 12:51 PM   #6
SaturN
Programmer
 
Join Date: Apr 2005
Location: Uk
Posts: 68
Rep Power: 4 SaturN is on a distinguished road
Hmm, i've never seen that before!! Thanks for that,
__________________
while me is alive:
	make(life,simple)
SaturN is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 12:44 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC