✨ PKGBUILD
This commit is contained in:
parent
cf5f641012
commit
2ed0bbb1a6
4 changed files with 71 additions and 14 deletions
|
@ -13,3 +13,14 @@ steps:
|
||||||
username: jmarya
|
username: jmarya
|
||||||
password:
|
password:
|
||||||
from_secret: registry_token
|
from_secret: registry_token
|
||||||
|
|
||||||
|
- name: "PKGBUILD"
|
||||||
|
image: git.hydrar.de/jmarya/pacco:latest
|
||||||
|
commands:
|
||||||
|
- pacco build --ci --push navos
|
||||||
|
environment:
|
||||||
|
PACCO_HOST: "https://pac.hydrar.de"
|
||||||
|
PACCO_TOKEN:
|
||||||
|
from_secret: pacco_token
|
||||||
|
SIGN_KEY:
|
||||||
|
from_secret: sign_key
|
||||||
|
|
|
@ -3,6 +3,10 @@ name = "pacco"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
edition = "2024"
|
edition = "2024"
|
||||||
|
|
||||||
|
[[bin]]
|
||||||
|
name = "pacco"
|
||||||
|
path = "src/main.rs"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
based = { git = "https://git.hydrar.de/jmarya/based" }
|
based = { git = "https://git.hydrar.de/jmarya/based" }
|
||||||
comrade = { git = "https://git.hydrar.de/jmarya/comrade" }
|
comrade = { git = "https://git.hydrar.de/jmarya/comrade" }
|
||||||
|
|
39
PKGBUILD
Normal file
39
PKGBUILD
Normal file
|
@ -0,0 +1,39 @@
|
||||||
|
# Maintainer: JMARyA <jmarya@hydrar.de>
|
||||||
|
pkgname=pacco
|
||||||
|
pkgver=main
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc="pacman package tool"
|
||||||
|
arch=('x86_64' 'aarch64')
|
||||||
|
url="https://git.hydrar.de/jmarya/pacco"
|
||||||
|
license=("MIT")
|
||||||
|
depends=('tar' 'xz' 'zstd' 'curl' 'base-devel' 'git' 'rsync' 'pacman')
|
||||||
|
optdepends=('docker')
|
||||||
|
makedepends=("rustup" "git")
|
||||||
|
source=("${pkgname}::git+https://git.hydrar.de/jmarya/pacco.git")
|
||||||
|
sha256sums=("SKIP")
|
||||||
|
|
||||||
|
pkgver() {
|
||||||
|
cd "$srcdir/$pkgname"
|
||||||
|
echo "$(date +%Y.%m.%d)_$(git rev-parse --short HEAD)"
|
||||||
|
}
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
cd "$srcdir/$pkgname"
|
||||||
|
rustup default nightly
|
||||||
|
cargo fetch
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cd "$srcdir/$pkgname"
|
||||||
|
cargo build --release
|
||||||
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
cd "$srcdir/$pkgname"
|
||||||
|
cargo test --release
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
cd "$srcdir/$pkgname"
|
||||||
|
install -Dm755 "target/release/pacco" "$pkgdir/usr/bin/pacco"
|
||||||
|
}
|
31
src/main.rs
31
src/main.rs
|
@ -56,20 +56,23 @@ async fn launch(config: String) {
|
||||||
..Default::default()
|
..Default::default()
|
||||||
})
|
})
|
||||||
.mount_assets()
|
.mount_assets()
|
||||||
.mount("/", routes![
|
.mount(
|
||||||
routes::index_page,
|
"/",
|
||||||
routes::pkg_route,
|
routes![
|
||||||
routes::push::upload_pkg,
|
routes::index_page,
|
||||||
routes::user::login,
|
routes::pkg_route,
|
||||||
routes::user::login_post,
|
routes::push::upload_pkg,
|
||||||
routes::user::account_page,
|
routes::user::login,
|
||||||
routes::ui::pkg_ui,
|
routes::user::login_post,
|
||||||
routes::ui::repo_ui,
|
routes::user::account_page,
|
||||||
routes::user::new_api_key,
|
routes::ui::pkg_ui,
|
||||||
routes::user::end_session,
|
routes::ui::repo_ui,
|
||||||
routes::user::change_password,
|
routes::user::new_api_key,
|
||||||
routes::user::change_password_post
|
routes::user::end_session,
|
||||||
])
|
routes::user::change_password,
|
||||||
|
routes::user::change_password_post
|
||||||
|
],
|
||||||
|
)
|
||||||
.manage(config)
|
.manage(config)
|
||||||
.manage(shell)
|
.manage(shell)
|
||||||
.launch()
|
.launch()
|
||||||
|
|
Loading…
Add table
Reference in a new issue