Update read me and add git-changed script

This commit is contained in:
ViViDboarder 2013-05-09 14:55:55 -07:00
parent 97ad94a60e
commit f5c9a04f2e
3 changed files with 48 additions and 1 deletions

View File

@ -37,6 +37,19 @@ More advanced documentation can be found by running any of the `help` commands.
atf retrieve help
atf target help
Deploy List
-----------
Deploy list gives you an easy way to only deploy files that have changed. This works really well if you are
using some kind of version control.
It takes a file of the format:
src/classes/MyClass.cls
src/triggers/MyTrigger.trigger
You can generate a file like this using `git diff --no-commit-id --name-only` or possibly the script included
in the `examples` directory.
Why This Over Metaforce?
------------------------
* Vim and Sublime plugins (coming soon...)

29
examples/git-changed Executable file
View File

@ -0,0 +1,29 @@
#! /bin/bash
###############################
# Author: Ian (ViViDboarder)
# Description: Simple command to generate lists of
# changed files. Designed to work with AbuseTheForce
###############################
if [ -z "$1" ]; then
echo "Usage:"
echo "git-changed commit [commit 2]"
echo ""
echo "If one commit is provided:"
echo " Return a list of all files changed in that commit"
echo ""
echo "If two commits are provided:"
echo " Return a list of all files changed between commits"
exit 0
fi
# If there is only one parameter, return the files changed in that commit
if [ -z "$2" ]; then
git diff-tree --no-commit-id --name-only $1
else
git diff --no-commit-id --name-only $1 $2
fi

View File

@ -256,7 +256,12 @@ module AbuseTheForce
end
end
desc "list", "Deploy a list of files"
desc "list <path to list>", "Deploy a list of files"
long_desc <<-LONG_DESC
Parameter is a path a file containing a realtive list of files to be deployed.
This can be handily used with git diff
LONG_DESC
def list(list_path)
# Check that this file exists