Skip to content

Commit e271f5c

Browse files
Fix ansible-lint rule violations
1 parent 7d1546f commit e271f5c

20 files changed

+65
-58
lines changed

galaxy.yml

+2-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
### REQUIRED
23
# The namespace of the collection. This can be a company/brand/organization or product namespace under which all
34
# content lives. May only contain alphanumeric lowercase characters and underscores. Namespaces cannot start with
@@ -8,7 +9,7 @@ namespace: wzzrd
89
name: atuin
910

1011
# The version of the collection. Must be compatible with semantic versioning
11-
version: "2.1.1"
12+
version: 2.1.1
1213

1314
# The path to the Markdown (.md) readme file. This path is relative to the root of the collection
1415
readme: README.md
@@ -18,7 +19,6 @@ readme: README.md
1819
authors:
1920
- Maxim Burgerhout <[email protected]>
2021

21-
2222
### OPTIONAL but strongly recommended
2323
# A short summary description of the collection
2424
description: Install and manage atuin on your systems
@@ -37,7 +37,6 @@ tags:
3737
- tools
3838

3939
dependencies: {}
40-
4140
repository: https://github.com/wzzrd/ansible-collection-atuin
4241

4342
documentation: https://github.com/wzzrd/ansible-collection-atuin

meta/runtime.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
# Collections must specify a minimum required ansible version to upload
33
# to galaxy
4-
requires_ansible: '>=2.15.0'
4+
requires_ansible: ">=2.15.0"
55

66
# Content that Ansible needs to load from another location or that has
77
# been deprecated/removed

roles/atuin_client/defaults/main.yml

+17-17
Original file line numberDiff line numberDiff line change
@@ -8,22 +8,22 @@ atuin_client_bin_dir: /usr/local/bin
88
atuin_client_libc_variant: gnu
99

1010
## where to store your database, default is your system data directory
11-
atuin_client_db_path: "~/.local/share/atuin/history.db"
11+
atuin_client_db_path: ~/.local/share/atuin/history.db
1212

1313
## where to store your encryption key, default is your system data directory
14-
atuin_client_key_path: "~/.local/share/atuin/key"
14+
atuin_client_key_path: ~/.local/share/atuin/key
1515

1616
## where to store your auth session token, default is your system data directory
17-
atuin_client_session_path: "~/.local/share/atuin/session"
17+
atuin_client_session_path: ~/.local/share/atuin/session
1818

1919
## date format used, either "us" or "uk"
20-
atuin_client_dialect: "uk"
20+
atuin_client_dialect: uk
2121

2222
## default timezone to use when displaying time
2323
## either "l", "local" to use the system's current local timezone, or an offset
2424
## from UTC in the format of "<+|->H[H][:M[M][:S[S]]]"
2525
## for example: "+9", "-05", "+03:30", "-01:23:45", etc.
26-
atuin_client_timezone: "local"
26+
atuin_client_timezone: local
2727

2828
## enable or disable automatic sync
2929
atuin_client_auto_sync: true
@@ -32,20 +32,20 @@ atuin_client_auto_sync: true
3232
atuin_client_update_check: true
3333

3434
## address of the sync server
35-
atuin_client_sync_address: "https://api.atuin.sh"
35+
atuin_client_sync_address: https://api.atuin.sh
3636

3737
## how often to sync history. note that this is only triggered when a command
3838
## is ran, so sync intervals may well be longer
3939
## set it to 0 to sync after every command
40-
atuin_client_sync_frequency: "10m"
40+
atuin_client_sync_frequency: 10m
4141

4242
## which search mode to use
4343
## possible values: prefix, fulltext, fuzzy, skim
44-
atuin_client_search_mode: "fuzzy"
44+
atuin_client_search_mode: fuzzy
4545

4646
## which filter mode to use
4747
## possible values: global, host, session, directory
48-
atuin_client_filter_mode: "global"
48+
atuin_client_filter_mode: global
4949

5050
## With workspace filtering enabled, Atuin will filter for commands executed
5151
## in any directory within a git repository tree (default: false)
@@ -54,16 +54,16 @@ atuin_client_workspaces: false
5454
## which filter mode to use when atuin is invoked from a shell up-key binding
5555
## the accepted values are identical to those of "filter_mode"
5656
## leave unspecified to use same mode set in "filter_mode"
57-
atuin_client_filter_mode_shell_up_key_binding: "global"
57+
atuin_client_filter_mode_shell_up_key_binding: global
5858

5959
## which search mode to use when atuin is invoked from a shell up-key binding
6060
## the accepted values are identical to those of "search_mode"
6161
## leave unspecified to use same mode set in "search_mode"
62-
atuin_client_search_mode_shell_up_key_binding: "fuzzy"
62+
atuin_client_search_mode_shell_up_key_binding: fuzzy
6363

6464
## which style to use
6565
## possible values: auto, full, compact
66-
atuin_client_style: "auto"
66+
atuin_client_style: auto
6767

