ready to release
This commit is contained in:
parent
b9c54f42bd
commit
e94e7f03fe
4 changed files with 12 additions and 21 deletions
8
.github/workflows/build.yaml
vendored
8
.github/workflows/build.yaml
vendored
|
@ -1,9 +1,11 @@
|
|||
# This workflow will build an Arch Linux ISO file with the commit on it
|
||||
name: Build Arch ISO with ArchInstall Commit
|
||||
name: build parchiso per release
|
||||
on:
|
||||
release:
|
||||
types:
|
||||
- created
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
api_key: ${{ secrets.GITHUB_TOKEN }}
|
||||
name: ${{ github.event.repository.name }}
|
||||
|
@ -15,10 +17,6 @@ jobs:
|
|||
image: archlinux:latest
|
||||
options: --privileged
|
||||
steps:
|
||||
- uses: crazy-max/ghaction-import-gpg@v4
|
||||
with:
|
||||
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
|
||||
passphrase: ${{ secrets.PASSPHRASE }}
|
||||
- uses: actions/checkout@v3
|
||||
- name: Install Packages via Pacman
|
||||
run: pacman -Sy; pacman --noconfirm -S git archiso python python-pip
|
||||
|
|
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
out/
|
|
@ -1,12 +1,10 @@
|
|||
#!/usr/bin/env bash
|
||||
# shellcheck disable=SC2034
|
||||
|
||||
iso_name="Parchlinux"
|
||||
iso_label="PARCH_$(date +%Y%m)"
|
||||
iso_publisher="Parch Linux <https://github.com/parch-os/>"
|
||||
iso_name="Parchlinux Plasma"
|
||||
iso_label="PARCHLINUX_PLASMA_$(date +%Y%m)"
|
||||
iso_publisher="Parch Linux <parchlinux.ir>"
|
||||
iso_application="Parch Linux Live/Rescue CD"
|
||||
#gpg_key="BC9DCC3C9A0B047F53065EEBFB8554F927F96E60"
|
||||
#gpg_signer="KomeilParseh <ahmdparsh129@gmail.com>"
|
||||
iso_version="$(date +%Y.%m.%d)"
|
||||
install_dir="arch"
|
||||
buildmodes=('iso')
|
||||
|
|
|
@ -2,17 +2,16 @@ import logging
|
|||
import os
|
||||
import sys
|
||||
from datetime import datetime
|
||||
from glob import glob
|
||||
|
||||
from pathlib import Path
|
||||
from github import Github
|
||||
|
||||
logging.basicConfig(level=logging.INFO, format="%(levelname)s: %(message)s")
|
||||
|
||||
api_key = os.getenv("api_key", None)
|
||||
current_date = datetime.today().strftime("%Y-%m-%d")
|
||||
path = glob(r"/__w/parch-iso-template/parch-iso-template/out/*.iso")[
|
||||
0
|
||||
] # edit this if your not use in workflow
|
||||
|
||||
path = list(Path().cwd().glob("out/*.iso"))[0].as_posix()
|
||||
|
||||
repo_name = os.getenv("name", None)
|
||||
release_name = os.getenv("release_name", None)
|
||||
|
||||
|
@ -27,7 +26,7 @@ if not (repo_name and api_key and release_name):
|
|||
|
||||
|
||||
gh = Github(api_key)
|
||||
repo = gh.get_repo(f"parch-os/{repo_name}")
|
||||
repo = gh.get_repo(f"parchlinux/{repo_name}")
|
||||
|
||||
release = repo.get_release(release_name)
|
||||
|
||||
|
@ -35,8 +34,3 @@ logging.info("statrting Upload ISO to release")
|
|||
|
||||
release.upload_asset(path=path)
|
||||
logging.info("ISO upload is done")
|
||||
|
||||
logging.info("statrting Upload ISO gpg key to release")
|
||||
release.upload_asset(
|
||||
"/__w/parch-iso-template/parch-iso-template/iso/public.key"
|
||||
) # noqa: E501:w
|
||||
|
|
Loading…
Add table
Reference in a new issue