ansible-plugins-collection/plugins/filter/files.py

14 lines
308 B
Python
Raw Permalink Normal View History

2022-12-10 23:54:41 +01:00
from functools import partial
from ansible.utils.unicode import unicode_wrap
2022-12-11 00:39:24 +01:00
def abspath(fname):
return os.path.abspath(fname)
2022-12-10 23:54:41 +01:00
class FilterModule(object):
''' Ansible file jinja2 filters '''
def filters(self):
2022-12-11 00:39:24 +01:00
filters = {
'abspath': abspath
2022-12-10 23:54:41 +01:00
}
2022-12-11 00:39:24 +01:00
return filters