Skip to content

This role sets up my git client and its attributes, aliases and few other things.

License

Notifications You must be signed in to change notification settings

tvieira/ansible-git-client

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build Status Ansible Galaxy

git-client

This role installs git client with my preferred settings and attributes. It includes send-mail, gpg (gnupg2) and gerrit settings.

The git templates contain a pre-commit hook for all your new projects when you run git init. This pre-commit hook runs pep8, pylint and pyflakes on all *py files you commit.

See files/pre-commit for more details.

Requirements

This role assumes you have previously installed:

  • vim (my git preferred editor)
  • gnupg2 and you have created your private key

It also assumes that the user's directory to which the homedir is set to has been previously configured.

For example, my machines are configured to have my username set to tmoreira. Therefore, if I want to run this role to install git-client to my username then I will set the homedir variable to

homedir: '/home/tmoreira'

The pre-commit hook script assumes you have PEP8, PyLint and PyFlakes installed.

Role Variables

homedir: '/home/foo'                # git templates will be installed at:
                                    #     {{ homedir }} /.git_templates
git:
  user:                             # general git client user's settings
    name: 'Foo'                     # user's full name
    email: 'foo@example.com'        # user's email
    signingkey: '01234567'          # user's GPG key

  sendemail:                        # settings used by git-email
    smtpuser: 'yourname@gmail.com'  # smtp server username
    smtpserver: 'smtp.gmail.com'    # smtp server address
    smtpserverport: '587'           # smtp server port (OPTIONAL)
    smtpencryption: 'tls'           # smtp encryption (OPTIONAL)

  gitreview:                        # settings used by git-review
    username: 'foo'                 # user's gerrit username

Playbook Example

    - hosts: servers
      roles:
         - git-client

License

GPLv3

Author Information

Tiago M. Vieira - https://github.com/tvieira

About

This role sets up my git client and its attributes, aliases and few other things.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages