From 65e4779c6b3c874c13a0ac5262e4ed431e68ef15 Mon Sep 17 00:00:00 2001 From: Michael Mandl Date: Fri, 13 Nov 2020 08:36:46 +0100 Subject: [PATCH] Install wsl-open --- roles/wsl-open/tasks/main.yaml | 19 +++++++++++++++++++ wsl-debian.yaml | 1 + 2 files changed, 20 insertions(+) create mode 100644 roles/wsl-open/tasks/main.yaml diff --git a/roles/wsl-open/tasks/main.yaml b/roles/wsl-open/tasks/main.yaml new file mode 100644 index 0000000..d873284 --- /dev/null +++ b/roles/wsl-open/tasks/main.yaml @@ -0,0 +1,19 @@ +--- +- name: download script + become_user: "{{ account.name }}" + get_url: + url: https://raw.githubusercontent.com/4U6U57/wsl-open/master/wsl-open.sh + dest: "{{ account.home }}/bin" + mode: "0755" + +- name: install xdg-open + package: + name: xdg-utils + state: latest + +- name: set BROWSER variable + become_user: "{{ account.name }}" + lineinfile: + path: "/home/{{ account.name }}/.zshrc" + regexp: "^export BROWSER=" + line: "export BROWSER=wsl-open.sh" diff --git a/wsl-debian.yaml b/wsl-debian.yaml index 646ed22..8e3b02d 100644 --- a/wsl-debian.yaml +++ b/wsl-debian.yaml @@ -19,5 +19,6 @@ - tools - dev-machine - pinentry-wsl + - wsl-open - dockerd-wsl - dircolors-wsl