VS Code/ Languages: make it more universial
This commit is contained in:
parent
063a927e01
commit
388f15988a
6 changed files with 22 additions and 11 deletions
|
@ -28,7 +28,7 @@
|
|||
vars:
|
||||
packages:
|
||||
- clang-format
|
||||
when: user_vscode == true and user_vscode_cpp == true
|
||||
when: user_lang_cpp == true
|
||||
|
||||
|
||||
# VS Code - Python Development Tools
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
vars:
|
||||
packages:
|
||||
- clang-format
|
||||
when: user_vscode == true and user_vscode_cpp == true
|
||||
when: user_lang_cpp == true
|
||||
|
||||
|
||||
# VS Code - Python Development Tools
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
vars:
|
||||
packages:
|
||||
- clang-format
|
||||
when: user_vscode == true and user_vscode_cpp == true
|
||||
when: user_lang_cpp == true
|
||||
|
||||
|
||||
# VS Code - Python Development Tools
|
||||
|
|
|
@ -1,5 +1,15 @@
|
|||
---
|
||||
# Common/VSCode: Install and Configure VS Code
|
||||
# - Installs VS Code, if user_vscode is set
|
||||
# - Installs development tools, if the corresponding variable is set
|
||||
# but will not try to configure VS Code, if user_vscode is not set.
|
||||
# - Also configures VS Code, of user_vscode is set
|
||||
|
||||
# Variables:
|
||||
# - user_vscode: Boolean, if vscode should be installed and configured
|
||||
# - user_lang_cpp: Boolean for C and C++
|
||||
# - user_lang_python: Boolean for Python
|
||||
|
||||
|
||||
- name: vscode - Install and configure VS Code
|
||||
include_tasks: "{{ item }}"
|
||||
|
@ -30,20 +40,21 @@
|
|||
shell: |
|
||||
PATH=/usr/local/bin:$PATH
|
||||
code --install-extension ms-vscode.cpptools
|
||||
when: user_vscode == true and user_vscode_cpp == true
|
||||
when: user_vscode == true and user_lang_cpp == true
|
||||
|
||||
|
||||
# VS Code - Python Development Tools
|
||||
- name: vscode - Python
|
||||
block:
|
||||
- name: vscode - Python - Install python dev packages
|
||||
pip:
|
||||
name:
|
||||
- autopep8
|
||||
- pylint
|
||||
executable: /usr/local/bin/pip3
|
||||
when: user_lang_python == true
|
||||
- name: vscode - Python
|
||||
block:
|
||||
- name: vscode - Python - Configure VS Code
|
||||
shell: |
|
||||
PATH=/usr/local/bin:$PATH
|
||||
code --install-extension ms-python.python
|
||||
when: user_vscode == true and user_vscode_python == true
|
||||
when: user_vscode == true and user_lang_python == true
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue