summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCédric Bosdonnat <cbosdonnat@suse.com>2017-07-18 17:39:55 +0200
committerCédric Bosdonnat <cbosdonnat@suse.com>2017-07-18 17:43:14 +0200
commit5a0068ff2a9460b2fb872a5722eb61d508869e9e (patch)
treea9bfed8aa03602bd9ad338b44ce5dc9d8789c1d4
parentf23d759eda69738917985feb9af727f792d1145e (diff)
downloadvirt-bootstrap.git-5a0068ff2a9460b2fb872a5722eb61d508869e9e.tar.gz
virt-bootstrap.git-5a0068ff2a9460b2fb872a5722eb61d508869e9e.tar.xz
virt-bootstrap.git-5a0068ff2a9460b2fb872a5722eb61d508869e9e.zip
Add script to run virt-bootstrap for hackers
run script takes care of setting the environment variables (only PYTHONPATH so far) needed to run virt-bootstrap without installing it. This wrapper script works in the same fashion than the ones in virt-manager or libvirt projects for consistency.
-rw-r--r--README.md9
-rwxr-xr-xrun20
2 files changed, 29 insertions, 0 deletions
diff --git a/README.md b/README.md
index 1ad1329..7451421 100644
--- a/README.md
+++ b/README.md
@@ -12,3 +12,12 @@ Dependencies
* skopeo
* virt-sandbox
* libguestfs
+
+Hacking
+-------
+
+To test changes without installing the package in your machine,
+use the run script. For example to run virt-bootstrap, use a command
+like the following one:
+
+ ./run src/virtBootstrap/virt-bootstrap.py --help
diff --git a/run b/run
new file mode 100755
index 0000000..5112034
--- /dev/null
+++ b/run
@@ -0,0 +1,20 @@
+#!/bin/sh
+# Authors: Cedric Bosdonnat <cbosdonnat@suse.com>
+#
+# Copyright (C) 2017 SUSE, Inc.
+#
+# 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 3 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, see <http://www.gnu.org/licenses/>.
+
+export PYTHONPATH=$PWD/src:$PYTHONPATH
+$@