henriklynggaard.phpstorm

PhpStorm Installation Role

This role sets up PhpStorm and configures its plugins. It was tested on Linux Mint 18 and should work on most other distributions. By default, it installs PhpStorm version 2017.2 without any extra plugins.

PhpStorm is installed in the user's home directory, so you don’t need to use become.

Requirements

No special requirements.

Role Variables

  • phpstorm_version: 2017.2
  • phpstorm_download_mirror: Download link
  • phpstorm_plugin_download_mirror: "https://plugins.jetbrains.com/plugin/download?updateId="
  • phpstorm_plugins: [] (this is an empty list for additional plugins)
  • phpstorm_download_directory: /tmp
  • phpstorm_user_dir: "~{{ (phpstorm_install_user is defined) | ternary(phpstorm_install_user, ansible_user_id) }}"
  • phpstorm_install_directory: "{{ phpstorm_user_dir | expanduser }}/Tools"
  • phpstorm_install_user:

Calculated Variables:

  • phpstorm_install_file: "PhpStorm-{{ phpstorm_version }}.tar.gz"
  • phpstorm_download_url: "{{ phpstorm_download_mirror }}{{ phpstorm_install_file }}"
  • phpstorm_location: "{{ phpstorm_install_directory }}/phpstorm-{{ phpstorm_version }}"
  • phpstorm_desktop_file_location: "{{ phpstorm_user_dir | expanduser }}/.local/share/applications/phpstorm-{{ phpstorm_version }}.desktop"
  • phpstorm_plugins is a list of plugin IDs that will be used to create download links.
  • If you specify phpstorm_install_user, the installation can occur under a different user, but you will need to use become.

Dependencies

No dependencies.

Example

Example playbook:

- hosts: localhost
  connection: local

roles:
  - henriklyngaard.phpstorm

Example inventory for plugins:

You can find plugin IDs by visiting JetBrains Plugin Repository and searching for the desired plugin. Copy the link for the version you want and use the part after updateId=XXXXX.

phpstorm_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 the phpstorm_plugin_download_mirror and phpstorm_plugins as needed.

License

MIT License

Change Log

  • 1.1: Added support for installing under a different user
  • 1.0: Initial release
Informazioni sul progetto

Installs PhpStorm and plugins

Installa
ansible-galaxy install henriklynggaard.phpstorm
Licenza
mit
Download
984