6868
## the maximum number of lines the interface should take up
6969
## set it to 0 to always go full screen
@@ -78,13 +78,13 @@ atuin_client_show_preview: false
7878

7979
## what to do when the escape key is pressed when searching
8080
## possible values: return-original, return-query
81-
atuin_client_exit_mode: "return-original"
81+
atuin_client_exit_mode: return-original
8282

8383
## possible values: emacs, subl
84-
atuin_client_word_jump_mode: "emacs"
84+
atuin_client_word_jump_mode: emacs
8585

8686
## characters that count as a part of a word
87-
atuin_client_word_chars: "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789"
87+
atuin_client_word_chars: abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789
8888

8989
## number of context lines to show when scrolling by pages
9090
atuin_client_scroll_context_lines: 1
@@ -145,7 +145,7 @@ atuin_client_enter_accept: true
145145
## keybinding is defined. If this is set to "emacs", "vim-insert", or
146146
## "vim-normal", the startup keymap mode in the Atuin search is forced to be
147147
## the specified one.
148-
atuin_client_keymap_mode: "auto"
148+
atuin_client_keymap_mode: auto
149149

150150
## Cursor style in each keymap mode. If specified, the cursor style is changed
151151
## in entering the cursor shape. Available values are "default" and
@@ -176,4 +176,4 @@ atuin_client_common_subcommands: |
176176
]
177177
178178
# Set commands that should be totally stripped and ignored from stats
179-
atuin_client_common_prefix: ["sudo"]
179+
atuin_client_common_prefix: [sudo]

roles/atuin_client/meta/main.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
galaxy_info:
23
author: Maxim Burgerhout
34
description: Role to deploy the atuin shell history tool

roles/atuin_client/molecule/default/converge.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Converge
23
hosts: all
34
# We disable gather facts because it would fail due to our container not
@@ -9,7 +10,7 @@
910
- name: Gather required subset of facts
1011
ansible.builtin.setup:
1112
gather_subset:
12-
- '!all'
13+
- "!all"
1314

1415
roles:
1516
- role: atuin_client

roles/atuin_client/molecule/default/molecule.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ platforms:
1010
volumes:
1111
- /sys/fs/cgroup:/sys/fs/cgroup:ro
1212
privileged: true
13-
command: "/usr/sbin/init"
13+
command: /usr/sbin/init
1414
platform: linux/amd64
1515
- name: ubi9
1616
image: registry.access.redhat.com/ubi9/ubi-init:latest
@@ -19,15 +19,15 @@ platforms:
1919
volumes:
2020
- /sys/fs/cgroup:/sys/fs/cgroup:rw
2121
privileged: true
22-
command: "/usr/sbin/init"
22+
command: /usr/sbin/init
2323
platform: linux/amd64
2424
provisioner:
2525
name: ansible
2626
inventory:
2727
host_vars:
2828
ubi8:
29-
atuin_client_libc_variant: "musl"
29+
atuin_client_libc_variant: musl
3030
ubi9:
31-
atuin_client_libc_variant: "gnu"
31+
atuin_client_libc_variant: gnu
3232
verifier:
3333
name: ansible

roles/atuin_client/molecule/default/prepare.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Prepare containers for molecule tests
23
hosts: all
34
gather_facts: false

roles/atuin_client/molecule/default/verify.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Verify
23
hosts: all
34
# We disable gather facts because it would fail due to our container not

roles/atuin_client/tasks/main.yml

+8-10
Original file line numberDiff line numberDiff line change
@@ -36,15 +36,14 @@
3636

3737
- name: Download and install new binary, if needed, for old atuin
3838
when:
39-
- (detected_version is not defined) or
40-
(atuin_client_version != detected_version)
39+
- (detected_version is not defined) or (atuin_client_version != detected_version)
4140
- atuin_client_version is version('18.3.0', '<')
4241
tags:
4342
- version
4443
block:
4544
- name: Formulate artifact name
4645
ansible.builtin.set_fact:
47-
atuin_client_artifact: atuin-v{{ atuin_client_version }}-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}.tar.gz # noqa yaml[line-length]
46+
atuin_client_artifact: atuin-v{{ atuin_client_version }}-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}.tar.gz # noqa yaml[line-length]
4847

4948
- name: Show artifact name
5049
ansible.builtin.debug:
@@ -57,8 +56,8 @@
5756
ansible.builtin.unarchive:
5857
src: https://github.com/atuinsh/atuin/releases/download/v{{ atuin_client_version }}/{{ atuin_client_artifact }} # noqa yaml[line-length].
5958
remote_src: true
60-
dest: "/tmp"
61-
include: "atuin-v{{ atuin_client_version }}-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}/atuin" # noqa yaml[line-length]
59+
dest: /tmp
60+
include: atuin-v{{ atuin_client_version }}-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}/atuin # noqa yaml[line-length]
6261
owner: root
6362
group: root
6463
mode: "0755"
@@ -82,15 +81,14 @@
8281

