Print history Web Browser on file txt

This commit is contained in:
stef-devs 2022-07-29 10:47:05 +02:00
parent 9d6dad2774
commit 84992a78aa
2 changed files with 13 additions and 1 deletions

3
.gitignore vendored
View File

@ -1,3 +1,4 @@
executable.py
executable.sh
siti.dat
siti.dat
history.txt

11
main.py
View File

@ -2,6 +2,17 @@
import tkinter as tk
#Libraries for execute command
import subprocess
#Libraries for read web browser history
from browser_history.browsers import Firefox
#Print all browser history on txt
with open('history.txt', 'w') as f:
fi = Firefox()
outputs = fi.fetch_history()
his = outputs.histories
for line in his:
f.write(str(line))
f.write('\n')
window = tk.Tk()
#Resolution program