Skip to content
Ansible role for installing Visual Studio Code extensions
Branch: master
Clone or download
Pull request Compare This branch is 28 commits ahead, 41 commits behind gantsign:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
defaults
handlers
meta
tasks
tests
vars
.editorconfig
.gitattributes
.gitignore
.travis.yml
LICENSE
README.md
molecule.yml
pytestdebug.log

README.md

Ansible Role: Visual Studio Code Extensions

Build Status Ansible Galaxy License

Role to install extensions for the Visual Studio Code IDE / text editor.

Requirements

  • Ansible >= 2.0

  • OS

    • Linux

      • Debian Family

        • Ubuntu

          • Xenial (16.04)
      • SUSE Family

        • OpenSUSE

          • 42.2
      • Note: other versions are likely to work but have not been tested.

    • MacOSX

      • Consider MacOSX support experimental as this time as it's not included in the automated tests.

Role Variables

The following variables will change the behavior of this role (default values are shown below):

# The name of the group for user files and folders (leave as null to use default
# value). Defaults to `users` on SUSE, `admin` on MacOSX and the username on all
# other OSs / distributions.
visual_studio_code_extensions_user_group_name: null

# Users to install extensions for
users: []

# List of extensions to be uninstalled for a particular user
# Defaults to empty list
# value can be specified as shown below
# visual_studio_code_extensions_absent: 
#   - ms-vscode.csharp
visual_studio_code_extensions_absent: []

Users are configured as follows:

users:
  - username: # Unix user name
    visual_studio_code_extensions:
      - # extension 1
      - # extension 2

Example Playbook

- hosts: servers
  roles:
    - role: gantsign.visual-studio-code-extensions
      users:
        - username: vagrant
          visual_studio_code_extensions:
            - streetsidesoftware.code-spell-checker
            - wholroyd.jinja
            - donjayamanne.python
          visual_studio_code_extensions_absent:
            - streetsidesoftware.code-spell-checker

More Roles From GantSign

You can find more roles from GantSign on Ansible Galaxy.

Development & Testing

This project uses Molecule to aid in the development and testing; the role is unit tested using Testinfra and pytest.

To develop or test you'll need to have installed the following:

To run the role (i.e. the tests/test.yml playbook), and test the results (tests/test_role.py), execute the following command from the project root (i.e. the directory with molecule.yml in it):

molecule test

License

MIT

Author Information

John Freeman

GantSign Ltd. Company No. 06109112 (registered in England)

You can’t perform that action at this time.