refactored alacritty
This commit is contained in:
@@ -16,7 +16,7 @@ log_args="$log_file $log_format $log_level $log_rotate"
|
|||||||
command_args="server $config_args $log_args -non-interactive"
|
command_args="server $config_args $log_args -non-interactive"
|
||||||
|
|
||||||
depend() {
|
depend() {
|
||||||
need net
|
need networking
|
||||||
}
|
}
|
||||||
|
|
||||||
start_pre() {
|
start_pre() {
|
||||||
@@ -25,35 +25,4 @@ start_pre() {
|
|||||||
--mode 0755 \
|
--mode 0755 \
|
||||||
/var/log/$RC_SVCNAME
|
/var/log/$RC_SVCNAME
|
||||||
}
|
}
|
||||||
#
|
|
||||||
# start() {
|
|
||||||
# ebegin "Starting $RC_SVCNAME"
|
|
||||||
# start-stop-daemon --start \
|
|
||||||
# --exec $command \
|
|
||||||
# --capabilities $capabilities \
|
|
||||||
# --make-pidfile \
|
|
||||||
# --pidfile /var/run/$RC_SVCNAME.pid \
|
|
||||||
# --user $command_user:$command_group \
|
|
||||||
#
|
|
||||||
# -- \
|
|
||||||
# $command_args
|
|
||||||
#
|
|
||||||
# eend $?
|
|
||||||
# }
|
|
||||||
#
|
|
||||||
# stop() {
|
|
||||||
# ebegin "Stopping $RC_SVCNAME"
|
|
||||||
# start-stop-daemon --stop \
|
|
||||||
# --exec $command \
|
|
||||||
# --pidfile /var/run/$RC_SVCNAME.pid
|
|
||||||
#
|
|
||||||
# eend $?
|
|
||||||
# }
|
|
||||||
#
|
|
||||||
# restart() {
|
|
||||||
# ebegin "Restarting $RC_SVCNAME"
|
|
||||||
# stop()
|
|
||||||
# start()
|
|
||||||
# eend $?
|
|
||||||
# }
|
|
||||||
# vim: set filetype=sh :
|
# vim: set filetype=sh :
|
||||||
|
|||||||
@@ -5,5 +5,5 @@
|
|||||||
community.general.cargo:
|
community.general.cargo:
|
||||||
name: "{{ pkg.name | default(pkg) }}"
|
name: "{{ pkg.name | default(pkg) }}"
|
||||||
version: "{{ pkg.vers | default(omit) }}"
|
version: "{{ pkg.vers | default(omit) }}"
|
||||||
path: "{{ paths.cargo | default(omit) }}"
|
path: "{{ path.cargo | default(path.prefix)}}"
|
||||||
locked: "{{ pkg.locked | default(omit) }}"
|
locked: "{{ pkg.locked | default(omit) }}"
|
||||||
|
|||||||
@@ -1,10 +1,18 @@
|
|||||||
# vim: set filetype=yaml.ansible :
|
# vim: set filetype=yaml.ansible :
|
||||||
---
|
---
|
||||||
- name: Set alacritty configuration
|
- name: Set alacritty install method
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
alacritty:
|
alacritty:
|
||||||
deps: "{{ pkgconfig.alacritty.build_deps[ansible_os_family] }}"
|
method: "{{ pkgconfig.alacritty.method[ansible_os_family] | default(pkgconfig.alacritty.method.default) }}"
|
||||||
vers: "{{ pkgconfig.alacritty.version }}"
|
|
||||||
cask: "{{ pkgconfig.alacritty.cask | default(omit) }}"
|
- name: Set alacritty configuration
|
||||||
locked: true
|
when:
|
||||||
name: alacritty
|
- alacritty.method == 'cargo'
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
alacritty:
|
||||||
|
method: "{{ alacritty.method }}"
|
||||||
|
build_deps: "{{ pkgconfig.alacritty.build_deps[ansible_os_family] }}"
|
||||||
|
cargo:
|
||||||
|
vers: "{{ pkgconfig.alacritty.version }}"
|
||||||
|
locked: true
|
||||||
|
name: alacritty
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# vim: set filetype=yaml.ansible :
|
# vim: set filetype=yaml.ansible :
|
||||||
---
|
---
|
||||||
- name: Add alacritty
|
- name: Append alacritty
|
||||||
when:
|
when:
|
||||||
- alacritty_configured is undefined
|
- alacritty_configured is undefined
|
||||||
block:
|
block:
|
||||||
@@ -8,26 +8,21 @@
|
|||||||
ansible.builtin.include_tasks:
|
ansible.builtin.include_tasks:
|
||||||
file: config/alacritty.yml
|
file: config/alacritty.yml
|
||||||
|
|
||||||
- name: Linux based installation
|
- name: Append alacritty to pkg_cargo
|
||||||
when:
|
when:
|
||||||
- ansible_system == 'Linux'
|
- alacritty.method == 'cargo'
|
||||||
block:
|
notify:
|
||||||
- name: Append alacritty build_deps to pkg_sys
|
- Depend cargo
|
||||||
ansible.builtin.set_fact:
|
changed_when: true
|
||||||
pkg_sys: "{{ pkg_sys + alacritty.build_deps }}"
|
ansible.builtin.set_fact:
|
||||||
|
pkg_sys: "{{ pkg_sys + alacritty.build_deps }}"
|
||||||
- name: Append alacritty to pkg_cargo
|
pkg_cargo: "{{ pkg_cargo + [alacritty.cargo] }}"
|
||||||
notify:
|
|
||||||
- Depend cargo
|
|
||||||
changed_when: true
|
|
||||||
ansible.builtin.set_fact:
|
|
||||||
pkg_cargo: "{{ pkg_cargo + [alacritty] }}"
|
|
||||||
|
|
||||||
- name: Append alacritty to pkg_cask
|
- name: Append alacritty to pkg_cask
|
||||||
when:
|
when:
|
||||||
- ansible_system == 'Darwin'
|
- alacritty.method == 'cask'
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
pkg_cask: "{{ pkg_cask + alacritty.cask }}"
|
pkg_cask: "{{ pkg_cask + ['alacritty'] }}"
|
||||||
|
|
||||||
- name: Set alacritty_configured
|
- name: Set alacritty_configured
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
|
|||||||
@@ -1,5 +1,11 @@
|
|||||||
alacritty:
|
alacritty:
|
||||||
version: 0.15.1
|
version: 0.15.1
|
||||||
|
method:
|
||||||
|
default: cargo
|
||||||
|
Darwin: cask
|
||||||
|
cargo:
|
||||||
|
locked: true
|
||||||
|
name: alacritty
|
||||||
build_deps:
|
build_deps:
|
||||||
RedHat:
|
RedHat:
|
||||||
- cmake
|
- cmake
|
||||||
@@ -24,5 +30,3 @@ alacritty:
|
|||||||
- libxcb-dev
|
- libxcb-dev
|
||||||
- libxkbcommon-dev
|
- libxkbcommon-dev
|
||||||
- pkgconf
|
- pkgconf
|
||||||
cask:
|
|
||||||
- alacritty
|
|
||||||
|
|||||||
Reference in New Issue
Block a user