1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/library
Stephen Fromm 1727bd3b7a Update git module to handle branches better
This drops the branch option.  The version option is overloaded
to mean either a sha1, branch, or tag.  This also adds the option
'remote' which defaults to 'origin'.
clone() was simplified by removing the checkout operation.  That
happens later when switch_version() is called.

Added the methods get_branches(), is_remote_branch(), and
is_local_branch().  get_branches() returns an array listing all
of the branches for the git repository.  is_remote_branch() checks
whether the arguments supplied correspond to a remote branch.
Similarly, is_local_branch() checks for a local branch.

The pull() method now checks to see if it is on the desired branch.
If not, it checks out the requested branch and then does a pull.
This should keep issue #604 still fixed.

switch_version(), formerly switchver(), looks to see if it is
checking out a branch.  If a branch, it checks it out with the --track
option.  This type of checkout was in pull() before.

Updated pull, clone, and switch_version to return (rc, out, err).
2012-07-26 00:22:30 -07:00
..
apt add noninteractive to debian module per #602 2012-07-16 20:18:58 -04:00
assemble More cleanup in assemble module for module magic (tm) 2012-07-25 09:24:10 -07:00
async_status Port async_status to use the new common code. 2012-07-24 19:03:18 -04:00
async_wrapper Apply logging of arguments to modules (issue #122) 2012-05-09 15:19:20 -07:00
authorized_key Fixes ansible/ansible#522, no longer creates comment in ~/.ssh/authorized_keys, does not create directory or file if state==absent. 2012-07-02 19:16:57 +00:00
command Port command module over to new common code. Notice that this has to subclass AnsibleModule -- this should be the only 2012-07-24 18:52:52 -04:00
copy imports not needed 2012-07-21 17:25:47 -04:00
facter Standardizing the module 2012-07-24 21:08:56 +05:30
failtest Surface module debug (-D) to /usr/bin/ansible also 2012-03-31 11:45:29 -04:00
fetch Setup module no longer saves to disk, as templates are mostly useful in playbooks and this allows lots of simplifications 2012-07-14 11:59:12 -04:00
file Fix file module to support = in args; remove superflous call in get_url 2012-07-24 06:40:34 +02:00
get_url Fix file module to support = in args; remove superflous call in get_url 2012-07-24 06:40:34 +02:00
git Update git module to handle branches better 2012-07-26 00:22:30 -07:00
group Update group module to use new shared module code 2012-07-21 22:30:13 -07:00
mount Standardizing the mount module 2012-07-24 17:00:08 +05:30
mysql_db Upgrading MySQL user module to new format 2012-07-22 12:11:39 -05:00
mysql_user Upgrading MySQL user module to new format 2012-07-22 12:11:39 -05:00
ohai Apply logging of arguments to modules (issue #122) 2012-05-09 15:19:20 -07:00
ping Save the transfer of the module file for new style modules, because we can inject the arguments into the modules. 2012-07-23 19:18:45 -04:00
raw Setup module no longer saves to disk, as templates are mostly useful in playbooks and this allows lots of simplifications 2012-07-14 11:59:12 -04:00
service Service module outputting extra data. 2012-07-19 13:15:09 -04:00
setup Fixes locale problem with ifconfig in setup module 2012-07-24 11:10:11 +02:00
shell Setup module no longer saves to disk, as templates are mostly useful in playbooks and this allows lots of simplifications 2012-07-14 11:59:12 -04:00
slurp By defining a main function here, and including it ahead of the boilerplate insertion symbol, tracebacks are 2012-07-20 06:37:46 -04:00
template Setup module no longer saves to disk, as templates are mostly useful in playbooks and this allows lots of simplifications 2012-07-14 11:59:12 -04:00
user Undefined variable error 2012-07-24 09:26:45 -05:00
virt Tweaks on previous refactoring of playbook, version bump a 0.4 reference, remove some debug, etc 2012-05-26 01:20:53 -04:00
yum Further standardize the yum module 2012-07-25 20:14:15 -04:00