From: "Anthony G. Basile" <blueness@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/webapp-config:master commit in: WebappConfig/, doc/
Date: Sat, 24 Aug 2013 23:06:47 +0000 (UTC) [thread overview]
Message-ID: <1377385371.3bbdf6579d88c0abe77519e0148dd0a7dcc7d3fe.blueness@gentoo> (raw)
commit: 3bbdf6579d88c0abe77519e0148dd0a7dcc7d3fe
Author: Devan Franchini <twitch153 <AT> hotmail <DOT> com>
AuthorDate: Fri Aug 23 19:39:31 2013 +0000
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org>
CommitDate: Sat Aug 24 23:02:51 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/webapp-config.git;a=commit;h=3bbdf657
Webappconfig/{config.py,worker.py}: Adds configurable --copy option.
This allows for altering the value of vhost_link_type in
/etc/vhosts/webapp-config to copy files by default when installing
a webapp as opposed to soft-linking or hard-linking. This patch also
repairs the previous damage in which the behavior of the --copy flag
was being ignored; due to the fact that the boolean g_copy was not
being passed down throughout the program because of the extra --cp
flag. Man page alterations have also been made to reflect the removal
of the --cp flag in the program.
X-Gentoo-Bug: 231482
X-Gentoo-Bug-URL: https://bugs.gentoo.org/231482
Signed-off-by: Anthony G. Basile <blueness <AT> gentoo.org>
---
WebappConfig/config.py | 11 ++++++-----
WebappConfig/worker.py | 2 +-
doc/webapp-config.8.xml | 1 -
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/WebappConfig/config.py b/WebappConfig/config.py
index bb86a55..26eab59 100644
--- a/WebappConfig/config.py
+++ b/WebappConfig/config.py
@@ -490,8 +490,7 @@ class Config:
' when creating virtual files. <NOTE>: some pack'
'ages will not work if you use this option')
- group.add_option('--cp',
- '--copy',
+ group.add_option('--copy',
action='store_true',
help = 'Directly copy the webapp files from'
' the /usr/share/webapps/ directory when installing'
@@ -1027,12 +1026,14 @@ class Config:
self.config.set('USER', 'g_link_type', 'soft')
- elif (self.config.has_option('USER', 'g_copy') and
- self.config.getboolean('USER', 'g_copy')):
+ elif ((self.config.has_option('USER', 'vhost_link_type') and
+ self.config.get('USER', 'vhost_link_type') == 'soft') or
+ (self.config.has_option('USER', 'g_copy') and
+ self.config.getboolean('USER', 'g_copy'))):
OUT.debug('Selecting copying of links', 7)
- self.config.set('USER', 'g_link_type', 'clone')
+ self.config.set('USER', 'g_link_type', 'copy')
else:
diff --git a/WebappConfig/worker.py b/WebappConfig/worker.py
index 250f068..5b10060 100644
--- a/WebappConfig/worker.py
+++ b/WebappConfig/worker.py
@@ -508,7 +508,7 @@ class WebappAdd:
if self.__v:
OUT.warn('Failed to softlink (' + str(e) + ')')
- elif self.__link_type == 'clone':
+ elif self.__link_type == 'copy':
try:
OUT.debug('Trying to copy files directly', 8)
diff --git a/doc/webapp-config.8.xml b/doc/webapp-config.8.xml
index 5b0048b..459e301 100644
--- a/doc/webapp-config.8.xml
+++ b/doc/webapp-config.8.xml
@@ -473,7 +473,6 @@
</varlistentry>
<varlistentry>
- <term><option>--cp</option></term>
<term><option>--copy</option></term>
<listitem>
<para>Use this option to create the virtual copy by copying the files from the <filename>/usr/share/webapps/</filename> directories.</para>
next reply other threads:[~2013-08-24 23:06 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-24 23:06 Anthony G. Basile [this message]
-- strict thread matches above, loose matches on Subject: below --
2015-07-02 14:31 [gentoo-commits] proj/webapp-config:master commit in: WebappConfig/, doc/ Devan Franchini
2013-08-03 13:24 Anthony G. Basile
2013-03-29 23:10 Anthony G. Basile
2013-03-29 23:03 Anthony G. Basile
2011-12-29 21:24 Anthony G. Basile
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1377385371.3bbdf6579d88c0abe77519e0148dd0a7dcc7d3fe.blueness@gentoo \
--to=blueness@gentoo.org \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox