summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-14 20:04:50 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-14 20:04:50 +0000
commit782f8df6e41f29dce2db4970a3ad84aaeb7d8c5f (patch)
tree3a88a542cd8074743d251881131510157cfc510b /examples
parentInitial commit. (diff)
downloadansible-lint-upstream.tar.xz
ansible-lint-upstream.zip
Adding upstream version 4.3.7.upstream/4.3.7upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--examples/example.yml52
-rw-r--r--examples/handlers/y.yml2
-rw-r--r--examples/include.yml19
-rw-r--r--examples/lineno.yml2
-rw-r--r--examples/lots_of_warnings.yml1000
-rw-r--r--examples/nomatches.yml9
-rw-r--r--examples/play.yml6
-rw-r--r--examples/roles/bobbins/tasks/main.yml3
-rw-r--r--examples/roles/hello/meta/main.yml3
-rw-r--r--examples/roles/morecomplex/handlers/main.yml2
-rw-r--r--examples/roles/morecomplex/tasks/main.yml8
-rw-r--r--examples/rules/TaskHasTag.py37
-rw-r--r--examples/tasks/x.yml4
-rw-r--r--examples/unicode.yml5
14 files changed, 1152 insertions, 0 deletions
diff --git a/examples/example.yml b/examples/example.yml
new file mode 100644
index 0000000..1ce910d
--- /dev/null
+++ b/examples/example.yml
@@ -0,0 +1,52 @@
+---
+- hosts: webservers
+
+ vars:
+ oldskool: "1.2.3"
+ bracket: "and close bracket"
+
+ tasks:
+ - name: unset variable
+ action: command echo {{thisvariable}} is not set in this playbook
+
+ - name: trailing whitespace
+ action: command echo do nothing
+
+ - name: git check
+ action: git a=b c=d
+
+ - name: git check 2
+ action: git version=HEAD c=d
+
+ - name: git check 3
+ git: version=a1b2c3d4 repo=xyz bobbins=d
+
+ - name: executing git through command
+ action: command git clone blah
+
+ - name: executing git through command
+ action: command chdir=bobbins creates=whatever /usr/bin/git clone blah
+
+ - name: using git module
+ action: git repo=blah
+
+ - name: passing git as an argument to another task
+ action: debug msg="{{item}}"
+ with_items:
+ - git
+ - bobbins
+
+ - name: yum latest
+ yum: state=latest name=httpd
+
+ - debug: msg="task without a name"
+
+ - name: apt latest
+ apt: state=latest name=apache2
+
+ - name: always run
+ debug: msg="always_run is deprecated"
+ always_run: true
+
+ # empty task is currently accepted by ansible as valid code:
+ -
diff --git a/examples/handlers/y.yml b/examples/handlers/y.yml
new file mode 100644
index 0000000..fe98a7a
--- /dev/null
+++ b/examples/handlers/y.yml
@@ -0,0 +1,2 @@
+- name: funny handler
+ action: service name=funny state=started force=true
diff --git a/examples/include.yml b/examples/include.yml
new file mode 100644
index 0000000..0e056ec
--- /dev/null
+++ b/examples/include.yml
@@ -0,0 +1,19 @@
+---
+- hosts: bobbins
+
+
+ pre_tasks:
+ - include: tasks/x.yml
+
+ roles:
+ - hello
+ - { role: morecomplex, t: z }
+
+ tasks:
+ - include: tasks/x.yml
+ - include: tasks/x.yml y=z
+
+ handlers:
+ - include: handlers/y.yml
+
+- include: play.yml
diff --git a/examples/lineno.yml b/examples/lineno.yml
new file mode 100644
index 0000000..57f879d
--- /dev/null
+++ b/examples/lineno.yml
@@ -0,0 +1,2 @@
+- tasks:
+ - git: repo=hello
diff --git a/examples/lots_of_warnings.yml b/examples/lots_of_warnings.yml
new file mode 100644
index 0000000..38136e1
--- /dev/null
+++ b/examples/lots_of_warnings.yml
@@ -0,0 +1,1000 @@
+---
+# This playbook causes ansible-lint to output tons of warnings
+# Enough to exceed typical stdout buffering size and thus to show the need for
+# catching IOError (EPIEP) errors.
+
+- hosts: webservers
+
+ tasks:
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
+ - name: executing git through command
+ action: command git clone blah
diff --git a/examples/nomatches.yml b/examples/nomatches.yml
new file mode 100644
index 0000000..2cc726e
--- /dev/null
+++ b/examples/nomatches.yml
@@ -0,0 +1,9 @@
+---
+- hosts: whatever
+
+ tasks:
+ - name: hello world
+ action: debug msg="Hello!"
+
+ - name: this should be fine too
+ action: file state=touch mode=0644 dest=./wherever
diff --git a/examples/play.yml b/examples/play.yml
new file mode 100644
index 0000000..63e0678
--- /dev/null
+++ b/examples/play.yml
@@ -0,0 +1,6 @@
+---
+- hosts: bobbins
+
+ tasks:
+ - name: a bad play
+ action: command service blah restart
diff --git a/examples/roles/bobbins/tasks/main.yml b/examples/roles/bobbins/tasks/main.yml
new file mode 100644
index 0000000..8df6c6b
--- /dev/null
+++ b/examples/roles/bobbins/tasks/main.yml
@@ -0,0 +1,3 @@
+---
+- name: test tasks
+ action: git a=b c=d
diff --git a/examples/roles/hello/meta/main.yml b/examples/roles/hello/meta/main.yml
new file mode 100644
index 0000000..b15a998
--- /dev/null
+++ b/examples/roles/hello/meta/main.yml
@@ -0,0 +1,3 @@
+---
+dependencies:
+ - role: bobbins
diff --git a/examples/roles/morecomplex/handlers/main.yml b/examples/roles/morecomplex/handlers/main.yml
new file mode 100644
index 0000000..3d5b393
--- /dev/null
+++ b/examples/roles/morecomplex/handlers/main.yml
@@ -0,0 +1,2 @@
+- name: restart service using command
+ command: service bar restart
diff --git a/examples/roles/morecomplex/tasks/main.yml b/examples/roles/morecomplex/tasks/main.yml
new file mode 100644
index 0000000..ed68394
--- /dev/null
+++ b/examples/roles/morecomplex/tasks/main.yml
@@ -0,0 +1,8 @@
+- name: test bad command
+ action: command mkdir blah
+
+- name: test bad command v2
+ command: mkdir blah
+
+- name: test bad local command
+ local_action: shell touch foo
diff --git a/examples/rules/TaskHasTag.py b/examples/rules/TaskHasTag.py
new file mode 100644
index 0000000..58dfa7c
--- /dev/null
+++ b/examples/rules/TaskHasTag.py
@@ -0,0 +1,37 @@
+"""Example implementation of a rule requiring tasks to have tags set."""
+from ansiblelint.rules import AnsibleLintRule
+
+
+class TaskHasTag(AnsibleLintRule):
+ """Tasks must have tag."""
+
+ id = 'EXAMPLE001'
+ shortdesc = 'Tasks must have tag'
+ description = 'Tasks must have tag'
+ tags = ['productivity', 'tags']
+
+ def matchtask(self, file, task):
+ """Task matching method."""
+ # The meta files don't have tags
+ if file['type'] in ["meta", "playbooks"]:
+ return False
+
+ if isinstance(task, str):
+ return False
+
+ # If the task include another task or make the playbook fail
+ # Don't force to have a tag
+ if not set(task.keys()).isdisjoint(['include', 'fail']):
+ return False
+
+ if not set(task.keys()).isdisjoint(['include_tasks', 'fail']):
+ return False
+
+ if not set(task.keys()).isdisjoint(['import_tasks', 'fail']):
+ return False
+
+ # Task should have tags
+ if 'tags' not in task:
+ return True
+
+ return False
diff --git a/examples/tasks/x.yml b/examples/tasks/x.yml
new file mode 100644
index 0000000..c5a4f10
--- /dev/null
+++ b/examples/tasks/x.yml
@@ -0,0 +1,4 @@
+- name: test include
+ action: funny value=clown
+ args:
+ key: value
diff --git a/examples/unicode.yml b/examples/unicode.yml
new file mode 100644
index 0000000..c16ce92
--- /dev/null
+++ b/examples/unicode.yml
@@ -0,0 +1,5 @@
+---
+- hosts: all
+ tasks:
+ - name: ั‚ะตัั‚
+ command: uname