8382
- name: Download and install new binary, if needed, for new atuin
8483
when:
85-
- (detected_version is not defined) or
86-
(atuin_client_version != detected_version)
84+
- (detected_version is not defined) or (atuin_client_version != detected_version)
8785
- atuin_client_version is version('18.3.0', '>=')
8886
tags:
8987
- version
9088
block:
9189
- name: Formulate artifact name
9290
ansible.builtin.set_fact:
93-
atuin_client_artifact: atuin-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}.tar.gz # noqa yaml[line-length]
91+
atuin_client_artifact: atuin-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}.tar.gz # noqa yaml[line-length]
9492

9593
- name: Show artifact name
9694
ansible.builtin.debug:
@@ -103,8 +101,8 @@
103101
ansible.builtin.unarchive:
104102
src: https://github.com/atuinsh/atuin/releases/download/v{{ atuin_client_version }}/{{ atuin_client_artifact }} # noqa yaml[line-length].
105103
remote_src: true
106-
dest: "/tmp"
107-
include: "atuin-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}/atuin" # noqa yaml[line-length]
104+
dest: /tmp
105+
include: atuin-{{ ansible_architecture }}-unknown-linux-{{ atuin_client_libc_variant }}/atuin # noqa yaml[line-length]
108106
owner: root
109107
group: root
110108
mode: "0755"

roles/atuin_client/tasks/users.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Get user info for {{ item }}
23
ansible.builtin.getent:
34
database: passwd

roles/atuin_server/handlers/main.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
2-
- name: "Restart atuin"
2+
- name: Restart atuin
33
ansible.builtin.service:
44
name: atuin
55
state: restarted
66

7-
- name: "Reload systemd"
7+
- name: Reload systemd
88
ansible.builtin.systemd:
99
daemon_reload: true

roles/atuin_server/meta/main.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
galaxy_info:
23
author: Maxim Burgerhout
34
description: Role to deploy the atuin shell history tool, server component

roles/atuin_server/molecule/default/converge.yml

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Converge server
23
hosts: all
34
# We disable gather facts because it would fail due to our container not
@@ -7,13 +8,13 @@
78
gather_facts: false
89
vars:
910
atuin_client_version: 18.3.0
10-
atuin_server_db_uri: "postgres://atuin:atuin@{{ atuin_server_host }}/atuin"
11+
atuin_server_db_uri: postgres://atuin:atuin@{{ atuin_server_host }}/atuin
1112

1213
pre_tasks:
1314
- name: Gather required subset of facts
1415
ansible.builtin.setup:
1516
gather_subset:
16-
- '!all'
17+
- "!all"
1718
- default_ipv4
1819

1920
roles:

roles/atuin_server/molecule/default/molecule.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ platforms:
1111
volumes:
1212
- /sys/fs/cgroup:/sys/fs/cgroup:rw
1313
privileged: true
14-
command: "/usr/sbin/init"
14+
command: /usr/sbin/init
1515
platform: linux/amd64
1616
- name: ubi9
1717
image: registry.access.redhat.com/ubi9/ubi-init:latest
@@ -20,15 +20,15 @@ platforms:
2020
volumes:
2121
- /sys/fs/cgroup:/sys/fs/cgroup:rw
2222
privileged: true
23-
command: "/usr/sbin/init"
23+
command: /usr/sbin/init
2424
platform: linux/amd64
2525
provisioner:
2626
name: ansible
2727
inventory:
2828
host_vars:
2929
ubi8:
30-
atuin_client_libc_variant: "musl"
30+
atuin_client_libc_variant: musl
3131
ubi9:
32-
atuin_client_libc_variant: "gnu"
32+
atuin_client_libc_variant: gnu
3333
verifier:
3434
name: ansible

roles/atuin_server/molecule/default/prepare.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Prepare containers for molecule tests
23
hosts: ubi8
34
gather_facts: false
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
1+
---
12
collections:
23
- containers.podman

roles/atuin_server/molecule/default/verify.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
---
12
- name: Verify
23
hosts: all
34
# We disable gather facts because it would fail due to our container not

roles/atuin_server/tasks/create_user.yml

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,14 @@
11
---
2-
- name: "Create atuin group"
2+
- name: Create atuin group
33
ansible.builtin.group:
44
name: "{{ atuin_server_group }}"
55
system: true
6-
state: "present"
6+
state: present
77

8-
- name: "Create atuin user"
8+
- name: Create atuin user
99
ansible.builtin.user:
1010
name: "{{ atuin_server_user }}"
11-
comment: "atuin server user"
11+
comment: atuin server user
1212
group: "{{ atuin_server_group }}"
1313
home: "{{ atuin_server_home }}"
1414
shell: /sbin/nologin

0 commit comments

Comments
 (0)