henriklynggaard.pycharm

Pycharm (https://www.jetbrains.com/pycharm)

This role installs Pycharm and sets up plugins. It has been tested on Linux Mint 18 but should work on most distributions. By default, it installs the Pycharm Community Edition version 2017.1.5, without any extra plugins.

Pycharm is installed in the user's home directory, and you do not need special privileges (become).

Requirements

None

Role Variables

  • pycharm_version: 2017.1.5

  • pycharm_edition: community

  • pycharm_download_mirror: https://download.jetbrains.com/python/

  • pycharm_plugin_download_mirror: "https://plugins.jetbrains.com/plugin/download?updateId="

  • pycharm_plugins: []

  • pycharm_download_directory: /tmp

  • pycharm_user_dir: "~{{ (pycharm_install_user is defined) | ternary(pycharm_install_user, ansible_user_id) }}"

  • pycharm_install_directory: "{{ pycharm_user_dir | expanduser }}/Tools"

  • pycharm_install_user:

  • pycharm_install_file: "pycharm-{{ pycharm_edition}}-{{ pycharm_version }}.tar.gz"

  • pycharm_download_url: "{{ pycharm_download_mirror }}{{ pycharm_install_file }}"

  • pycharm_desktop_file_directory: "{{ ansible_env['HOME'] }}/.local/share/applications"

  • pycharm_desktop_file_location: "{{ pycharm_user_dir | expanduser }}/.local/share/applications/pycharm-{{ pycharm_edition }}-{{ pycharm_version }}.desktop"

  • The pycharm_plugins list contains plugin IDs that will be used to download plugins.
  • If you set pycharm_install_user, the installation can be done for a different user, but you will need special privileges (become).

Dependencies

None

Example

Example playbook

- hosts: localhost
  connection: local

roles:
  - henriklyngaard.pycharm

Example inventory for plugins

The plugin IDs can be found on https://plugins.jetbrains.com/pycharm by searching for the plugin. Copy the link for the desired version and use the updateId=XXXXX part at the end.

pycharm_plugins:
  # ignore version 1.7.6
  - 32828
  # bash support version 1.6.5.171
  - 31610
  # ansible version 0.9.4
  - 27616
  # docker version 2.5.3
  - 33621
  # markdown version 2017.1.20170302
  - 33092  

Alternatively, you can upload the required plugins to a web server and change pycharm_plugin_download_mirror and pycharm_plugins accordingly.

License

MIT

Change log

  • 1.4: Allowed installation under another user
  • 1.3: Upgraded to Pycharm 2017.1.5
  • 1.2: Added molecule tests
  • 1.1: Created the desktop file directory if it didn't exist
  • 1.0: Initial version
Informazioni sul progetto

Installs PyCharm and plugins

Installa
ansible-galaxy install henriklynggaard.pycharm
Licenza
mit
Download
542