summaryrefslogtreecommitdiffstats
path: root/src/lib/Client/Tools
diff options
context:
space:
mode:
authorNarayan Desai <desai@mcs.anl.gov>2007-01-18 20:19:27 +0000
committerNarayan Desai <desai@mcs.anl.gov>2007-01-18 20:19:27 +0000
commit46a242872523b8946e2ac48129c32f410b92f15f (patch)
tree0a0be6837ae730052be1c1e8cb1fb58736bdeb61 /src/lib/Client/Tools
parent22a72a07658b765492c0d7dee554c4869312ac25 (diff)
downloadbcfg2-46a242872523b8946e2ac48129c32f410b92f15f.tar.gz
bcfg2-46a242872523b8946e2ac48129c32f410b92f15f.tar.bz2
bcfg2-46a242872523b8946e2ac48129c32f410b92f15f.zip
Add configfile interactive diff support. (Resolves Ticket #279)
Remove query text from statistics upload git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@2697 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'src/lib/Client/Tools')
-rw-r--r--src/lib/Client/Tools/POSIX.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/lib/Client/Tools/POSIX.py b/src/lib/Client/Tools/POSIX.py
index 8fcd8b608..85fd9fac3 100644
--- a/src/lib/Client/Tools/POSIX.py
+++ b/src/lib/Client/Tools/POSIX.py
@@ -204,6 +204,10 @@ class POSIX(Bcfg2.Client.Tools.Tool):
entry.set("current_diff", xml.sax.saxutils.quoteattr(diff))
except:
pass
+ udiff = '\n'.join([x for x in difflib.unified_diff(content.split('\n'), \
+ tempdata.split('\n'))])
+ entry.set('qtext', udiff + "\nInstall ConfigFile %s: (y/N) " % \
+ (entry.get('name')))
return contentStatus and permissionStatus
def InstallConfigFile(self, entry):