ci: automatic updates #2
							
								
								
									
										44
									
								
								.gitea/workflows/update.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										44
									
								
								.gitea/workflows/update.yml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,44 @@ | ||||
| name: Update packages | ||||
|  | ||||
| on: | ||||
|   schedule: | ||||
|     - cron: '0 0 * * *' | ||||
|   workflow_dispatch: | ||||
|  | ||||
| jobs: | ||||
|   update-specs: | ||||
|     runs-on: ubuntu-latest | ||||
|     steps: | ||||
|       - name: Checkout repo | ||||
|         uses: actions/checkout@v4 | ||||
|       - name: Install alr-spec deps | ||||
|         run: | | ||||
|           apt-get update && apt-get install -y python3-nvchecker shfmt | ||||
|       - name: Install alr-spec | ||||
|         run: | | ||||
|           curl -L -o /bin/alr-spec https://altlinux.space/aides-community/alr-utils/releases/download/v0.0.4/alr-spec-linux-amd64 | ||||
|           chmod +x /bin/alr-spec | ||||
|       - name: Update | ||||
|         run: | | ||||
|           set -e | ||||
|           PACKAGES=( | ||||
|             "discord-bin" | ||||
|             "firefox-bin" | ||||
|             "telegram-desktop-bin" | ||||
|           ) | ||||
|           for pkg in "${PACKAGES[@]}" | ||||
|           do | ||||
|             echo "Updating $pkg" | ||||
|             alr-spec update-package --keep-skip-checksums "./$pkg" | ||||
|           done | ||||
|       - name: Commit and push if changes | ||||
|         run: | | ||||
|           git config user.name "gitea" | ||||
|           git config user.email "admin@plemya-x.ru" | ||||
|           if [ -n "$(git status --porcelain)" ]; then | ||||
|             git add . | ||||
|             git commit -m "Automatic package updates" | ||||
|             git push | ||||
|           else | ||||
|             echo "No changes to commit." | ||||
|           fi | ||||
							
								
								
									
										4
									
								
								discord-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								discord-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | ||||
| [discord-linux-tar] | ||||
| source = "httpheader" | ||||
| url = "https://discord.com/api/download?platform=linux&format=tar.gz" | ||||
| regex = "discord-([0-9.]+).tar.gz" | ||||
							
								
								
									
										4
									
								
								firefox-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										4
									
								
								firefox-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,4 @@ | ||||
| [firefox] | ||||
| source = "regex" | ||||
| url = "https://product-details.mozilla.org/1.0/firefox_versions.json" | ||||
| regex = '"LATEST_FIREFOX_VERSION": "([0-9.]+)"' | ||||
							
								
								
									
										5
									
								
								telegram-desktop-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										5
									
								
								telegram-desktop-bin/.nvchecker.toml
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,5 @@ | ||||
| [telegram-desktop-bin] | ||||
| source = "github" | ||||
| github = "telegramdesktop/tdesktop" | ||||
| use_latest_release = true | ||||
| prefix = "v" | ||||
		Reference in New Issue
	
	Block a user