From 73682f1194b1056bed675daf3ae79019fb8035c0 Mon Sep 17 00:00:00 2001 From: Luke Harding Date: Tue, 30 Apr 2024 13:20:01 -0400 Subject: [PATCH 1/5] Work on #1 and #4 --- .gitea/workflows/build-on-release.yaml | 13 +++++++++++ Cargo.toml | 1 + README.md | 31 +++++++++++++++++++++++++- 3 files changed, 44 insertions(+), 1 deletion(-) create mode 100644 .gitea/workflows/build-on-release.yaml diff --git a/.gitea/workflows/build-on-release.yaml b/.gitea/workflows/build-on-release.yaml new file mode 100644 index 0000000..85e0b87 --- /dev/null +++ b/.gitea/workflows/build-on-release.yaml @@ -0,0 +1,13 @@ +name: Build on Release +run-name: ${{ gitea.actor }} +on: [ release ] + +jobs: + cargo-build: + runs-on: ubuntu-latest + steps: + - name: Check out code repository + uses: actions/checkout@v4 + - name: Is cargo installed? + run: | + which cargo \ No newline at end of file diff --git a/Cargo.toml b/Cargo.toml index 9d85513..c174e0a 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,6 +2,7 @@ name = "rust-archlinux-update" version = "0.1.0" edition = "2021" +license = "GPL-3" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html diff --git a/README.md b/README.md index e028eb7..26ac2ba 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,32 @@ # Rust Arch Linux Updater -A program that automates the arch update process with cleanup and auto removal \ No newline at end of file +A program that automates the arch update process with cleanup and auto removal. + +***Currently, a WIP. USE AT OWN RISK*** + +## Setup + +The current state requires that you build it yourself. The most up-to-date version will be on the development branch. + +Just run `cargo build --release` and copy the executable from `./target/release/rust-archlinux-update` to wherever you +need it. + +Distribution on pre-built binaries, cargo, etc. is in the works. + +## Usage + +The default behavior of the command is to use pacman to run a package update, auto-removal, and cache clear in that +order. + +In the future the command will support AUR helpers like paru and those will need to be activated with a flag. + +## Issue Reporting + +I don't allow random sign-ups on my gitea instance. Please email me at [luke@lukeh990.io](mailto:luke@lukeh990.io). + +If you have any suggestions for how to better handle issue reporting please email me. + +## Contributing + +If you are the one person to read this and want to copy the source and work on it please follow the GPLv3 license. +If you decide to contribute back email me, and we'll figure out the best way for you to contribute. \ No newline at end of file From a19d7e026a35b46c699bdb755bcee8fd01e2b09f Mon Sep 17 00:00:00 2001 From: Luke Harding Date: Tue, 30 Apr 2024 13:37:21 -0400 Subject: [PATCH 2/5] Testing #4 --- .gitea/workflows/build-on-release.yaml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/build-on-release.yaml b/.gitea/workflows/build-on-release.yaml index 85e0b87..cd46ccd 100644 --- a/.gitea/workflows/build-on-release.yaml +++ b/.gitea/workflows/build-on-release.yaml @@ -4,10 +4,15 @@ on: [ release ] jobs: cargo-build: - runs-on: ubuntu-latest + runs-on: ubuntu-latest-rust steps: - name: Check out code repository uses: actions/checkout@v4 - - name: Is cargo installed? + - name: Build Binary run: | - which cargo \ No newline at end of file + cargo build --release + - name: Push binary to artifact + uses: actions/upload-artifact@v4 + with: + name: build + path: ./target/release/rust-archlinux-update \ No newline at end of file From f856a1d89ad25f79f748f4e0d0956cc1ab319efc Mon Sep 17 00:00:00 2001 From: Luke Harding Date: Tue, 30 Apr 2024 13:50:02 -0400 Subject: [PATCH 3/5] On push to main build and create draft release --- .gitea/workflows/build-on-release.yaml | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitea/workflows/build-on-release.yaml b/.gitea/workflows/build-on-release.yaml index cd46ccd..bdd9574 100644 --- a/.gitea/workflows/build-on-release.yaml +++ b/.gitea/workflows/build-on-release.yaml @@ -1,6 +1,9 @@ name: Build on Release run-name: ${{ gitea.actor }} -on: [ release ] +on: + push: + branches: + - main jobs: cargo-build: @@ -12,7 +15,8 @@ jobs: run: | cargo build --release - name: Push binary to artifact - uses: actions/upload-artifact@v4 + uses: actions/gitea-release-action@v1 with: - name: build - path: ./target/release/rust-archlinux-update \ No newline at end of file + draft: true + files: |- + target/release/rust-archlinux-update \ No newline at end of file From 1cd20200b5e809dbac876ecd30a0bb054747c091 Mon Sep 17 00:00:00 2001 From: Luke Harding Date: Tue, 30 Apr 2024 13:52:23 -0400 Subject: [PATCH 4/5] Use gitea urls in action pull --- .gitea/workflows/build-on-release.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/build-on-release.yaml b/.gitea/workflows/build-on-release.yaml index bdd9574..264e9e0 100644 --- a/.gitea/workflows/build-on-release.yaml +++ b/.gitea/workflows/build-on-release.yaml @@ -10,12 +10,12 @@ jobs: runs-on: ubuntu-latest-rust steps: - name: Check out code repository - uses: actions/checkout@v4 + uses: https://gitea.com/actions/checkout@v4 - name: Build Binary run: | cargo build --release - name: Push binary to artifact - uses: actions/gitea-release-action@v1 + uses: https://gitea.com/actions/gitea-release-action@v1 with: draft: true files: |- From f53db91118a0942469ac4173d06804dd224be007 Mon Sep 17 00:00:00 2001 From: Luke Harding Date: Tue, 30 Apr 2024 13:52:23 -0400 Subject: [PATCH 5/5] Update README and add gitea workflow --- .gitea/workflows/build-on-release.yaml | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/.gitea/workflows/build-on-release.yaml b/.gitea/workflows/build-on-release.yaml index 85e0b87..264e9e0 100644 --- a/.gitea/workflows/build-on-release.yaml +++ b/.gitea/workflows/build-on-release.yaml @@ -1,13 +1,22 @@ name: Build on Release run-name: ${{ gitea.actor }} -on: [ release ] +on: + push: + branches: + - main jobs: cargo-build: - runs-on: ubuntu-latest + runs-on: ubuntu-latest-rust steps: - name: Check out code repository - uses: actions/checkout@v4 - - name: Is cargo installed? + uses: https://gitea.com/actions/checkout@v4 + - name: Build Binary run: | - which cargo \ No newline at end of file + cargo build --release + - name: Push binary to artifact + uses: https://gitea.com/actions/gitea-release-action@v1 + with: + draft: true + files: |- + target/release/rust-archlinux-update \ No newline at end of file