Skip to content

Commit afccdf0

Browse files
committed
Avoid regex
1 parent 08592ec commit afccdf0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

roles/ota/apps/defaults/main.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
---
22
ota_apps_read_config_only: false
33
ota_source_repository_branch: main
4-
ota_directory: "{{ ota_source_repository | urlsplit('path') | regex_replace('^.*/(.+?)(\\.git)?$', '\\1') }}" # extract the repository name from the URL
4+
ota_directory: "{{ ota_source_repository | ansible.builtin.urlsplit('path') | ansible.builtin.basename | ansible.builtin.splitext | first }}" # extract the repository name from the URL

0 commit comments

Comments
 (0)