Co-authored-by: meaz <meaz@disroot.org>
Reviewed-on: #47
Reviewed-by: meaz <meaz@no-reply@disroot.org>
Co-authored-by: muppeth <muppeth@disroot.org>
Co-committed-by: muppeth <muppeth@disroot.org>
This commit is contained in:
muppeth 2024-06-15 14:52:48 +02:00 committed by muppeth
parent 5e5c8dd415
commit 1e84bbe2e9
2 changed files with 18 additions and 5 deletions

View file

@ -8,7 +8,7 @@ forgejo_confdir: '/etc/forgejo/app.ini'
forgejo_dump_path: '/srv/forgejo-dump'
forgejo_flavor: 'forgejo'
forgejo_version: '7.0.3'
forgejo_version: '7.0.4'
#forgejo_version: '1.21.7-0'
forgejo_arch: 'linux-amd64'
#forgejo_download_url: 'https://github.com/go-gitea/gitea/releases/download/v{{ forgejo_version }}/gitea-{{ forgejo_version }}-{{ forgejo_arch }}'

View file

@ -39,14 +39,27 @@
become_user: "{{ forgejo_user }}"
tags: theme
- name: "[THEME] - Find css files from different repos and copy them in the public folder"
shell:
cmd: find "{{ forgejo_theme_dir }}" -type f -name "*.css" -not -path "{{ forgejo_theme_dir }}/public/*" | xargs cp -t "{{ forgejo_theme_dir }}/public/assets/css"
chdir: "{{ forgejo_theme_dir }}"
- name: "[THEME] - Find css files from different repos"
find:
paths: "{{ forgejo_theme_dir }}"
patterns: "*.css"
recurse: yes
register: css_files
tags: theme
- name: "[THEME] - Copy css files to the public folder"
copy:
src: "{{ item.path }}"
dest: "{{ forgejo_theme_dir }}/public/assets/css/"
remote_src: yes
force: yes
with_items: "{{ css_files.files }}"
when: "'/public/' not in item.path"
become: true
become_user: "{{ forgejo_user }}"
tags: theme
# Lastly, update app.ini by adding the theme's name list.
- name: "[THEME] - Get and prepare a list for app.ini of css files in public folder, register it"
shell: