From fae63e28f93407bd3740852573c996fd80bd14f7 Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Mon, 12 May 2025 19:22:28 +0300 Subject: [PATCH 1/5] fix license-header.tmpl --- license-header.tmpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/license-header.tmpl b/license-header.tmpl index 367a718..e5003de 100644 --- a/license-header.tmpl +++ b/license-header.tmpl @@ -1,5 +1,5 @@ ALR - Any Linux Repository -Copyright (C) {{ .Year }} Евгений Храмов +Copyright (C) {{ .Year }} The ALR Authors This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by -- 2.49.1 From 56b9f3211c59c2e88c9399cdde2b333f4c5dbdfb Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Mon, 12 May 2025 19:22:50 +0300 Subject: [PATCH 2/5] ci: add simple workflow for pre-commit --- .gitea/workflows/pre-commit.yaml | 46 ++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .gitea/workflows/pre-commit.yaml diff --git a/.gitea/workflows/pre-commit.yaml b/.gitea/workflows/pre-commit.yaml new file mode 100644 index 0000000..dee0316 --- /dev/null +++ b/.gitea/workflows/pre-commit.yaml @@ -0,0 +1,46 @@ +# ALR - Any Linux Repository +# Copyright (C) 2025 The ALR Authors +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + + +name: Pre-commit + +on: + push: + branches: [ main ] + pull_request: + + +jobs: + pre-commit: + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: https://github.com/actions/checkout@v4 + + - name: Set up Go + uses: https://github.com/actions/setup-go@v5 + with: + go-version: '1.23' + + - name: Set up Python for pre-commit + uses: https://github.com/actions/setup-python@v5 + with: + python-version: '3.12' + + - run: pip install pre-commit + - run: pre-commit install + - run: pre-commit run --all-files \ No newline at end of file -- 2.49.1 From ce1836b6465d49a0a0d9a95897b76c6d92753522 Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Mon, 12 May 2025 19:30:15 +0300 Subject: [PATCH 3/5] ci: use go 1.24 --- .gitea/workflows/pre-commit.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/pre-commit.yaml b/.gitea/workflows/pre-commit.yaml index dee0316..c846a13 100644 --- a/.gitea/workflows/pre-commit.yaml +++ b/.gitea/workflows/pre-commit.yaml @@ -34,7 +34,7 @@ jobs: - name: Set up Go uses: https://github.com/actions/setup-go@v5 with: - go-version: '1.23' + go-version: '1.24' - name: Set up Python for pre-commit uses: https://github.com/actions/setup-python@v5 -- 2.49.1 From 750513b11931187e0987d5f2d399d6cea2d94232 Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Mon, 12 May 2025 19:46:52 +0300 Subject: [PATCH 4/5] fix ci --- .gitea/workflows/pre-commit.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitea/workflows/pre-commit.yaml b/.gitea/workflows/pre-commit.yaml index c846a13..a107511 100644 --- a/.gitea/workflows/pre-commit.yaml +++ b/.gitea/workflows/pre-commit.yaml @@ -40,6 +40,9 @@ jobs: uses: https://github.com/actions/setup-python@v5 with: python-version: '3.12' + + - name: Install deps + run: apt-get update && apt-get install -y gettext bc - run: pip install pre-commit - run: pre-commit install -- 2.49.1 From c892310f6936ceec30d0ad8f7a0628a5e3f2bca8 Mon Sep 17 00:00:00 2001 From: Maxim Slipenko Date: Mon, 12 May 2025 20:11:55 +0300 Subject: [PATCH 5/5] fix Makefile --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index c6ee88b..ff8412b 100644 --- a/Makefile +++ b/Makefile @@ -54,7 +54,7 @@ uninstall: clean clear: rm -f $(BIN) -OLD_FILES=$$(< old-files) +OLD_FILES=$(shell cat old-files) IGNORE_OLD_FILES := $(foreach file,$(shell cat old-files),-ignore $(file)) update-license: $(ADD_LICENSE_BIN) -v -f license-header-old-files.tmpl $(OLD_FILES) -- 2.49.1