Compare commits
2 Commits
1751438ff0
...
7eca867e0a
| Author | SHA1 | Date | |
|---|---|---|---|
|
7eca867e0a
|
|||
|
724cd1624e
|
@@ -0,0 +1,22 @@
|
||||
name: Release
|
||||
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- "v*"
|
||||
|
||||
jobs:
|
||||
archlinux:
|
||||
name: Arch Linux
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
packages: write
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: heyhusen/archlinux-package-action@v3.0.0
|
||||
with:
|
||||
path: .
|
||||
- run: ls -alh
|
||||
# - run: curl --user ${{ gitea.actor }}:${{ secrets.GITEA_TOKEN }} \
|
||||
# --upload-file $(ls | grep -E 'crete-[0-9]+\.[0-9]+\.[0-9]+-[0-9]+-.*.pkg.tar.zst') \
|
||||
# https://git.huizinga.dev/api/packages/infra/arch/core
|
||||
@@ -0,0 +1,34 @@
|
||||
# Maintainer: Tim Huizinga <tim@huizinga.dev>
|
||||
pkgname=crete
|
||||
pkgver=0.0.0
|
||||
pkgrel=1
|
||||
pkgdesc='A tool that takes node and cluster configs and uses it to generate talos configs and render jinja templates'
|
||||
url='https://git.huizinga.dev/infra/crete'
|
||||
license=('GPL-3.0-or-later')
|
||||
makedepends=('cargo-nightly')
|
||||
depends=()
|
||||
arch=('i686' 'x86_64' 'armv6h' 'armv7h')
|
||||
source=('LICENSE')
|
||||
sha256sums=('4bffc7da729013886ae68623c0d6145201b20a495879b589990953b2a27e1fbd')
|
||||
|
||||
pkgver() {
|
||||
cargo info $pkgname | grep -Po '^version: \K[\d\.]+'
|
||||
}
|
||||
|
||||
prepare() {
|
||||
export RUSTUP_TOOLCHAIN=nightly
|
||||
cargo fetch --locked --target host-tuple
|
||||
}
|
||||
|
||||
build() {
|
||||
export RUSTUP_TOOLCHAIN=nightly
|
||||
export CARGO_TARGET_DIR=target
|
||||
cargo build --frozen --release --all-features
|
||||
cargo run --bin $pkgname -- shell-completions > _$pkgname
|
||||
}
|
||||
|
||||
package() {
|
||||
install -Dm0644 -t "$pkgdir/usr/share/licenses/$pkgname/" "LICENSE"
|
||||
install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/$pkgname"
|
||||
install -Dm0644 -t "$pkgdir/usr/share/zsh/site-functions" "_$pkgname"
|
||||
}
|
||||
@@ -5,6 +5,32 @@ and render jinja templates.
|
||||
|
||||
## Installation
|
||||
|
||||
### Arch
|
||||
|
||||
First import the verification key:
|
||||
|
||||
```bash
|
||||
wget https://git.huizinga.dev/api/packages/infra/arch/repository.key -O /tmp/repository.key
|
||||
sudo pacman-key --add /tmp/repository.key
|
||||
sudo pacman-key --lsign-key $(gpg --show-keys /tmp/repository.key | sed -n 2p)
|
||||
```
|
||||
|
||||
And add the following to `/etc/pacman.conf`:
|
||||
|
||||
```ini
|
||||
[infra]
|
||||
SigLevel = Required
|
||||
Server = https://git.huizinga.dev/api/packages/infra/arch/core/$arch
|
||||
```
|
||||
|
||||
You can then install `crete` by running:
|
||||
|
||||
```bash
|
||||
sudo pacman -Sy crete
|
||||
```
|
||||
|
||||
### Cargo install
|
||||
|
||||
Add the following to `~/.cargo.config.toml`:
|
||||
|
||||
```toml
|
||||
|
||||
Reference in New Issue
Block a user