Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
Choose a Base Repository
Nothing to show
...
Choose a Head Repository
Nothing to show
Checking mergeability… Don’t worry, you can still create the pull request.
  • 5 commits
  • 8 files changed
  • 0 commit comments
  • 1 contributor
Showing with 73 additions and 124 deletions.
  1. +5 −0 .gitignore
  2. +30 −20 HACKING.rst
  3. +2 −0 MANIFEST.in
  4. +15 −0 README.rst
  5. +0 −21 tools/make-dist-tarball
  6. +15 −30 tools/make-tarball
  7. +4 −28 tools/read-dependencies
  8. +2 −25 tools/read-version
View
@@ -0,0 +1,5 @@
+.tox
+dist
+cloud_init.egg-info
+__pycache__
+build
View
@@ -8,41 +8,51 @@ To get changes into cloud-init, the process to follow is:
- `Canonical Contributor Agreement`_
-* Get your changes into a local bzr branch.
- Initialize a repo, and checkout trunk (init repo is to share bzr info across multiple checkouts, its different than git):
+* Get your changes into a local git branch.
- - ``bzr init-repo cloud-init``
- - ``bzr branch lp:cloud-init trunk.dist``
- - ``bzr branch trunk.dist my-topic-branch``
+ - Fork the cloud-init project on `GitHub`_.
+ - Clone your forked repository::
-* Commit your changes (note, you can make multiple commits, fixes, more commits.):
+ git clone https://github.com/<YOUR_USERNAME>/cloud-init
- - ``bzr commit``
+ - Create a new topic branch for your work::
-* Check pep8 and test, and address any issues:
+ cd cloud-init
+ git checkout -b my-topic-branch
- - ``make test pep8``
+* Make and commit your changes (note, you can make multiple commits,
+ fixes, more commits.)::
-* Push to launchpad to a personal branch:
+ git commit
- - ``bzr push lp:~<YOUR_USERNAME>/cloud-init/<BRANCH_NAME>``
+* Check pep8 and test, and address any issues::
-* Propose that for a merge into lp:cloud-init via web browser.
+ make test pep8
- - Open the branch in `Launchpad`_
+* Push to your GitHub repository::
- - It will typically be at ``https://code.launchpad.net/<YOUR_USERNAME>/<PROJECT>/<BRANCH_NAME>``
- - ie. https://code.launchpad.net/~smoser/cloud-init/mybranch
+ git push -u origin my-topic-branch
-* Click 'Propose for merging'
-* Select 'lp:cloud-init' as the target branch
+* Use your browser to create a pull request on GitHub.
-Then, someone on cloud-init-dev (currently `Scott Moser`_ and `Joshua Harlow`_) will
-review your changes and follow up in the merge request.
+ - Open the branch on `GitHub`_
-Feel free to ping and/or join #cloud-init on freenode (irc) if you have any questions.
+ - It will typically be at
+ ``https://github.com/<YOUR_USERNAME>/cloud-init/tree/<BRANCH_NAME>``,
+ for example
+ <https://github.com/smoser/cloud-init/my-topic-branch>.
+
+* Click 'New pull request'
+* Select ``cloud-init/cloud-init``, branch ``master`` as the base branch
+
+Then, someone on cloud-init-dev (currently `Scott Moser`_ and `Joshua
+Harlow`_) will review your changes and follow up in the merge request.
+
+Feel free to ping and/or join ``#cloud-init`` on freenode (irc) if you
+have any questions.
.. _Launchpad: https://launchpad.net
+.. _GitHub: https://github.com/
.. _Canonical Contributor Agreement: http://www.canonical.com/contributors
.. _Scott Moser: https://launchpad.net/~smoser
.. _Joshua Harlow: https://launchpad.net/~harlowja
View
@@ -4,5 +4,7 @@ graft tools
prune build
prune dist
prune .tox
+prune .git
+prune .gitignore
prune .bzr
exclude .bzrignore
View
@@ -0,0 +1,15 @@
+Cloud-init
+==========
+
+Cloud-init is the defacto multi-distribution package that handles
+early initialization of a cloud instance.
+
+The package is hosted at <https://github.com/cloud-init/cloud-init/>.
+
+Additional documentation can be found in the `doc/` subdirectory.
+
+Contributing
+------------
+
+For information about how to contribute to cloud-init development, see
+the file ``HACKING.rst`` included in this distribution.
View
@@ -1,21 +0,0 @@
-#!/bin/sh
-
-Usage() {
- cat <<EOF
-Usage: ${0##*/} version
- make a tarball of 'version'
- must be in a bzr directory, and 'version' must be a tag
-
-EOF
-}
-
-topdir="$PWD"
-tag="$1"
-
-[ -n "$tag" ] || { Usage 1>&2 ; exit 1; }
-
-out="${topdir}/cloud-init-${tag}.tar.gz"
-
-bzr export --format=tgz --root="cloud-init-$tag" \
- "--revision=tag:${tag}" "$out" "$topdir" &&
- echo "Wrote ${out}"
View
@@ -1,39 +1,24 @@
#!/bin/sh
set -e
-find_root() {
- local topd
- if [ -z "${CLOUD_INIT_TOP_D}" ]; then
- topd=$(cd "$(dirname "${0}")" && cd .. && pwd)
- else
- topd=$(cd "${CLOUD_INIT_TOP_D}" && pwd)
- fi
- [ $? -eq 0 -a -f "${topd}/setup.py" ] || return
- ROOT_DIR="$topd"
-}
-
-if ! find_root; then
- echo "Unable to locate 'setup.py' file that should" \
- "exist in the cloud-init root directory." 1>&2
- exit 1;
-fi
-
-REVNO=$(bzr revno "$ROOT_DIR")
-
-if [ ! -z "$1" ]; then
- ARCHIVE_FN="$1"
+rev=${1:-HEAD}
+if [ "$rev" = HEAD ]; then
+ revname=$(git describe --tags)
else
- VERSION=$("$ROOT_DIR/tools/read-version")
- ARCHIVE_FN="$PWD/cloud-init-$VERSION~bzr$REVNO.tar.gz"
+ revname="$rev"
fi
-export_uncommitted=""
-if [ "${UNCOMMITTED:-0}" != "0" ]; then
- export_uncommitted="--uncommitted"
+archive_prefix="cloud-init-$revname"
+archive_name="$archive_prefix.tar.gz"
+
+if [ "$rev" = HEAD ] && ! git diff-index --quiet HEAD --; then
+ echo "ERROR: There are uncommitted changes." >&2
+ exit 1
fi
-bzr export ${export_uncommitted} \
- --format=tgz --root="cloud-init-$VERSION~bzr$REVNO" \
- "--revision=${REVNO}" "${ARCHIVE_FN}" "$ROOT_DIR"
+git archive \
+ --format=tar \
+ --prefix "$archive_prefix/" $rev |
+ gzip > $archive_name
-echo "$ARCHIVE_FN"
+echo $archive_name
View
@@ -1,29 +1,5 @@
-#!/usr/bin/env python
+#!/bin/sh
-import os
-import re
-import sys
-
-if 'CLOUD_INIT_TOP_D' in os.environ:
- topd = os.path.realpath(os.environ.get('CLOUD_INIT_TOP_D'))
-else:
- topd = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
-
-for fname in ("setup.py", "requirements.txt"):
- if not os.path.isfile(os.path.join(topd, fname)):
- sys.stderr.write("Unable to locate '%s' file that should "
- "exist in cloud-init root directory." % fname)
- sys.exit(1)
-
-if len(sys.argv) > 1:
- reqfile = sys.argv[1]
-else:
- reqfile = "requirements.txt"
-
-with open(os.path.join(topd, reqfile), "r") as fp:
- for line in fp:
- if not line.strip() or line.startswith("#"):
- continue
- sys.stdout.write(re.split("[>=.<]*", line)[0].strip() + "\n")
-
-sys.exit(0)
+cd $(git rev-parse --show-toplevel)
+egrep -v '^$|^#' requirements.txt |
+ sed 's/;.*//'
View
@@ -1,26 +1,3 @@
-#!/usr/bin/env python
+#!/bin/sh
-import os
-import re
-import sys
-
-if 'CLOUD_INIT_TOP_D' in os.environ:
- topd = os.path.realpath(os.environ.get('CLOUD_INIT_TOP_D'))
-else:
- topd = os.path.dirname(os.path.dirname(os.path.realpath(__file__)))
-
-for fname in ("setup.py", "ChangeLog"):
- if not os.path.isfile(os.path.join(topd, fname)):
- sys.stderr.write("Unable to locate '%s' file that should "
- "exist in cloud-init root directory." % fname)
- sys.exit(1)
-
-vermatch = re.compile(r"^[0-9]+[.][0-9]+[.][0-9]+:$")
-
-with open(os.path.join(topd, "ChangeLog"), "r") as fp:
- for line in fp:
- if vermatch.match(line):
- sys.stdout.write(line.strip()[:-1] + "\n")
- break
-
-sys.exit(0)
+git describe --tags

No commit comments for this range