gem module supports prerelease (--pre)
This commit is contained in:
parent
78e5f6129f
commit
e1a1ac1e76
1 changed files with 9 additions and 0 deletions
|
@ -67,6 +67,12 @@ options:
|
||||||
description:
|
description:
|
||||||
- Version of the gem to be installed/removed.
|
- Version of the gem to be installed/removed.
|
||||||
required: false
|
required: false
|
||||||
|
prerelease:
|
||||||
|
description:
|
||||||
|
- Allow installation of prerelease versions of the gem.
|
||||||
|
required: false
|
||||||
|
default: "no"
|
||||||
|
version_added: "1.6"
|
||||||
author: Johan Wiren
|
author: Johan Wiren
|
||||||
'''
|
'''
|
||||||
|
|
||||||
|
@ -174,6 +180,8 @@ def install(module):
|
||||||
cmd.append('--user-install')
|
cmd.append('--user-install')
|
||||||
else:
|
else:
|
||||||
cmd.append('--no-user-install')
|
cmd.append('--no-user-install')
|
||||||
|
if module.params['prerelease']:
|
||||||
|
cmd.append('--pre')
|
||||||
cmd.append('--no-rdoc')
|
cmd.append('--no-rdoc')
|
||||||
cmd.append('--no-ri')
|
cmd.append('--no-ri')
|
||||||
cmd.append(module.params['gem_source'])
|
cmd.append(module.params['gem_source'])
|
||||||
|
@ -190,6 +198,7 @@ def main():
|
||||||
repository = dict(required=False, aliases=['source'], type='str'),
|
repository = dict(required=False, aliases=['source'], type='str'),
|
||||||
state = dict(required=False, default='present', choices=['present','absent','latest'], type='str'),
|
state = dict(required=False, default='present', choices=['present','absent','latest'], type='str'),
|
||||||
user_install = dict(required=False, default=True, type='bool'),
|
user_install = dict(required=False, default=True, type='bool'),
|
||||||
|
prerelease = dict(required=False, default=False, type='bool'),
|
||||||
version = dict(required=False, type='str'),
|
version = dict(required=False, type='str'),
|
||||||
),
|
),
|
||||||
supports_check_mode = True,
|
supports_check_mode = True,
|
||||||
|
|
Loading…
Reference in a new issue