Compare commits

..

10 Commits

Author SHA1 Message Date
46e2859d28 trim whitespaces
Some checks failed
Build on Multiple Distributions / build-on-arch (push) Failing after 1m31s
Build on Multiple Distributions / build-on-debian (push) Failing after 2m57s
Build on Multiple Distributions / build-on-fedora (push) Failing after 1m12s
2025-04-30 17:59:48 +05:30
93a9424b98 minor improvements 2025-04-25 14:59:34 +05:30
d4649c8f00 change guake to yakuake and add kdepim-addons 2025-04-25 14:59:01 +05:30
59ef68a9b4 remove dups 2025-04-25 14:58:36 +05:30
c6096a1d51 add zen and headlamp 2025-04-22 12:16:32 +05:30
30b90ec02b Edit .gitlab-ci.yml 2025-04-21 23:53:17 +00:00
137be4f34c Update .gitlab-ci.yml file 2025-04-21 23:48:52 +00:00
8dc0e308ff Add new file 2025-04-21 23:47:15 +00:00
8269d99d26 Edit build.yml 2025-04-21 23:30:28 +00:00
bd281b11b6 Update .gitea/workflows/build.yml 2025-04-18 11:47:29 +00:00
6 changed files with 57 additions and 17 deletions

View File

@@ -22,7 +22,7 @@ jobs:
- name: Checkout code - name: Checkout code
run: | run: |
git clone http://192.168.1.233:222/aggarwalakshun/rust-setup.git . git clone https://akshun-gitlab.uk/aggarwalakshun/rust-setup.git .
git checkout $GITEA_SHA git checkout $GITEA_SHA
- name: Install dependencies - name: Install dependencies
@@ -53,7 +53,7 @@ jobs:
- name: Checkout code - name: Checkout code
run: | run: |
git clone http://192.168.1.233:222/aggarwalakshun/rust-setup.git . git clone https://akshun-gitlab.uk/aggarwalakshun/rust-setup.git .
git checkout $GITEA_SHA git checkout $GITEA_SHA
- name: Install dependencies - name: Install dependencies
@@ -83,7 +83,7 @@ jobs:
- name: Checkout code - name: Checkout code
run: | run: |
git clone http://192.168.1.233:222/aggarwalakshun/rust-setup.git . git clone https://akshun-gitlab.uk/aggarwalakshun/rust-setup.git .
git checkout $GITEA_SHA git checkout $GITEA_SHA
- name: Install dependencies - name: Install dependencies

36
.gitlab-ci.yml Normal file
View File

@@ -0,0 +1,36 @@
stages:
- build
variables:
GIT_STRATEGY: clone
GIT_SUBMODULE_STRATEGY: recursive
.build_template: &build_template
stage: build
script:
- cargo build --release
artifacts:
paths:
- target/release/setup
build_on_arch:
<<: *build_template
image: archlinux:latest
before_script:
- pacman -Syu --noconfirm
- pacman -S --noconfirm git rustup gcc
- rustup default stable
build_on_debian:
<<: *build_template
image: debian:stable
before_script:
- apt update && apt upgrade -y
- apt install -y git cargo
build_on_fedora:
<<: *build_template
image: fedora:latest
before_script:
- dnf up -y
- dnf install -y git cargo

View File

@@ -6,13 +6,10 @@ guake-git
howdy-beta-git howdy-beta-git
lens-bin lens-bin
moonlight-qt-bin moonlight-qt-bin
oh-my-posh-bin
onlyoffice-bin onlyoffice-bin
jellyfin-media-player jellyfin-media-player
mission-center mission-center
moonlight-qt-bin
oh-my-posh-bin oh-my-posh-bin
onlyoffice-bin
sunshine-bin sunshine-bin
standardnotes-bin standardnotes-bin
visual-studio-code-bin visual-studio-code-bin

View File

@@ -19,6 +19,8 @@
"org.qbittorrent.qBittorrent": "qBittorrent", "org.qbittorrent.qBittorrent": "qBittorrent",
"org.videolan.VLC": "VLC", "org.videolan.VLC": "VLC",
"org.standardnotes.standardnotes": "Standard Notes", "org.standardnotes.standardnotes": "Standard Notes",
"one.ablaze.floorp": "Floorp" "one.ablaze.floorp": "Floorp",
"app.zen_browser.zen": "Zen Browser",
"io.kinvolk.Headlamp": "Headlamp"
} }
} }

View File

@@ -1,4 +1,4 @@
guake yakuake
neovim neovim
git git
flatpak flatpak
@@ -8,4 +8,5 @@ cargo
kio-gdrive kio-gdrive
korganizer korganizer
plasma5-integration plasma5-integration
kwayland-integration kwayland-integration
kdepim-addons

View File

@@ -29,7 +29,7 @@ fn main() -> io::Result<()> {
let buffer = std::str::from_utf8(&file_content.data) let buffer = std::str::from_utf8(&file_content.data)
.map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?; .map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?;
let first_choice: Vec<String> = buffer.lines().map(|line| line.to_string()).collect(); let first_choice: Vec<String> = buffer.lines().map(|line| line.trim().to_string()).collect();
for (index, element) in first_choice.iter().enumerate() { for (index, element) in first_choice.iter().enumerate() {
eprint!("{}. {}\n", index + 1, element); eprint!("{}. {}\n", index + 1, element);
@@ -43,9 +43,9 @@ fn main() -> io::Result<()> {
} }
match distro { match distro {
"arch" => arch_choices(input)?, // Pass the input value here "arch" => arch_choices(input)?,
"Debian" => debian_choices(input)?, // Pass the input value here "Debian" => debian_choices(input)?,
"fedora" => fedora_choices(input)?, // Pass the input value here "fedora" => fedora_choices(input)?,
_ => return Err(io::Error::new(io::ErrorKind::NotFound, "Unsupported distro")), _ => return Err(io::Error::new(io::ErrorKind::NotFound, "Unsupported distro")),
}; };
} }
@@ -103,7 +103,7 @@ fn install_programs() -> Result<(), Box<dyn std::error::Error>> {
let file = Asset::get("prompts/programs.txt").ok_or_else(|| io::Error::new(io::ErrorKind::NotFound, "File not found"))?; let file = Asset::get("prompts/programs.txt").ok_or_else(|| io::Error::new(io::ErrorKind::NotFound, "File not found"))?;
let buffer = std::str::from_utf8(&file.data) let buffer = std::str::from_utf8(&file.data)
.map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?; .map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?;
let choice: Vec<String> = buffer.lines().map(|line| line.to_string()).collect(); let choice: Vec<String> = buffer.lines().map(|line| line.trim().to_string()).collect();
for(index, element) in choice.iter().enumerate() { for(index, element) in choice.iter().enumerate() {
eprint!("{}. {}\n", index+1, element) eprint!("{}. {}\n", index+1, element)
@@ -235,6 +235,10 @@ fn update_system() -> Result<(), Box<dyn std::error::Error>> {
_ => eprint!("Unsupported distro") _ => eprint!("Unsupported distro")
}; };
if which("flatpak").is_some() {
Command::new("flatpak").arg("update").status()?;
}
Ok(()) Ok(())
} }
@@ -245,10 +249,10 @@ fn aur() -> Result<(), Box<dyn std::error::Error>> {
let file = Asset::get("prompts/aur.txt").ok_or_else(|| io::Error::new(io::ErrorKind::NotFound, "File not found"))?; let file = Asset::get("prompts/aur.txt").ok_or_else(|| io::Error::new(io::ErrorKind::NotFound, "File not found"))?;
let buffer = std::str::from_utf8(&file.data) let buffer = std::str::from_utf8(&file.data)
.map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?; .map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?;
let choice: Vec<String> = buffer.lines().map(|line| line.to_string()).collect(); let choice: Vec<String> = buffer.lines().map(|line| line.trim().to_string()).collect();
if which("yay").is_none() { if which("yay").is_none() {
eprint!("AUR helper not found. Install yay Y/N? (1/0)"); eprint!("yay not found. Install yay Y/N? (1/0)");
let input = handle_int_input(); let input = handle_int_input();
if input == 1 { if input == 1 {
Command::new("sudo").arg("pacman").arg("-S").arg("git").arg("base-devel").status()?; Command::new("sudo").arg("pacman").arg("-S").arg("git").arg("base-devel").status()?;
@@ -291,7 +295,7 @@ fn third_party() -> Result<(), Box<dyn std::error::Error>> {
let buffer = std::str::from_utf8(&file.data) let buffer = std::str::from_utf8(&file.data)
.map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?; .map_err(|e| io::Error::new(io::ErrorKind::InvalidData, e))?;
let choices: Vec<String> = buffer.lines().map(|line| line.to_string()).collect(); let choices: Vec<String> = buffer.lines().map(|line| line.trim().to_string()).collect();
for (index, element) in choices.iter().enumerate() { for (index, element) in choices.iter().enumerate() {
eprintln!("{}. {}", index + 1, element); eprintln!("{}. {}", index + 1, element);