-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added fish, kitty, starship, waybar config PKGBUILDS
- Loading branch information
Showing
4 changed files
with
200 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Maintainer: ZeStig <zestig@duck.com> | ||
pkgname=stratos-fish-config | ||
pkgver=1.0 | ||
pkgrel=0 | ||
pkgdesc="Fish shell configuration for StratOS" | ||
arch=('x86_64') | ||
url="https://github.com/StratOS-Linux/StratOS-fish-config" | ||
license=('GPL') | ||
depends=('bash' 'fish') | ||
|
||
build() { | ||
git clone $url | ||
echo $srcdir | ||
} | ||
|
||
package() { | ||
mkdir -p "$pkgdir/etc/skel/.config/fish" | ||
|
||
emacs_config_paths=( "$HOME/.config/fish" ) | ||
|
||
config_exists=false | ||
for config in "${emacs_config_paths[@]}"; do | ||
if [ -e "$config" ]; then | ||
config_exists=true | ||
break | ||
fi | ||
done | ||
|
||
if [ "$config_exists" = true ]; then | ||
cp -r "$srcdir/StratOS-fish-config"/* "$pkgdir/etc/skel/.config/fish/" | ||
echo "The configuration files have been installed in /etc/skel/.config/fish." | ||
echo "You may copy the files manually if you wish to overwrite your current fish configuration." | ||
else | ||
read -p "No fish configuration files found. Do you want to install the StratOS fish configuration in .config/fish? (y/n): " user_input | ||
if [[ "$user_input" =~ ^[Yy]$ ]]; then | ||
mkdir -p "$HOME/.config/fish" | ||
cp -r "$srcdir/StratOS-fish-config"/* "$HOME/.config/fish/" | ||
else | ||
cp -r "$srcdir/StratOS-fish-config"/* "$pkgdir/etc/skel/.config/fish/" | ||
echo "The configuration files have been installed in /etc/skel/.config/fish." | ||
echo "You may copy the files manually if you wish to overwrite your current fish configuration." | ||
fi | ||
fi | ||
} | ||
|
||
pkgpostrm() { | ||
rm -rf "/etc/skel/.config/fish" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Maintainer: ZeStig <zestig@duck.com> | ||
pkgname=stratos-kitty-config | ||
pkgver=1.0 | ||
pkgrel=0 | ||
pkgdesc="Kitty terminal emulator configuration for StratOS" | ||
arch=('x86_64') | ||
url="https://github.com/StratOS-Linux/StratOS-kitty-config" | ||
license=('GPL') | ||
depends=('bash' 'kitty') | ||
|
||
build() { | ||
git clone $url | ||
echo $srcdir | ||
} | ||
|
||
package() { | ||
mkdir -p "$pkgdir/etc/skel/.config/kitty" | ||
|
||
emacs_config_paths=( "$HOME/.config/kitty" ) | ||
|
||
config_exists=false | ||
for config in "${emacs_config_paths[@]}"; do | ||
if [ -e "$config" ]; then | ||
config_exists=true | ||
break | ||
fi | ||
done | ||
|
||
if [ "$config_exists" = true ]; then | ||
cp -r "$srcdir/StratOS-kitty-config"/* "$pkgdir/etc/skel/.config/kitty/" | ||
echo "The configuration files have been installed in /etc/skel/.config/kitty." | ||
echo "You may copy the files manually if you wish to overwrite your current kitty configuration." | ||
else | ||
read -p "No fish configuration files found. Do you want to install the StratOS kitty configuration in .config/kitty? (y/n): " user_input | ||
if [[ "$user_input" =~ ^[Yy]$ ]]; then | ||
mkdir -p "$HOME/.config/kitty" | ||
cp -r "$srcdir/StratOS-kitty-config"/* "$HOME/.config/kitty/" | ||
else | ||
cp -r "$srcdir/StratOS-kitty-config"/* "$pkgdir/etc/skel/.config/kitty/" | ||
echo "The configuration files have been installed in /etc/skel/.config/kitty." | ||
echo "You may copy the files manually if you wish to overwrite your current kitty configuration." | ||
fi | ||
fi | ||
} | ||
|
||
pkgpostrm() { | ||
rm -rf "/etc/skel/.config/kitty" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
# Maintainer: ZeStig <zestig@duck.com> | ||
pkgname=stratos-starship-config | ||
pkgver=1.0 | ||
pkgrel=0 | ||
pkgdesc="Starship shell prompt configuration for StratOS" | ||
arch=('x86_64') | ||
url="https://github.com/StratOS-Linux/StratOS-starship-config" | ||
license=('GPL') | ||
depends=('bash' 'fish') | ||
|
||
build() { | ||
git clone $url | ||
echo $srcdir | ||
} | ||
|
||
package() { | ||
mkdir -p "$pkgdir/etc/skel/.config/fish" | ||
|
||
emacs_config_paths=( "$HOME/.config/fish" ) | ||
|
||
config_exists=false | ||
for config in "${emacs_config_paths[@]}"; do | ||
if [ -e "$config" ]; then | ||
config_exists=true | ||
break | ||
fi | ||
done | ||
|
||
if [ "$config_exists" = true ]; then | ||
cp -r "$srcdir/StratOS-fish-config"/* "$pkgdir/etc/skel/.config/fish/" | ||
echo "The configuration files have been installed in /etc/skel/.config/fish." | ||
echo "You may copy the files manually if you wish to overwrite your current fish configuration." | ||
else | ||
read -p "No fish configuration files found. Do you want to install the StratOS fish configuration in .config/fish? (y/n): " user_input | ||
if [[ "$user_input" =~ ^[Yy]$ ]]; then | ||
mkdir -p "$HOME/.config/fish" | ||
cp -r "$srcdir/StratOS-fish-config"/* "$HOME/.config/fish/" | ||
else | ||
cp -r "$srcdir/StratOS-fish-config"/* "$pkgdir/etc/skel/.config/fish/" | ||
echo "The configuration files have been installed in /etc/skel/.config/fish." | ||
echo "You may copy the files manually if you wish to overwrite your current fish configuration." | ||
fi | ||
fi | ||
} | ||
|
||
pkgpostrm() { | ||
rm -rf "/etc/skel/.config/fish" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# Maintainer: ZeStig <zestig@duck.com> | ||
pkgname=stratos-waybar-config | ||
pkgver=1.0 | ||
pkgrel=0 | ||
pkgdesc="StratOS Waybar config" | ||
arch=('x86_64') | ||
url="https://github.com/StratOS-Linux/StratOS-waybar-config" | ||
license=('GPL') | ||
depends=('bash') | ||
|
||
build() { | ||
# Clone the repo directly into the source directory | ||
git clone "$url" "$srcdir/StratOS-waybar-config" | ||
echo "$srcdir" | ||
} | ||
|
||
package() { | ||
# Define the target installation directory | ||
local config_dir="$pkgdir/etc/skel/.config/waybar" | ||
|
||
# Create the necessary directories | ||
mkdir -p "$config_dir" | ||
|
||
# Define the path of the Waybar config in the user's home | ||
local waybar_config_path="$HOME/.config/waybar" | ||
|
||
# Check if a Waybar configuration already exists in the home directory | ||
if [ -e "$waybar_config_path" ]; then | ||
# If the config exists in the home directory, ask if user wants to overwrite it | ||
read -p "Waybar configuration already exists in your home directory. Do you want to overwrite it? (y/n): " user_input | ||
if [[ "$user_input" =~ ^[Yy]$ ]]; then | ||
cp -r "$srcdir/StratOS-waybar-config"/* "$waybar_config_path/" | ||
echo "Your Waybar configuration has been overwritten in $waybar_config_path." | ||
else | ||
echo "The Waybar configuration was not overwritten." | ||
fi | ||
else | ||
# If no Waybar configuration exists in the home directory, copy to the home directory | ||
read -p "No Waybar configuration found in your home directory. Do you want to install the configuration there? (y/n): " user_input | ||
if [[ "$user_input" =~ ^[Yy]$ ]]; then | ||
mkdir -p "$waybar_config_path" | ||
cp -r "$srcdir/StratOS-waybar-config"/* "$waybar_config_path/" | ||
echo "The Waybar configuration has been installed in your home directory." | ||
fi | ||
fi | ||
|
||
# Also copy the configuration to /etc/skel/.config/waybar for new users | ||
cp -r "$srcdir/StratOS-waybar-config"/* "$config_dir/" | ||
echo "The configuration files have been installed in /etc/skel/.config/waybar." | ||
echo "New users will get the default Waybar configuration in their home directories." | ||
} | ||
|
||
pkgpostrm() { | ||
# Clean up the configuration directory in /etc/skel when the package is removed | ||
rm -rf "/etc/skel/.config/waybar" | ||
} |