Skip to content

Commit

Permalink
Merge pull request #67 from jacebrowning/release/v0.5
Browse files Browse the repository at this point in the history
Release v0.5
  • Loading branch information
jacebrowning committed Oct 20, 2015
2 parents c8db075 + 7bc5eda commit 03f4f30
Show file tree
Hide file tree
Showing 31 changed files with 772 additions and 85 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ env

# Generated documentation
docs/gen
apidocs
/apidocs
/site
/*.html
*.rst
docs/*.png
Expand Down
5 changes: 5 additions & 0 deletions .pep257
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[pep257]

# D10*: docstring missing (checked by PyLint)
# D202: No blank lines allowed *after* function docstring (personal preference)
add-ignore = D102,D103,D105,D202
30 changes: 24 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,22 +1,22 @@
sudo: required
sudo: false

language: python
python:
- 3.3
- 3.4
- 3.5

cache: pip
cache:
pip: true
directories:
- env

before_install:
- sudo add-apt-repository ppa:git-core/ppa -y
- sudo apt-get update
env:
global:
- RANDOM_SEED=12345
- secure: "UnyHAJ/T6eI/6vaXXKsZgs2XqBib06DubRqMVegy1nMNBjFsmyZ3tU+22gW2NWAGzukwC3GXWsxkN+7sTlTcTldFBvN9onzC1oVDfQrcAUjvSOK02OZ4tepVq5umsDUxGpRqhWB7LgEv0zM6DHzj6k+yaPBtcJg6NFhpScQfHyY="

install:
- sudo apt-get install git; git --version
- pip install coveralls scrutinizer-ocular

before_script:
Expand All @@ -30,6 +30,24 @@ after_success:
- coveralls
- ocular

after_script: >
echo $TRAVIS_BRANCH; echo $TRAVIS_PULL_REQUEST;
if [[ $TRAVIS_BRANCH == 'develop' && $TRAVIS_PULL_REQUEST == 'false' ]]; then
# Generate site
make mkdocs ;
# Configure Git with Travis CI information
git config --global user.email "travis@travis-ci.org" ;
git config --global user.name "travis-ci" ;
# Delete the current repository
rm -rf .git ;
# Rebuild the repository from the generated files and push to GitHub pages
cd site ;
git init ;
git add . ;
git commit -m "Deploy Travis CI build $TRAVIS_BUILD_NUMBER to GitHub pages" ;
git push -f https://${GH_TOKEN}@github.com/${TRAVIS_REPO_SLUG} master:gh-pages ;
fi
notifications:
email:
on_success: never
Expand Down
11 changes: 11 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
Revision History
================

0.5 (2015/10/20)
----------------

- Added Git plugin support via: `git deps`.
- Removed '--no-clean' option (now the default) on 'install' and 'update'.
- Added '--clean' option to delete ignored files on 'install' and 'update'.
- Switched to 'install' rather than 'update' of nested dependencies.
- Added '--all' option on 'update' to update all nested dependencies.
- Disabled warnings when running 'install' without locked sources.
- Added '--no-lock' option to disable version recording.

0.4.2 (2015/10/18)
------------------

Expand Down
6 changes: 4 additions & 2 deletions LICENSE.txt → LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
The MIT License (MIT)
# License

Copyright (c) 2015 Jace Browning <jacebrowning@gmail.com>
**The MIT License (MIT)**

Copyright &copy; 2015, Jace Browning

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
40 changes: 26 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ NOSE := $(BIN)/nosetests
PYTEST := $(BIN)/py.test
COVERAGE := $(BIN)/coverage
SNIFFER := $(BIN)/sniffer
MKDOCS := $(BIN)/mkdocs

# Flags for PHONY targets
DEPENDS_CI_FLAG := $(ENV)/.depends-ci
Expand All @@ -77,10 +78,10 @@ ALL_FLAG := $(ENV)/.all
all: depends doc $(ALL_FLAG)
$(ALL_FLAG): $(SOURCES)
$(MAKE) check
touch $(ALL_FLAG) # flag to indicate all setup steps were successful
@ touch $(ALL_FLAG) # flag to indicate all setup steps were successful

.PHONY: ci
ci: check test tests
ci: mkdocs check test tests

.PHONY: watch
watch: depends-dev .clean-test
Expand All @@ -107,7 +108,7 @@ depends: depends-ci depends-dev
.PHONY: depends-ci
depends-ci: env Makefile $(DEPENDS_CI_FLAG)
$(DEPENDS_CI_FLAG): Makefile
$(PIP) install --upgrade pep8 pep257==0.6 pylint coverage pytest pytest-cov pytest-random pytest-runfailed
$(PIP) install --upgrade pep8 pep257 pylint coverage pytest pytest-cov pytest-random pytest-runfailed mkdocs
@ touch $(DEPENDS_CI_FLAG) # flag to indicate dependencies are installed

.PHONY: depends-dev
Expand All @@ -125,8 +126,10 @@ endif

# Documentation ################################################################

URL := "git-dependency-manager.info"

.PHONY: doc
doc: readme verify-readme apidocs uml
doc: readme verify-readme uml apidocs mkdocs

.PHONY: readme
readme: depends-dev README-github.html README-pypi.html
Expand All @@ -143,20 +146,32 @@ $(DOCS_FLAG): README.rst
$(PYTHON) setup.py check --restructuredtext --strict --metadata
@ touch $(DOCS_FLAG) # flag to indicate README has been checked

.PHONY: apidocs
apidocs: depends-dev apidocs/$(PACKAGE)/index.html
apidocs/$(PACKAGE)/index.html: $(SOURCES)
$(PDOC) --html --overwrite $(PACKAGE) --html-dir apidocs

.PHONY: uml
uml: depends-dev docs/*.png
docs/*.png: $(SOURCES)
$(PYREVERSE) $(PACKAGE) -p $(PACKAGE) -a 1 -f ALL -o png --ignore test
- mv -f classes_$(PACKAGE).png docs/classes.png
- mv -f packages_$(PACKAGE).png docs/packages.png

.PHONY: apidocs
apidocs: depends-dev apidocs/$(PACKAGE)/index.html
apidocs/$(PACKAGE)/index.html: $(SOURCES)
$(PDOC) --html --overwrite $(PACKAGE) --html-dir apidocs

.PHONY: mkdocs
mkdocs: depends-ci site/index.html
site/index.html: mkdocs.yml docs/*.md
$(MKDOCS) build --clean --strict
echo $(URL) > site/CNAME

.PHONY: mkdocs-live
mkdocs-live: mkdocs
eval "sleep 3; open http://127.0.0.1:8000" &
$(MKDOCS) serve

.PHONY: read
read: doc
$(OPEN) site/index.html
$(OPEN) apidocs/$(PACKAGE)/index.html
$(OPEN) README-pypi.html
$(OPEN) README-github.html
Expand All @@ -172,10 +187,7 @@ pep8: depends-ci

.PHONY: pep257
pep257: depends-ci
# D102/D103: docstring missing (checked by PyLint)
# D202: No blank lines allowed *after* function docstring (personal preference)
# D203: 1 blank line required before class (deprecated warning)
$(PEP257) $(PACKAGE) tests --ignore=D102,D103,D202,D203
$(PEP257) $(PACKAGE) tests

.PHONY: pylint
pylint: depends-ci
Expand Down Expand Up @@ -258,7 +270,7 @@ clean-all: clean clean-env .clean-workspace

.PHONY: .clean-doc
.clean-doc:
rm -rf README.rst apidocs *.html docs/*.png
rm -rf README.rst apidocs *.html docs/*.png site

.PHONY: .clean-test
.clean-test:
Expand Down
25 changes: 16 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](http://img.shields.io/travis/jacebrowning/gdm/master.svg)](https://travis-ci.org/jacebrowning/gdm)
[![Build Status](https://travis-ci.org/jacebrowning/gdm.svg?branch=develop)](https://travis-ci.org/jacebrowning/gdm)
[![Coverage Status](http://img.shields.io/coveralls/jacebrowning/gdm/master.svg)](https://coveralls.io/r/jacebrowning/gdm)
[![Scrutinizer Code Quality](http://img.shields.io/scrutinizer/g/jacebrowning/gdm.svg)](https://scrutinizer-ci.com/g/jacebrowning/gdm/?branch=master)
[![PyPI Version](http://img.shields.io/pypi/v/GDM.svg)](https://pypi.python.org/pypi/GDM)
Expand All @@ -7,6 +7,8 @@
Getting Started
===============

Git Dependency Manager (GDM) is a language-agnostic "dependency manager" using Git. It aims to serve as a submodules replacement and provides advanced options for managing versions of nested Git repositories.

Requirements
------------

Expand All @@ -19,13 +21,13 @@ Installation

GDM can be installed with pip:

```
```sh
$ pip3 install gdm
```

or directly from the source code:

```
```sh
$ git clone https://github.com/jacebrowning/gdm.git
$ cd gdm
$ python3 setup.py install
Expand All @@ -50,7 +52,7 @@ sources:
Ignore GDM's dependency storage location:
```
```sh
$ echo .gdm >> .gitignore
```

Expand All @@ -59,7 +61,7 @@ Basic Usage

See the available commands:

```
```sh
$ gdm --help
```

Expand All @@ -68,7 +70,7 @@ Updating Dependencies

Get the latest versions of all dependencies:

```
```sh
$ gdm update
```

Expand All @@ -92,13 +94,13 @@ Restoring Previous Versions

Display the specific revisions that are currently installed:

```
```sh
$ gdm list
```

Reinstall these specific versions at a later time:

```
```sh
$ gdm install
```

Expand All @@ -107,6 +109,11 @@ Deleting Dependencies

Remove all installed dependencies:

```
```sh
$ gdm uninstall
```

Advanced Options
================

See the full documentation at http://git-dependency-manager.info/.
2 changes: 1 addition & 1 deletion docs/.gitignore
Original file line number Diff line number Diff line change
@@ -1 +1 @@
# remove this placeholder after adding files
*.png
File renamed without changes.
1 change: 1 addition & 0 deletions docs/about/changes.md
1 change: 1 addition & 0 deletions docs/about/contributing.md
1 change: 1 addition & 0 deletions docs/about/license.md
76 changes: 76 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Git Dependency Manager

Git Dependency Manager (GDM) is a language-agnostic "dependency manager" using Git. It aims to serve as a submodules replacement and provides advanced options for managing versions of nested Git repositories.

[![Build Status](https://travis-ci.org/jacebrowning/gdm.svg?branch=develop)](https://travis-ci.org/jacebrowning/gdm)
[![Coverage Status](http://img.shields.io/coveralls/jacebrowning/gdm/master.svg)](https://coveralls.io/r/jacebrowning/gdm)
[![Scrutinizer Code Quality](http://img.shields.io/scrutinizer/g/jacebrowning/gdm.svg)](https://scrutinizer-ci.com/g/jacebrowning/gdm/?branch=master)
[![PyPI Version](http://img.shields.io/pypi/v/GDM.svg)](https://pypi.python.org/pypi/GDM)
[![PyPI Downloads](http://img.shields.io/pypi/dm/GDM.svg)](https://pypi.python.org/pypi/GDM)

## Requirements

* Python 3.3+
* Latest version of Git (with [stored credentials](http://stackoverflow.com/questions/7773181))
* OSX/Linux (with a decent shell for Git)

## Installation

GDM can be installed with pip:

```sh
$ pip3 install gdm
```

or directly from the source code:

```sh
$ git clone https://github.com/jacebrowning/gdm.git
$ cd gdm
$ python3 setup.py install
```

## Setup

Create a GDM configuration file (`gdm.yml` or `.gdm.yml`) in the root of your working tree:

```yaml
location: .gdm
sources:
- repo: https://github.com/kstenerud/iOS-Universal-Framework
dir: framework
rev: Mk5-end-of-life
- repo: https://github.com/jonreid/XcodeCoverage
dir: coverage
rev: master
link: Tools/XcodeCoverage
```
Ignore GDM's dependency storage location:
```sh
$ echo .gdm >> .gitignore
```

Basic Usage
-----------

Get all dependencies:

```sh
$ gdm install
```

which will essentially:

1. create a working tree at _root_/`location`/`dir`
2. fetch from `repo` and checkout the specified `rev`
3. symbolically link each `location`/`dir` from _root_/`link` (if specified)
4. repeat for all nested working trees containing a configuration file

where `rev` can be:

* all or part of a commit SHA: `123def`
* a tag: `v1.0`
* a branch: `master`
* a `rev-parse` date: `'develop@{2015-06-18 10:30:59}'`
Loading

0 comments on commit 03f4f30

Please sign in to comment.