Mailinglist Archive: yast-devel (246 mails)

< Previous Next >
[yast-devel] Re: [yast-commit] <rest-service> master : patches module: added policikit class, which is parent of package and patch model
  • From: Josef Reidinger <jreidinger@xxxxxxx>
  • Date: Mon, 24 Aug 2009 13:48:01 +0200
  • Message-id: <4A927DF1.6060808@xxxxxxx>
On 08/24/2009 01:31 PM, Bjoern Geuken wrote:
ref: refs/heads/master
commit 10e502901ee5e98552aa1c701cf7d2d965587fa2
Author: Bjoern Geuken <bgeuken@xxxxxxx>
Date: Mon Aug 24 13:31:19 2009 +0200

patches module: added policikit class, which is parent of package and
patch model
---
.../patches/app/controllers/packages_controller.rb | 27 -----
.../patches/app/controllers/patches_controller.rb | 19 +++-
plugins/patches/app/models/package.rb | 90 ++++------------
plugins/patches/app/models/patch.rb | 70 ++-----------
plugins/patches/app/models/policykit.rb | 112
++++++++++++++++++++
5 files changed, 159 insertions(+), 159 deletions(-)

diff --git a/plugins/patches/app/models/policykit.rb
b/plugins/patches/app/models/policykit.rb
new file mode 100644
index 0000000..f5bad05
--- /dev/null
+++ b/plugins/patches/app/models/policykit.rb
@@ -0,0 +1,112 @@
+require "dbus"
+require 'socket'
+require 'thread'
+
+# Used to stop DBus::Main loop
+class PKErrorException < Exception; end
+# Used to stop DBus::Main loop
+class PKFinishedException < Exception; end
+
+# Model for patches available via package kit
+class Policykit
+

Hi, I don't see any reason for PolicyKit name, maybe you want name it
PackageKit?
This patch is nice example of DRY refactoring, good job ;)

--
Josef Reidinger
YaST team
maintainer of perl-Bootloader, YaST2-Repair, webyast modules language
and time
--
To unsubscribe, e-mail: yast-devel+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-devel+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups