mirror of
https://github.com/starr-dusT/dotfiles.git
synced 2025-05-19 10:56:05 -07:00
setup xbps-src packaging and update script to allow skipping them
This commit is contained in:
parent
f983d68dd9
commit
9ad14d05ff
@ -1,9 +1,11 @@
|
|||||||
#!/usr/bin/env sh
|
#!/usr/bin/env bash
|
||||||
set -e
|
|
||||||
echo -e "Starting initial setup for Fedora..."
|
|
||||||
|
|
||||||
# Install ansible and run playbook
|
echo -e "Starting initial setup..."
|
||||||
sudo dnf -y update && sudo dnf install -y ansible
|
|
||||||
|
# Install ansible python dependencies
|
||||||
|
sudo xpbs-install -Syu
|
||||||
|
sudo xbps-install python3 python3-pip ansible
|
||||||
|
sudo pip install pexpect
|
||||||
|
|
||||||
# Install ansible extensions
|
# Install ansible extensions
|
||||||
ansible-galaxy install -r {{ .chezmoi.workingTree }}/provision/requirements.yml
|
ansible-galaxy install -r {{ .chezmoi.workingTree }}/provision/requirements.yml
|
||||||
@ -19,7 +21,7 @@ read -p "Reboot? " -n 1 -r
|
|||||||
echo # (optional) move to a new line
|
echo # (optional) move to a new line
|
||||||
if [[ ! $REPLY =~ ^[Yy]$ ]]
|
if [[ ! $REPLY =~ ^[Yy]$ ]]
|
||||||
then
|
then
|
||||||
exit 1
|
exit 0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo reboot
|
sudo reboot
|
||||||
|
@ -1,13 +1,56 @@
|
|||||||
#!/usr/bin/env sh
|
#!/usr/bin/env bash
|
||||||
# provide tags to update with comma seperation (e.g. updates,packages)
|
|
||||||
set -e
|
help ()
|
||||||
echo "Starting update for Void..."
|
{
|
||||||
|
echo "
|
||||||
|
Update void linux with ansible
|
||||||
|
|
||||||
|
Usage: update <tags> <flags>
|
||||||
|
|
||||||
|
EXAMPLE TAGS:
|
||||||
|
packages,configs
|
||||||
|
|
||||||
|
FLAGS:
|
||||||
|
-s, --src compile (or recompile) source based packages"
|
||||||
|
exit 0
|
||||||
|
}
|
||||||
|
|
||||||
|
POSITIONAL_ARGS=()
|
||||||
|
SRC=false
|
||||||
|
|
||||||
|
while [[ $# -gt 0 ]]; do
|
||||||
|
case $1 in
|
||||||
|
-s|--src)
|
||||||
|
SRC=true
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-h|--help)
|
||||||
|
help
|
||||||
|
;;
|
||||||
|
-*|--*)
|
||||||
|
echo "Unknown option $1"
|
||||||
|
exit 1
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
POSITIONAL_ARGS+=("$1")
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
set -- "${POSITIONAL_ARGS[@]}" # restore positional parameters
|
||||||
|
|
||||||
# Goto playbook and run it
|
# Goto playbook and run it
|
||||||
cd {{ .chezmoi.workingTree }}/provision
|
cd {{ .chezmoi.workingTree }}/provision
|
||||||
|
|
||||||
# Install ansible and run playbook
|
# Install ansible and run playbook
|
||||||
ansible-playbook setup.yml -i hosts --ask-become-pass --tags "$1" --skip-tags "once"
|
if [ "$SRC" = true ] ; then
|
||||||
|
echo "Starting update with source packages - be prepated to wait..."
|
||||||
|
ansible-playbook setup.yml -i hosts --ask-become-pass --tags "$1" --skip-tags "once"
|
||||||
|
else
|
||||||
|
echo "Starting update without source packages..."
|
||||||
|
ansible-playbook setup.yml -i hosts --ask-become-pass --tags "$1" --skip-tags "once,src"
|
||||||
|
fi
|
||||||
|
|
||||||
# Return to where you were
|
# Return to where you were
|
||||||
cd -
|
cd -
|
||||||
|
@ -30,17 +30,20 @@
|
|||||||
state: present
|
state: present
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
|
- name: Install desktop xbps-src packages
|
||||||
|
tags: ["src"]
|
||||||
|
include_tasks: ../include/xbps-src.yml
|
||||||
|
loop:
|
||||||
|
- package: rofi-rbw # Simplistic password typer/copier using rofi and wofi
|
||||||
|
repository: hostdir/binpkgs
|
||||||
|
|
||||||
- name: Install desktop flatpaks
|
- name: Install desktop flatpaks
|
||||||
flatpak:
|
flatpak:
|
||||||
name:
|
name:
|
||||||
- com.discordapp.Discord # Voice, video and text communication service
|
- com.discordapp.Discord # VoIP and instant messaging social platform
|
||||||
- org.gimp.GIMP # Create images and edit photographs
|
- org.gimp.GIMP # Create images and edit photographs
|
||||||
- org.inkscape.Inkscape # Vector Graphics Editor
|
- org.inkscape.Inkscape # Vector Graphics Editor
|
||||||
- com.github.tchx84.Flatseal # Manage Flatpak permissions
|
- com.github.tchx84.Flatseal # Manage Flatpak permissions
|
||||||
state: present
|
state: present
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Install desktop python packages
|
|
||||||
ansible.builtin.pip:
|
|
||||||
name:
|
|
||||||
- rofi-rbw # Rofi frontend for Bitwarden
|
|
||||||
|
@ -6,7 +6,6 @@
|
|||||||
- ripgrep # Fast search tool inspired by ag and grep
|
- ripgrep # Fast search tool inspired by ag and grep
|
||||||
- fd # Simple, fast and user-friendly alternative to find
|
- fd # Simple, fast and user-friendly alternative to find
|
||||||
- lazygit # Simple terminal UI for git commands
|
- lazygit # Simple terminal UI for git commands
|
||||||
- cargo # Rust package manager
|
|
||||||
state: present
|
state: present
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
|
33
provision/tasks/include/xbps-src.yml
Normal file
33
provision/tasks/include/xbps-src.yml
Normal file
@ -0,0 +1,33 @@
|
|||||||
|
- name: Clone or pull void-packages
|
||||||
|
ansible.builtin.git:
|
||||||
|
repo: 'https://github.com/void-linux/void-packages.git'
|
||||||
|
dest: /home/{{ user }}/git/void-packages
|
||||||
|
update: yes
|
||||||
|
register: git_return
|
||||||
|
|
||||||
|
- name: Bootstrap if newly cloned
|
||||||
|
ansible.builtin.command: ./xbps-src binary-bootstrap
|
||||||
|
args:
|
||||||
|
chdir: /home/{{ user }}/git/void-packages
|
||||||
|
when: not git_return.before
|
||||||
|
|
||||||
|
- name: Enable restricted if newly cloned
|
||||||
|
copy:
|
||||||
|
dest: /home/{{ user }}/git/void-packages/etc/conf
|
||||||
|
content: |
|
||||||
|
XBPS_ALLOW_RESTRICTED=yes
|
||||||
|
when: not git_return.before
|
||||||
|
|
||||||
|
- name: Package {{ item.package }} with xbps-src
|
||||||
|
ansible.builtin.command: ./xbps-src pkg {{ item.package }}
|
||||||
|
args:
|
||||||
|
chdir: /home/{{ user }}/git/void-packages
|
||||||
|
|
||||||
|
- name: Install packaged {{ item.package }}
|
||||||
|
expect:
|
||||||
|
command: xbps-install --repository {{ item.repository }} {{ item.package }}
|
||||||
|
responses:
|
||||||
|
continue: y
|
||||||
|
args:
|
||||||
|
chdir: /home/{{ user }}/git/void-packages
|
||||||
|
become: true
|
@ -37,4 +37,3 @@
|
|||||||
state: present
|
state: present
|
||||||
flatpakrepo_url: https://flathub.org/repo/flathub.flatpakrepo
|
flatpakrepo_url: https://flathub.org/repo/flathub.flatpakrepo
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
|
@ -13,10 +13,12 @@
|
|||||||
- khal # Command-line calendar build around CalDAV
|
- khal # Command-line calendar build around CalDAV
|
||||||
- khard # Command-line addressbook built around CardDAV
|
- khard # Command-line addressbook built around CardDAV
|
||||||
- vdirsyncer # Synchronize calendars and addressbooks
|
- vdirsyncer # Synchronize calendars and addressbooks
|
||||||
- cargo # Required for rbw
|
|
||||||
state: present
|
state: present
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
- name: Install rbw
|
- name: Install terminal xbps-src packages
|
||||||
community.general.cargo:
|
tags: ["src"]
|
||||||
name: rbw # Unofficial command line client for Bitwarden
|
include_tasks: ../include/xbps-src.yml
|
||||||
|
loop:
|
||||||
|
- package: rbw # Unofficial command line client for bitwarden
|
||||||
|
repository: hostdir/binpkgs
|
||||||
|
6
void.md
6
void.md
@ -86,12 +86,6 @@ export HOME=/home/tstarr/
|
|||||||
exec /usr/bin/syncthing > /dev/null 2>&1
|
exec /usr/bin/syncthing > /dev/null 2>&1
|
||||||
```
|
```
|
||||||
|
|
||||||
## OH-my-zsh
|
|
||||||
|
|
||||||
```bash
|
|
||||||
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
|
|
||||||
```
|
|
||||||
|
|
||||||
## Lxappearance
|
## Lxappearance
|
||||||
|
|
||||||
GTK theme can be set with lxappearance
|
GTK theme can be set with lxappearance
|
||||||
|
Loading…
x
Reference in New Issue
Block a user