Git-Url: 
http://git.frugalware.org/gitweb/gitweb.cgi?p=frugal-tweak.git;a=commitdiff;h=98a70866d345630b44ed98f035ab483dcd3b607b

commit 98a70866d345630b44ed98f035ab483dcd3b607b
Author: bouleetbil <bouleet...@frogdev.info>
Date:   Thu Nov 18 11:48:02 2010 +0000

*added python script for update database pacman-g2
*for remove mono rc script

diff --git a/PyUtils/PyFrugalTweakService.py b/PyUtils/PyFrugalTweakService.py
new file mode 100644
index 0000000..b978df3
--- /dev/null
+++ b/PyUtils/PyFrugalTweakService.py
@@ -0,0 +1,33 @@
+"""
+ *  Copyright (C) 2010 by Gaetan Gourdin <bouleet...@frogdev.info>
+ *
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+"""
+
+import time
+import os
+
+
+def UpdateDatabase():
+       os.system("pacman-g2 -Sy 2>/dev/null >/dev/null")
+
+#print("Start frugalware-tweak update database")
+UpdateDatabase()
+while True:
+    time.sleep(3600 ) # 60 min.
+    try:
+        UpdateDatabase()
+    except:
+        pass
diff --git a/PyUtils/PyUtils.mdproj b/PyUtils/PyUtils.mdproj
index 3a323e0..64aa180 100644
--- a/PyUtils/PyUtils.mdproj
+++ b/PyUtils/PyUtils.mdproj
@@ -36,6 +36,7 @@
<Compile Include="irc.py" />
<Compile Include="fw-interfaces\fw-interfaces.py" />
<Compile Include="fw-login-manager\fw-login-manager.py" />
+    <Compile Include="PyFrugalTweakService.py" />
</ItemGroup>
<ItemGroup>
<None Include="fw-interfaces\Create_archive.sh" />
_______________________________________________
Frugalware-git mailing list
Frugalware-git@frugalware.org
http://frugalware.org/mailman/listinfo/frugalware-git

Reply via email to